WebRequest.DefaultWebProxy.GetProxy(uri)不一致 [英] WebRequest.DefaultWebProxy.GetProxy(uri) inconsitency

查看:88
本文介绍了WebRequest.DefaultWebProxy.GetProxy(uri)不一致的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


与大公司客户合作,我发现:

Working with a big corporate customer, i found that :


WebRequest.DefaultWebProxy.GetProxy(uri)

WebRequest.DefaultWebProxy.GetProxy(uri)


返回正确的代理后,突然返回uri。这可能发生在几个小时或几天之后。

after returning the correct Proxy, is suddenly returning the uri. This can happen after a few hours or few days.


Cany有人能让我高兴吗?怎么可能..

Cany anyone enlight me ? How possible..


谢谢

推荐答案

嗨Jweizman2606,

Hi Jweizman2606,

感谢您发布此处。

对于您的问题,如果您的GetProxy(Uri目的地)方法的目的地不在$ b $中b
BypassList

WebRequest
实例使用代理服务器和
返回地址
属性。

For your question, if the destination of your GetProxy(Uri destination) method is not in BypassList, the WebRequest instance uses the proxy server and the Address property is returned.

请检查MSDN文档中的备注。

Please check the remarks in the MSDN document.

https://docs.microsoft.com/en-us/dotnet/api/system.net.webproxy.getproxy?view=netframework -4.7.2

最好的问候,

Wendy


这篇关于WebRequest.DefaultWebProxy.GetProxy(uri)不一致的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆