Archive for the ‘Debugging’ Category

Tracing HTTP with Fiddler

October 6, 2012 Leave a comment

Fiddler is a great tool for debugging HTTP traffic between a HTTP client and a HTTP server.

It’s free and can be downloaded from here:

Debugging with localhost

Fiddler is acting as a local proxy and enables itself for all WinInet based communication after startup.

However, there are some things to remember when debugging traffic to and from a local server, because depending on the .NET framework version, proxy usage is disabled in code.

Example: The traffic from this site should be captured: http://localhost/MySite/MyPage.aspx

There are a few workarounds, which should help to solve this situation:

– Use <machinename> instead of localhost ==> http://mymachine/MySite/MyPage.aspx

– Use ipv4.fiddler instead of localhost ==> http://ipv4.fiddler/MySite/MyPage.aspx

– Use ipv6.fiddler instead of localhost ==> http://ipv4.fiddler/MySite/MyPage.aspx

Debugging with IIS 8 Express on Windows 8

There can be even more problems, when using IIS 8 Express on Windows 8.

IIS Express is hardcoded to respond only to requests on localhost.

Therefore ipv4.fiddler does not work in this scenario.

But also this scenario can be solved:

– Use localhost.fiddler instead of localhost ==> http://localhost.fiddler:5057/MySite/MyPage.aspx


Debugging Http traffic to and from immersive / New UI Style apps

Example: When using the new immersive IE, there must be done one more change, because all Win 8 New UI Style apps cannot contact local services by default.

This will work only, if they get an additional server capability, but much better for debugging is to set the app on the excempt list.

Fiddler can help to do this:

image image

This way also the immersive IE browser and every other Windows Store App is able to contact local services via HTTP.

Categories: Debugging, Windows 8