Socks Proxy On Linux
Page 1 of 1
Socks Proxy On Linux
Set up the SSH tunnel
We’ll create an SSH tunnel that will securely forward traffic from your local machine on port- Code:
9090
- Code:
22
- Code:
1024
Linux and macOS
If you run Linux, macOS or any other Unix-based operating system on your local machine, you can easily start an SSH tunnel with the following- Code:
ssh
- Code:
ssh -N -D 9090 [USER]@[SERVER_IP]
- Code:
-N
- Code:
-D 9090
- Code:
[USER]@[SERVER_IP]
- To run the command in the background use the
- Code:
-f
- If your SSH server is listening on a port other than 22 (the default) use the
- Code:
-p [PORT_NUMBER]
Once you run the command, you’ll be prompted to enter your user password. After entering it, you will be logged in to your server and the SSH tunnel will be established.
You can set up an SSH key-based authentication and connect to your server without entering a password.
Windows
Windows users can create an SSH tunnel using the PuTTY SSH client. You can download PuTTY here .- Launch Putty and enter your server IP Address in the
- Code:
Host name (or IP address)
- Under the
- Code:
Connection
- Code:
SSH
- Code:
Tunnels
- Code:
9090
- Code:
Source Port
- Code:
Dynamic
- Click on the
- Code:
Add
- Go back to the
- Code:
Session
- Code:
Saved Session
- Code:
Save
- Select the saved session and log in to the remote server by clicking on the
- Code:
Open
A new window asking for your username and password will show up. Once you enter your username and password you will be logged in to your server and the SSH tunnel will be started.
Setting up public key authentication will allow you to connect to your server without entering a password.
Configuring Your Browser to Use Proxy
Now that you have open the SSH SOCKS tunnel, the last step is to configure your preferred browser to use it.Firefox
The steps below are the same for Windows, macOS, and Linux.- In the upper right-hand corner, click on the hamburger icon
- Code:
☰
- Click on the
- Code:
Preferences
- Scroll down to the
- Code:
Network Settings
- Code:
Settings...
- A new window will open.
- Select the
- Code:
Manual proxy configuration
- Enter
- Code:
127.0.0.1
- Code:
SOCKS Host
- Code:
9090
- Code:
Port
- Check the
- Code:
Proxy DNS when using SOCKS v5
- Click on the
- Code:
OK
At this point, your Firefox is configured and you can browse the Internet through the SSH tunnel. To verify, you can open
- Code:
google.com
To revert back to the default settings go to
- Code:
Network Settings
- Code:
Use system proxy settings
There are also several plugins that can help you to configure Firefox’s proxy settings such as FoxyProxy .
Google Chrome
Google Chrome uses the default system proxy settings. Instead of changing your operating system proxy settings you can either use an addon such as SwitchyOmega or start Chrome web browser from the command line.To launch Chrome using a new profile and your SSH tunnel use the following command:
Linux :
- Code:
/usr/bin/google-chrome \
--user-data-dir="$HOME/proxy-profile" \
--proxy-server="socks5://localhost:9090"
Re: Socks Proxy On Linux
In Kali Linux machine let’s run the command to connect with the Ubuntu using Dynamic SSH tunnelling.
- Code:
ssh -D 7000 raj@192.168.1.108
- Code:
ssh -L 7000:192.168.22.129:80 raj@192.168.1.108
Last edited by jamied_uk on 7th February 2022, 07:14; edited 1 time in total
Similar topics
» Firewall For Security Linux Kali Linux & Mint
» proxy page
» Windows Proxy Server
» Setting up Squid proxy software
» torrent proxy for downloading music tv films games software etc
» proxy page
» Windows Proxy Server
» Setting up Squid proxy software
» torrent proxy for downloading music tv films games software etc
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum
|
|