I got error "The request filtering module is configured to deny a request that exceeds the request content length" at IIS 7

ASP.NET
I got error "The request filtering module is configured to deny a request that exceeds the request content length" at IIS 7

SUMMARY

This problem occurs because by default in IIS 7 enabled requestFiltering that have MaxAllowedContentLength property. It specifies, in bytes, the maximum length of content in a request. The default is 30000000 (approximately 30 megabytes.)

SOLUTION

To change this value you must include following code in your Web.config file if you want to apply this setting only to you application.

<configuration>
   <system.webServer>
      <security>
         <requestFiltering>
            <requestLimits maxAllowedContentLength="100000000"/> 
         </requestFiltering>
      </security>
   </system.webServer>
</configuration>      
     

Add Feedback