Thursday, March 27, 2014

Fiddler and Asp.Net

Ran across this today, just a handy item to know.  I use Fiddler a lot of debugging web programming.  Today I needed to use to to debug some Web.Request conversation.  For the most part I write everything out to log files and it contains what I need.  But, I was dealing with a tech support organization who really wanted Fiddler output.


http://weblog.west-wind.com/posts/2009/Jan/14/Monitoring-HTTP-Output-with-Fiddler-in-NET-HTTP-Clients-and-WCF-Proxies

So, even though I have libraries to man-handle the Web.Requests the following entry in the web.config file allowed Fiddler to see the conversation.  No code change!

  <system.net>
    <defaultProxy>
      <proxy
              usesystemdefault="False"
              bypassonlocal="True" 
              proxyaddress="http://127.0.0.1:8888"              
              />
    </defaultProxy>
  </system.net>
 
If you forget and don't have Fiddler running, you can get the following error
System.Net.Sockets.SocketException: No connection could be made because the target machine actively refused it 127.0.0.1:8888
 
 


No comments:

Post a Comment