IIS Log Request Body / POST Data

httpiislogging

Does anyone know how I could get IIS to log POST data or the entire HTTP request?

Best Answer

The IIS logs only record querystring and header information without any POST data.

If you're using IIS7, you can enabled Failed Request Tracing for status code 200. That will record all of the data and you can select which type of data to include.

In either IIS6 or 7, you can use Application_BeginRequest in global.asax and create your own logging of POST data.

Or, in IIS7, you can write a HTTP Module with your own custom logging.