Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Environment :linksys wrt300n v1.1 which can have ddwrt-mega. Willing to tunnel all lan's outbound traffic through an ssh tunnel.

share|improve this question

migrated from stackoverflow.com Jul 27 '12 at 2:32

This question came from our site for professional and enthusiast programmers.

1  
Not programming related. Perhaps try on SuperUsers. –  pst Jul 25 '12 at 0:12

2 Answers 2

You can tunnel a specific port with a reverse shell. The direction is important. For example ssh -R 80:localhost:80 user@www.host.de. This will connect your localhost port 80 to the port 80 from the host and it will send all network packets from port 80 to your port 80. When you need you can do the other way around.

share|improve this answer

To tunnel all outbound LAN traffic, follow these steps:

  1. Run script in the form ssh -D <localport> <remotehost>. E.g. ssh -D 8080 ssh-user@server-ip. Here, 8080 is source port on which SOCKS server listens. It'll perform Dynamic Port Forwarding.

  2. Setup a proxy from GUI of router. The proxy server detail: IP is local/private IP of router (where script of step 1 runs) and port is the port specified in script of step 1.

Done!

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.