Silverlight在不运行Fiddler的情况下无法下载clientaccessppolice .xml

本文关键字:下载 clientaccessppolice xml 情况下 运行 Fiddler Silverlight | 更新日期: 2023-09-27 18:02:11

我的项目由Silverlight和WindowsForms两部分组成。WindowsForm在localhost:8081或其他端口返回数据。数据可以很容易地看到通过浏览器输入地址,所有电脑的参数。

如果Silverlight在本地服务器上启用一切正常,当你在外部服务器上运行它时,问题就开始了。

在我的电脑上一切工作正常,但在一些电脑上,一个错误返回"Async_ExceptionOccurred"。

随着网络的发展,Silverlight无法获取clinetaccessppolice .xml,请求已经发送,但没有任何反应,没有返回错误。当然可以直接在浏览器中打开文件。

打开后小提琴虫消失在一些电脑上。

说明clinetaccesspolice和跨域设置正确。

Silverlight在不运行Fiddler的情况下无法下载clientaccessppolice .xml

我找到了一个解决方案。也许这样做不太专业,但可以解决问题。

Fiddler为开发者分享自己的引擎。在PC上使用的程序中使用它。引擎将自动更改代理设置,因此客户端不需要知道任何东西;)

核心

提琴手

// Call Startup to tell FiddlerCore to begin listening on the specified port,
// and optionally register as the system proxy and optionally decrypt HTTPS traffic.
Fiddler.FiddlerApplication.Startup(8877, true, true);
// Call Shutdown to tell FiddlerCore to stop listening on the specified port, and 
// unregister as the system proxy if attached.
Fiddler.FiddlerApplication.Shutdown();