Bypass firewall rules

  about 266 words   1 min

SSH <3

At work, they changed a firewall and added a rule to block Youtube. I'm fine with that but some colleagues are quite annoyed by that change. They really want to watch tutorials or kitten on Youtube.

What I like about ssh is how it helps you to bypass a lot of things πŸ˜‰

What a lot of people don't know about ssh is that it include a SOCKS proxy out of the box that you need to configure in your browser to bypass a restriction. You only need a ssh server somewhere to connect to.


  $ ssh -D 3128 -f -C -q -N user@ssh_server

  -D 3128 tells ssh to launch a SOCKS server on port 3128 locally.
  -f forks the process into the background.
  -C turns on compression.
  -q enables "Quiet mode", since the purpose here is only to tunnel we don't really care about error output and such.
  -N tells ssh that no commands will be sent (-f complains if we don’t specify this).

Then you just need to configure your app that need to use that tunnel. In our case, we'll use firefox :

Go to the Preferences -> General -> Network Proxy. Check the “Manual proxy configuration” and add in the “SOCKS Host : 127.0.0.1 port : 3128”

Sometimes some DNS requests can be filtered too, for this you can also tunnel them through our little proxy. Here is the manual configuration in the about:config in firefox :


  network.proxy.socks : 127.0.0.1
  network.proxy.socks_port : 3128
  network.proxy.socks.remote_dns : true
  network.proxy.socks_version : 5
  network.proxy.type : 1

Tadaaaa … Enjoy your movies !


ssh firewall CLI tools tips
STORIES BASED ON SAME TAGS

Imagemagick - a swiss army knife for manipulating images

There is a CLI tool I use often to manipulate images, its name is Imagemagick. You can install it with any package management system you have depending of your OS. Imagemagick is also used in a lot of libraries to render images for various purposes. Here is a list of commands I use quite often when I need to edit some images.

Read more

Using Timewarrior With Taskwarrior

Terminals have always been a thing that I loved to use. I spend a lot of times using and tweaking them. i My daily use include a lot of this little programs that help you to improve your productivity. Keybindings and customizations is also one thing that I love about terminals compared to GUI. That's also why I awesomewm. For those who don't know what it is, it's a lightweight tiling window manager like Ion.

Read more

What aliases do you use ?

Here is a list of aliases I use more or less frequently. Aliases and shell functions is a thing that I couldn't live without. It helps you type less to do more. I've been using zsh for a while now and I've never been a real fan about bash. Prior to that shell I used to work with diferrent ksh variants.

Read more