亲爱的朋友们, 如何在Windows中使用C ++和C语言获取http代理IP地址和端口号。 请允许任何人帮我解决这个问题。 谢谢, S Shanmuga Raja 我尝试过: 我尝试了一些MSDN - 微软的例子。但这对我的问题没有用。
Dear Friends, How to fetch http proxy IP address and port number using C++ and C language in Windows. Please can anyone help me on this issue. Thanks, S Shanmuga Raja What I have tried: I tried out some of the MSDN - Microsoft example. But it is not work out for my problem.
推荐答案参见WinHttpGetDefaultProxyConfiguration功能(Windows) [ ^ ]。 另请阅读注册表包含Windows HTTP代理设置的密钥。关键是 See WinHttpGetDefaultProxyConfiguration function (Windows)[^]. Alternatively read the registry key that contains the Windows HTTP proxy settings. The key is HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\
,该值以 ProxyServer 中的文本形式存储(来源:如何使用注册表文件配置客户端代理服务器设置 [ ^ ])。 请注意,某些应用程序(通常是所有浏览器)都允许设置自己的代理,而不是使用为系统配置的代理。然后,您必须阅读这些应用程序的配置。
and the value is stored as text in ProxyServer (source: How to configure client proxy server settings by using a registry file[^]). Note that some applications (usually all browsers) allow setting their own proxy rather than using the one configured for the system. Then you have to read the configuration for those applications.
更多推荐
以编程方式使用C ++ / C获取HTTP代理和端口号
发布评论