How to set SQUID Proxy authentication using netsh?

2019-06-10 05:26发布

I am behind a SQUID proxy. I need to set proxy settings for cmd. I'm using win7 so proxycfg cannot be used. I used netsh like this: netsh winhttp import proxy source=ie

Internet explorer had my proxy settings already. Now the problem is that my proxy requires username/password authentication. I do not know how to set the username and password in command prompt. Any help would be greatly appreciated.

Thanks in advance,

2条回答
老娘就宠你
2楼-- · 2019-06-10 05:54

Here is the solution my friend

Install CC Proxy. This software created a local proxy server on my PC. I used my own IP address as my proxy server in LAN settings and this enabled me to access the internet without asking for proxy everytime as CCproxy used my campus proxy as the cascading proxy.

Type in the netsh command in prompt so that the apps start using the local proxy. (no authentication on local proxy due to CC Proxy)

netsh winhttp import proxy source=ie Metro apps are programmed to prevent access of internet through a local proxy.

Also, set

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\NlaSvc\Parameters\Internet\EnableActiveProbing to 0 and then go enable the following options in the Group Policy:

Open "Local Group Policy Editor" (gpedit.msc) Navigate to "Computer Configuration - Administrative Templates - Network Isolation". Enable "Proxy Definitions Are Authorative" and "Subnet definitions are authorative".

follow me on twitter @smailbelhamidi

查看更多
唯我独甜
3楼-- · 2019-06-10 05:59

I've been having a similar problem lately. I actually gave up trying to find out if you could use netsh to set username/password for proxies that require authentication as I couldn't find any instructions (which suggested to me it's not possible).

One option I've seen suggested elsewhere is to use software such as Proxifier to direct traffic for all applications via your proxy server. I've not tried this myself so apologies if it doesn't work.

If you have admin access to the Squid proxy server you can configure it to allow access to particular sites without authenticating. This is how I got round the problem. Details on how to do this can be found on the squid wiki page below:

http://wiki.squid-cache.org/ConfigExamples/Authenticate/Bypass

查看更多
登录 后发表回答