10

I would like to monitor HTTP request headers. Does IIS log this information somewhere?

0

6 Answers 6

12

IIS can log few HTTP headers; including Referer, Cookie and User-agent; but not all. If you want to log any of these variables, you'll have to set them up from IIS manager (Web Site Properties > Web Site Tab > Enable Logging > Properties)

3

To log custom headers you can use IIS Advanced Logging feature. A good article on it can be found at http://www.iis.net/learn/extensions/advanced-logging-module/advanced-logging-for-iis-custom-logging

1
  • Adding detail from the link would improve this answer. Links break and that renders the answer less useful
    – Dave M
    Apr 20, 2015 at 12:34
3

You can use failed request tracing in IIS to include status code 200. This would log successful requests too and you can view all request headers in the "request details" > "general request headers" section.

2

you can use software like: http://iismonitor.motobit.com/ or ethereal

1
  • do you use it ?
    – Kiquenet
    Sep 12, 2018 at 8:07
1

I would reccomend using Wireshark. It is an excellent tool and the more familiar you are with it the more uses you will find for it.

Also, because HTTP headers are sometimes broken into multiple TCP segments you might have to enable "Reassemble HTTP headers spanning multiple TCP segments".

Hope that helps.

0

You can simply define any request headers that you want to monitor in IIS Manager, so they are recorded with each request in the W3C log output.

To do so select the desired site in IIS Manager's left pane, open the Logging tool in the middle pane, and click "Select Fields...".

enter image description here

Then add all request headers that you want to log in the "Custom Fields" box using the "Add Field..." button:

enter image description here

"Log Field" is a free name (no blanks allowed),
"Source" must contain the exact name of the request header.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .