if you can ssh into ur server that means you can use a proxy!!! to browse internet @_@ bypass your (bad) internet restriction(???)
understanding ssh forwarding
forwarding?
port forwarding, tunneling, something like that. Basically makes you access a place where you previously cant, through an middleman that can. you dont necessarily have to connect one, or both ends of the ssh connection to the internet.
ssh?
oh no
ssh is secure shell. basically it is your terminal streamed over the internet BUT it is secure encrypted and you are not to worry.
to set it up you need to generate a private key, secure that key (af), then in the server install and run ssh server, then paste the content of the public key to a file or some files in there. then config ssh client so it uses the private key for the server (and while ur at it a nickname too). then connect.
i think you know this already. you dont? what are you doing
a server can pretty much be your windows computer btw, well cuz a server is just a computer. it doesnt even need to run 24/7 (normally you want it to run 24/7 tho)
ssh forwarding
https://unix.stackexchange.com/a/115906 this is the only post you need.
read it
the format we are going to use is ssh [-L|-R] fromPort:ipTo:toPort user@host and specifically ipTo = 127.0.0.1 (localhost).
what is going on:
for -L, After running this code, you the client can access 127.0.0.1:fromPort, ssh will forward that to the server (the host), the server will access ipTo:toPort, then all responses go back to the client.
for -R, its the Server trying to connect to 127.0.0.1:fromPort, sshd captures that, sends it to you the ssh -R runner, you connect to destination at ipTo:toPort, and send responses back to the server.
you can put a ipFrom before the fromPort so you connect to the ipFrom instead of localhost
so where does it help with proxying:
doing the proxy
squid caching / proxy server
right now just know that
On the server:
install and run squid
first, install squid. sudo dnf install squid, or whatever package manager you use.
second, run squid.
maybe run sudo systemctl enable squid
By default squid will take port 3128 check if it is different for you / squid cant run maybe maybe with sudo systemctl status squid
third. forget configuring. As you are going to be using ssh -L, and default squid conf allows localhost (only, in fact), you are already good to go.
On the client:
do the command
ssh -L 12345:127.0.0.1:3128 -Nf user@serverhost (12345 is an example port id suggest 3128)
boom. check your localhost:12345. its the squid error page. youve done it.
connect to proxy
setup proxying: (windows for me) go to Network & Internet > Proxy, manual, toggle it on, 127.0.0.1, 12345, save.
so simple.
you can set it up on firefox, or maybe your settings have proxy settings too. find it yourself
no more proxy?
turn it off from the same settings page.
maybe idk find your ssh process from the task manager (its the backgrounding effect of -Nf) and kill it.
comment below!