开发者

Suppress the HTTP_X_FORWARDED_FOR http header, c# .net C++

I'm writing an application in C# that uses proxies. The proxies are sending the HTTP_X_FORWARDED_FOR during HTTP requests, and this is unwanted behavior.

I am extending the Interop.SHDocVw axWebBrowser (aka Internet Explorer) control right now, but can take another approach if needed for this problem.

Is there 开发者_C百科some way to suppress this header... can this be done in code, on the proxy server, or not at all?


The proxy server, between your C# client and web site, is adding that HTTP_X_FORWARDED_FOR header.

So, You cannot suppress that on C# client.

But if you have control on proxy server, there should be a setting to turn it off.

For example in squid, following could work.

header_access X_Forwarded_For deny all

Or

You may try to find different proxy services, which does not send your ip address.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜