Re: When does the httpRuntime maxRequestLength setting kick in?



maxRequestLength is used to monitor the input stream (upload). if the max
length is hit, then asp.net closes the request stream giving the browser an
error. so if you max was set a 2mb, and the user tried to upload a 4mb file,
they would get an error in the middle of their upload, and your webhost
would charge you for 2mb of bandwidth.

-- bruce (sqlwork.com)

"Andy Stephens" <andrew.stephens@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:98EA95A2-E7E9-48AC-8B32-F100AA26B94D@xxxxxxxxxxxxxxxx
Hi all

I'm developing a site where visitors can upload images (using the html
file
input control). As most webhosting companies set a monthly bandwidth limit
I
want to try and limit the size of uploads.

I thought about using the <httpRuntime> "maxRequestLength" setting, which
throws an exception if a HTTP request is too large. Does anyone know if
this
will work, or will it occur too late in the request lifecycle. I.E. will
the
webhost's bandwidth monitor "capture" the request before ASP.Net (or IIS?)
rejects the request length?


Many thanks
Andy


.



Relevant Pages

  • Solution design
    ... allow the end user to upload photos to the server. ... The first request would trigger for creating: ... and uses the advantages of the .NET technologies even on client side). ... we tried to create a Java applet that was trying to ...
    (microsoft.public.dotnet.general)
  • Re: I cant get httpWorkerRequest.ReadEntityBody() to work !!!
    ... ASP.NET Httpmodule to intercept file upload requests. ... The HttpWorkerRequest class is a raw abstract class ... help us access the uploaded file streams in the Multi-Part form request. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: [PHP] php File upload
    ... support on the client, and a server that understands the DAV request. ... I've not had to upload such large files over HTTP, ... sends them in the response headers when serving a GET request. ...
    (php.general)
  • Tomcat - post upload fails for files over 320 KB
    ... I am using a Post Servlet to handle a text file upload. ... the browser never got beyond the "Sending request" ...
    (comp.lang.java.programmer)
  • Re: HTTP Adapter
    ... Is it autmotically supposed to read the input stream withouht invoking this ... I have an orchestration in my scenario as well. ... >> stream as an HTTP Request and write the data to a file. ...
    (microsoft.public.biztalk.general)

Loading