简体   繁体   English

Fiddler没有从Windows 8中的C#应用​​程序捕获流量

[英]Fiddler Not Capturing Traffic from my C# Application in Windows 8

I have recently upgraded to a new computer with Windows 8. I have installed Fiddler, yet I am having problems capturing traffic sent and received from my C# application. 我最近升级到使用Windows 8的新计算机。我已经安装了Fiddler,但我在捕获从C#应用程序发送和接收的流量时遇到问题。 I never had this issue on Windows 7, so I assume its a Windows 8 issue. 我从来没有在Windows 7上遇到过这个问题,所以我认为它是Windows 8的问题。

The application is an ordinary WinForms application using C# 5.0 and .NET 4.5. 该应用程序是使用C#5.0和.NET 4.5的普通WinForms应用程序。 I am using Visual Studio 2012. 我正在使用Visual Studio 2012。

Any ideas how to get around this as I'm having a hard time debugging my application without it. 任何想法如何解决这个问题,因为我很难在没有它的情况下调试我的应用程序。

Fiddler captures traffic from Chrome and Firefox with no issues, just not my application. Fiddler捕获来自Chrome和Firefox的流量没有任何问题,只是我的应用程序。 I have also loaded another application that I developed, and that works fine. 我还加载了我开发的另一个应用程序,并且工作正常。

It may be worth noting that this is the first application I've developed that uses HttpClient to make Http requests. 值得注意的是,这是我开发的第一个使用HttpClient发出Http请求的应用程序。 Could that be causing any issues? 这会引起任何问题吗?

Edit: I am using the Fiddler Application to monitor traffic. 编辑:我正在使用Fiddler应用程序来监控流量。 I am not connecting to localhost. 我没有连接到localhost。 I am connect to web API's. 我连接到web API。

Step #1 is to try starting Fiddler before starting your application. 步骤#1是在开始申请之前尝试启动Fiddler。 This helps the default configuration, whereby .NET applications pick up the system proxy when they start and are oblivious to proxy changes after they start. 这有助于默认配置,从而.NET应用程序在启动时会选择系统代理,并且在启动后无需代理更改。

Step #2, if the first step doesn't work, is to explicitly configure your process to use the proxy by editing the app.exe.config file or the machine.config file, or by setting the Proxy property on the request object. 步骤#2,如果第一步不起作用,则通过编辑app.exe.config文件或machine.config文件,或通过在请求对象上设置Proxy属性,显式配置进程以使用代理。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM