Most universities have IP based authentication for access to Journals and index sites (MathSciNet, Web of Knowledge, etc.) If you’re off campus, they usually provide some VPN client (e.g. Cisco) which is quite painful to work with. However, if you have ssh access to a machine on campus, you can access journals very easily.
This method can also be used to access Gmail from China, or any site that is firewalled from the region you are currently in, provided you have
ssh access to a host from which the site is not firewalled.
This should also work on Macs.
Open a terminal and type:
ssh -D9050 email@example.com
Leave the terminal open.
Open a browser and set it to use
localhost:9050 as a SOCKS proxy.
In FireFox go to Preferences / Advanced / Network / Settings (as of 2014-03-03) and
Check Manual proxy configuration
127.0.0.1 into the SOCKS host field, and
9050 into the port field.
Now accessing any site from your browser will make the request appear to come from your campus computer.
Once you’re done with your access to the restricted resources, exit the
ssh connection, and reset your browsers proxy settings to NONE.
Recently (2014-12-22) I found github firewalled from my current location (India).
While the above easily allowed me to access the website from my browser, I couldn’t directly access any github hosted repositories.
Turns out that you can tell
ssh to use a proxy to use a site quite easily:
Install a version of
netcat that support proxies (on Debian systems, install the
netcat-openbsd package; the
netcat-traditional package does not have proxy support, and won’t work in this situation).
~/.ssh/config and add the following:
Host github.com ProxyCommand nc -x localhost:9050 %h %p
ssh -D 9050 ... and leave the terminal open.
ssh connections to this host will use the proxy and circumvent the firewall.
This means you can
git pull happily from your github repositories.
When you’re done, close the terminal window with the ssh connection.
Once your proxies are set up the firefox addon Toggle Proxy allows you to toggle between them painlessly.
As an alternative to the SOCKS proxy, you could set up an SSH tunnel:
ssh firstname.lastname@example.org -L <port>:paywalledjournal.com:<port>
<port> for HTTP access usually being 80.)
Awesome knowledge in this post how to access the network remotely using ssh proxy.