We had a reported application issue in which the user was receiving a “Request entity is too large” over SSL only.  When accessing the same application with the same data over regular HTTP, everything worked fine.

Upon further research, we determined that over SSL, the entire request entity body must be preloaded during negotiation.  In addition, SSL will use the value of the UploadReadAheadSize metabase property to validate the request size.  http://www.microsoft.com/technet/prodtechnol/WindowsServer2003/Library/IIS/7e0d74d3-ca01-4d36-8ac7-6b2ca03fd383.mspx?mfr=true

The UploadReadAheadSize metabase property specifies the number of bytes that a Web server will read into a buffer and pass to an ISAPI extension or module. This occurs once per client request. The ISAPI extension or module receives any additional data directly from the client.

To fix this issue, the UploadReadAheadSize metabase property value needs to be increased.  Plesae note that the default value for the UploadReadAheadSize is 49152.  The maximum size for this property is 2147483647.

In this example, we will increase the value to “204800”.

  1. On the web server, open the command prompt Run –> CMD.EXE.
  2. Change directories to the C:\Windows\SysWOW64\inetsrv (assumes 64-bit) –> CD C:\Windows\SysWOW64\inetsrv
  3. Determine the current metabase property value: appcmd.exe list config –section:system.webServer/serverRuntime
  4. Increase the metabase property value:  appcmd.exe set config -section:system.webServer/serverRuntime /uploadReadAheadSize:”204800″