If you have comments or thoughts about my blog, you can contact me at my lab here:
Uber Admin Tip: Instant SOCKS proxy.
Ok, so you have an SSH account back at school on your ubuntu computer and you set up apache on port 80, but forgot to config your firewall to let port 80 traffic in and drove the 50 minutes through traffic home only to find you forgot and may have to drive back to school. What to do? Thanks to OpenSSH you can create a down and dirty SOCKS Proxy over an encrypted SSH connection from your home computer.
No Really, this is literally a one liner! Here is what we will do:
First we will create an SSH connection to our machine back at school, while redirecting a local port over the SSH connection.
ssh -D 9999 firstname.lastname@example.org -p 22
This essentially forwards localhost port 9999 to your school machine. Now thats all well and good but how can we get at the Firewall from our work machine, ssh is not a VNC connection. Well since our machine at school connects to the firewall on 192.168.123.1 over a web browser, we simply open our SSH connection above and then configure mozilla to use a SOCKS proxy of localhost port 9999. Then enter 192.168.123.1 into firefox and magically you will be connected to your lab firewall from inside allowing you to access it so you can open your web port and see your web page.
Recent blog posts
- Easy exporting of Drupal 7 custom fields for use in module code.
- Midnight Commander on OS-X
- Get lists of NIDs from DB filtering by fields without having to do joins - Hello "Entity Field Query"
- Setting the maximum upload size or php memory for Drupal 7
- Charts and Graphs in Drupal 7
- Restore a LVM image to LVM direct from gzip to LVM with a progress bar
- Check if port XXX is listening on your server
- Fix slow SSH response on your Ubuntu Server
- Things i like to do to Ubuntu to make it rock.
- Find and eliminate rogue or ghost KVM Virtual machines under Cloudmin