Question

I have a file input field that base64 encodes a selected image to be sent to my handler (IHttpHandler).

What is the maximum or how do I found out what the maximum request size I can send to my handler?

The file will not be larger than 500kB, but I dont' know if that is too big or not, and given the nature of base64 encoding, it inflates the filesize ~33%.

UPDATE: Thank you all for the helpful answers and comments!

Was it helpful?

Solution

The max request size is driven by a setting in web.config:

<httpRuntime maxRequestLength="nnnn" />

The default is 4MB.

http://msdn.microsoft.com/en-us/library/system.web.configuration.httpruntimesection.maxrequestlength(v=vs.100).aspx

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top