Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Capture internal request calls in fiddler

Tags:

c#

wcf

asmx

fiddler

I have web application and calling WCF and ASMX services internally to get the information. But, In fildder I'm able to see the only web apllication aspx requests alone, not WCF and asmx service calls.

How I can captures those WCF and asmx calls in the Fiddler trafiice.

If fiddler has not having that option, please suggest some other tools.

like image 320
user2783742 Avatar asked Mar 23 '23 09:03

user2783742


1 Answers

By default, Fiddler runs as a proxy server, which captures traffic that is passed through it.

When you run Fiddler on your client, your browser passes request through Fiddler on their way out to the server. If your client and server are on the same PC, traffic sent to localhost or 127.0.0.1 might bypass Fiddler due to hardcoded limits in the .NET Framework (browsers don't have this problem).

To address this, you can update the .NET code to hit one of the aliases for localhost that Fiddler supports, to wit: localhost.fiddler or ipv4.fiddler or ipv6.fiddler.

If Fiddler is running on the server and you want to capture requests made by your serverside code (e.g. outbound requests from ASP.NET) then you need to configure your ASP.NET application to send its traffic to Fiddler. That's because, when Fiddler runs, it configures the current user to send its traffic to Fiddler, but ASP.NET runs inside a Windows Service account and not inside the current user's account. There are several ways to capture requests made from inside ASP.NET, but this blog post summarizes the simplest. Update the appropriate machine.config (usually the 64bit version of the file) to contain the line

<proxy autoDetect="false" bypassonlocal="false" proxyaddress="http://127.0.0.1:8888" usesystemdefault="false" />

Now, if Fiddler is running on a different server then you'd have to configure the proxy setting to point to whatever machine Fiddler is running on, e.g.

<proxy autoDetect="false" bypassonlocal="false" proxyaddress="http://MyFiddlerServer:8888" usesystemdefault="false" />

like image 69
EricLaw Avatar answered Apr 27 '23 02:04

EricLaw