Force programs to use & go through proxy

24

13

My school requires a proxy for all internet access. If you want to use the internet, it is impossible to not use a proxy. This makes it a problem for many programs that don't seem to let you enter proxy settings.

How can I use Steam when I am behind a proxy? Is it possible to somehow enter the details into a configuration file, or force it to get the settings from Internet Explorer?

If not, does software exist for creating a 'virtual' network adapter which will pass all traffic (or all protocol x traffic) through the proxy?

Although I am facing this specific problem on Windows 7, solutions for all operating systems are welcome.

Josh Hunt

Posted 2009-08-05T10:56:23.813

Reputation: 20 095

Question was closed 2020-02-26T18:03:25.050

Just curious, why to use Steam at school? – Kirill V. Lyadvinsky – 2009-08-05T11:29:54.230

JIa3ep: To play games on? Often our teacher organizes mini LAN 'parties' with sucky mac games. – Josh Hunt – 2009-08-05T14:04:54.000

there is 'bypass proxy client' mentioned here, haven't tried it though and apparently the free version isn't that good and the paid version is subscription http://www.pcmag.com/article2/0,2817,1683712,00.asp

– barlop – 2013-12-19T21:54:33.957

Answers

8

Check out Proxifier. Combined with an SSH tunnel, you should be able to get most programs through any proxy.

My school (and all the others in my state) have a quite elaborate web filtering proxy set up which blocks most ports on the other side of the proxy. I managed to get around it using a combination of the programs mentioned above on Windows.

Just create an SSH tunnel using Putty as necessary, and then set Proxifier to use the tunnel as its proxy. This should route traffic of all ports through the proxies.

Josh Hunt

Posted 2009-08-05T10:56:23.813

Reputation: 20 095

2I wish there would be something like this for commercial use and free. The alternatives do not work at all (on our VPS). – Martin Braun – 2014-07-16T18:54:00.373

2Note, this is not a free solution as "Proxifier" requires payment. – Zoran Pavlovic – 2014-11-07T12:39:29.610

I tried to do this myself on OS X but the client just wouldn't connect. Turns out you need to launch Steam with the -tcp option as described in this answer. It seems that since 2009 things have changed. I bet this applies to Windows too.

– 2rs2ts – 2016-04-15T06:55:35.650

1Where do you point the tunnel endpoints? – Michael Caron – 2012-01-24T17:41:09.580

3

My tun2socks software (Linux, Windows) creates a virtual network interface that forwards all incoming TCP connections through a specified proxy server. It can only use a SOCKS proxy, and by default can only forward TCP, though UDP can be forwarded too if you are able to run my udpgw forwarder somewhere behind the SOCKS. Assuming you meet those requirements, here's how you can set it up:

First create the virtual interface and configure it. On Linux:

openvpn --mktun --dev tun0 --user <your_user>
ifconfig tun0 10.0.0.1/24

Or, on Windows, just install OpenVPN to get the TAP-Win32 virtual interface, and assign it IP 10.0.0.1, netmask 255.255.255.0.

Then start tun2socks, which does the actual forwarding:

badvpn-tun2socks --tundev tun0
  --netif-ipaddr 10.0.0.2 --netif-netmask 255.255.255.0
  --socks-server-addr <socks_server_address>:<socks_port>

Here, 10.0.0.2 is the IP of the virtual router inside the virtual interface. It must be in the same subnet as, and different from, the one assigned to the virtual interface itself (10.0.0.1/24). On Windows, instead of tun0, use:

--tundev "tap0901:<display_name_of_TAP-Win32_device>:10.0.0.1:10.0.0.0:255.255.255.0"

At this point you should be able to ping the virtual router 10.0.0.2 (in which case the running tun2socks program will be the one to respond). To forward connections through the proxy, all you have to do is route them through the virtual device. On Linux:

route add default gw 10.0.0.2 metric 0

Or on Windows:

route add 0.0.0.0 mask 0.0.0.0 10.0.0.2 metric 0

The critical part here is that the route overrides any existing default route. Also, if your SOCKS server is not on the local network, you have to add an exception route with higher metric to prevent connections from being routed back into the virtual interface. See the link at the top for more information.

Ambroz Bizjak

Posted 2009-08-05T10:56:23.813

Reputation: 4 265

I can't get this working on Windows, I believe I'm using the correct values per your instructions, however: http://i.imgur.com/Q17GOJr.png I also checked 'Hardware Ids' show the value of 'tap0901'

– deed02392 – 2013-10-05T21:01:07.623

@deed02392 That is strange. Some things to check: Is your device really a TAP-Win32 device, as installed by the OpenVPN driver? Are you using the newest OpenVPN version? Also try renaming the device to something short like "TAP", but I think it shouldn't matter. – Ambroz Bizjak – 2013-10-05T22:01:46.447

@deed02392 Someone also made a GUI for tun2socks (google it), you can try that, but I can't make any assurances about its quality. – Ambroz Bizjak – 2013-10-05T22:02:32.543

@deed02392 If you want to debug this, here's some instructions on ideone to stop spamming the comments, http://ideone.com/vSupRi

– Ambroz Bizjak – 2013-10-05T22:22:40.010

Interesting, it's called Local Area Connection 3 in registry. Swapping the name for that and it's working immediately... – deed02392 – 2013-10-06T09:36:33.330

1

To the best of my knowledge, Steam uses the default proxy settings in Internet Explorer. You can run into issues if you use a proxy script, but they're easy to work around. Just dig around in the script for the proxy addresses and set them up as your proxies, and Steam should work just fine.

If you continue to have issues, you should look on the Steam forums. Valve's Steam developers typically troll the tech support/help forums and provide assistance where necessary.

If you're having issues with individual Steam games, you're probably out of luck, since they tend to use specific ports.

Andrew Scagnelli

Posted 2009-08-05T10:56:23.813

Reputation: 1 777

2It doesn't use the system proxy settings (just checked with Wireshark). – Etienne Perot – 2011-12-29T23:58:24.587

1

Your best bet is to set the proxy info in Internet Settings in control panel, if your Uni uses a proxy configuration script then you can navigate to that file in your web browser and check out the manual settings or you can run with the script and hope for the best. Steam should work after that. My uni only recently prevented non-proxy steam access so that they could throttle steam download speeds... :(

rollinginsanity

Posted 2009-08-05T10:56:23.813

Reputation: 11

0

For Windows there is a free utility, called KKcap:

KKCap, a free proxy software Providing support to SOCKS5, Shadowsocks, etc. A free alternative to proxy software like Proxifier or SSTap. Also a light-weight alternative to VPN. Supports from Windows XP to Windows 10. Redirect connections from of any internet app.

You should configure it for programs which you want to go through your proxy.

T.Todua

Posted 2009-08-05T10:56:23.813

Reputation: 2 436

0

Not all proxies don't allow all ports to be accessed so what you describe isn't actually possible.

If you can access https:// URLs and have access to a machine on the outside then you could set up a VPN server on the external machine and run a VPN on your machine to tunnel all traffic through that server. You will be able to access this server as long as you run the VPN on port 443 and it uses SSL for handshaking.

I've done this before on Linux but using SSH but it's certainly possible on Windows (provided you can find a free VPN that supports the above).

Mike McQuaid

Posted 2009-08-05T10:56:23.813

Reputation: 3 639