Size: 2580
Comment:
|
Size: 3056
Comment:
|
Deletions are marked like this. | Additions are marked like this. |
Line 3: | Line 3: |
To get Web access to I-MATH intranet webserver it's possible to setup a SOCKS SSH proxy channel. This is setting is not persistent, start it when you need it. | <<TableOfContents>> To get Web access to I-MATH intranet webserver it's possible to setup a SOCKS SSH proxy channel. This is setting is not persistent, start it when you need it. |
Line 12: | Line 14: |
* Use SSH * Linux & Mac OS X: preinstalled. * Windows: https://www.howtogeek.com/336775/how-to-enable-and-use-windows-10s-built-in-ssh-commands/ |
|
Line 13: | Line 18: |
* Use SSH * Linux & Mac OS X: preinstalled. * Windows: https://www.howtogeek.com/336775/how-to-enable-and-use-windows-10s-built-in-ssh-commands/ * Open a terminal and start the SSH Socks connection (I-MATH password): {{{ |
* Open a terminal and start the SSH Socks connection (I-MATH password): {{{ |
Line 25: | Line 26: |
To use the I-MATH internal DNS Server (necessary to get access to hostnames that are only known inside of I-MATH), use the SOCKS5 protocol '''incl. DNS forward'''. | |
Line 26: | Line 28: |
To use the I-MATH internal DNS Server (necessary to get access to hostnames that are only known inside of I-MATH), use the SOCKS5 protocol '''incl. DNS forward'''. |
|
Line 29: | Line 29: |
|| Browser || Command || || Google Chrome || Linux: `google-chrome --proxy-server="socks5://localhost:1080"`<<BR>>Mac OS X: `/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --proxy-server="socks5://localhost:1080"`|| || Opera || Linux: `opera --proxy-server="socks5://localhost:1080"`<<BR>>Mac OS X: `/Applications/Opera.app/Contents/MacOS/Opera --proxy-server="socks5://localhost:1080"`|| |
||Browser ||Command || ||Google Chrome (see also [[https://wiki.math.uzh.ch/public/ProxyBySsh#Advanced_Setup:_Google_Chrome_Proxy_Switch|advanced]]) ||Linux: `google-chrome --proxy-server="socks5://localhost:1080"`<<BR>>Mac OS X: `/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --proxy-server="socks5://localhost:1080"` || ||Opera ||Linux: `opera --proxy-server="socks5://localhost:1080"`<<BR>>Mac OS X: `/Applications/Opera.app/Contents/MacOS/Opera --proxy-server="socks5://localhost:1080"` || |
Line 35: | Line 34: |
Line 42: | Line 40: |
Line 44: | Line 41: |
* A: yes - just check the 'network' seetings. |
* A: yes - just check the 'network' seetings. |
Line 48: | Line 44: |
* A: This is a very quick way to use the proxy. If you do not need it, start the browser via mouse. |
* A: This is a very quick way to use the proxy. If you do not need it, start the browser via mouse. |
Line 52: | Line 47: |
* A: yes. A small bash script should do the trick: {{{ #! |
* A: yes. A small bash script should do the trick: {{{#!sh |
Line 57: | Line 51: |
nohup google-chrome --proxy-server="socks5://localhost:1080" & ssh -C -D 1080 <I-MATH account>@ssh.math.uzh.ch |
nohup google-chrome --proxy-server="socks5://localhost:1080" & ssh -C -D 1080 <I-MATH account>@ssh.math.uzh.ch |
Line 61: | Line 54: |
* Check [[ssh#Working_with_SSH_Keys|SSH Keys]] to setup password less SSH login. | * Check [[ssh#Working_with_SSH_Keys|SSH Keys]] to setup password less SSH login. |
Line 64: | Line 57: |
* A: Create an additional profile 'proxy'. Start Firefox via Terminal `firefox -P`, create the profile, use it and do the proxy config there. | |
Line 65: | Line 59: |
* A: Create an additional profile 'proxy'. Start Firefox via Terminal `firefox -P`, create the profile, use it and do the proxy config there. | == Advanced Setup: Google Chrome Proxy Switch == Install and configure the Google Chrome extension [[https://chrome.google.com/webstore/detail/proxy-switchyomega/padekgcemlokbadohgkifijomclgjgif?hl=en|SwitchyOmega]] to automatically switch proxy for certain URLs. Configurations: {{attachment:switchyOmega_proxy.png}} {{attachment:switchyOmega_autoswitch.png}} |
(Web) Proxy by SSH
To get Web access to I-MATH intranet webserver it's possible to setup a SOCKS SSH proxy channel. This is setting is not persistent, start it when you need it.
The proxy configuration can be done:
on the OS - not described here.
via commandline - described here for Google Chrome and Opera.
inside the browser via GUI - described here for Firefox.
SSH Proxy
- Use SSH
Linux & Mac OS X: preinstalled.
Windows: https://www.howtogeek.com/336775/how-to-enable-and-use-windows-10s-built-in-ssh-commands/
- Open a terminal and start the SSH Socks connection (I-MATH password):
ssh -C -D 1080 <I-MATH account>@ssh.math.uzh.ch
This terminal won't be used anymore, but it has to be open as long as the proxy is in use!
Browser
To use the I-MATH internal DNS Server (necessary to get access to hostnames that are only known inside of I-MATH), use the SOCKS5 protocol incl. DNS forward.
For Google Chrome or Opera, open a second terminal and type the following command.
Browser |
Command |
Google Chrome (see also advanced) |
Linux: google-chrome --proxy-server="socks5://localhost:1080" |
Opera |
Linux: opera --proxy-server="socks5://localhost:1080" |
- Firefox
- There is no officially option '-proxy-server' for the commandline
Start firefox, open 'settings', navigate to 'network' > see screenshot
FAQ
- Q: Can I configure Google Chrome / Opera via GUI like Firefox
- A: yes - just check the 'network' seetings.
- Q: Why should I start Google Chrome / Opera via commandline?
- A: This is a very quick way to use the proxy. If you do not need it, start the browser via mouse.
- Q: Can I automate the steps?
- A: yes. A small bash script should do the trick:
#!/bin/bash nohup google-chrome --proxy-server="socks5://localhost:1080" & ssh -C -D 1080 <I-MATH account>@ssh.math.uzh.ch
- A: yes. A small bash script should do the trick:
Check SSH Keys to setup password less SSH login.
- Q: in Firefox I don't like to toggle the proxy on/off all the time - is there a better way?
A: Create an additional profile 'proxy'. Start Firefox via Terminal firefox -P, create the profile, use it and do the proxy config there.
Advanced Setup: Google Chrome Proxy Switch
Install and configure the Google Chrome extension SwitchyOmega to automatically switch proxy for certain URLs.
Configurations: