Stern inaktivStern inaktivStern inaktivStern inaktivStern inaktiv
 

Usually you just start one VPN on your system to get through a firewall. But if you have to go through a second firewall later it's difficult to configure. That's a common situation if you first have to go through a company or country firewall and then enter your home network which is protected by a firewall. As long a you use a Linux system and a system in your target network protected by a firewall offers ssh access there exists an easy way to get it done.

 

There is a nice tool called sshtunnel available. You start your first VPN and then start sshtunnel. This tool uses the existing VPN and connects via ssh to a system in the second target network and creates a tunnel in the already active VPN  connection. Works like a charm.

 

I created a small script which starts sshtunnel with customizable environment variables.

 

#!/bin/bash

TARGET=<ssh target host>
TARGET=<dyndns IP of target>
TARGET_PORT=<ssh target port>
TARGET_USER=<ssh target userid>
NS=<remote nameserver>

sshuttle --dns -vNHr $TARGET_USER@$TARGET:$TARGET_PORT -x $TARGET 0/0

Kommentar schreiben

*** Hinweis ***

Kommentare sind erwünscht. Aber um lästige Spamposts abweisen zu können gibt es ein paar Dinge die zu beachten sind:
  1. Kommentare mit dem Text http werden sofort zurückgewiesen mit der Meldung Sie sind nicht berechtigt den Tag zu verwenden. zz
  2. Kommentare werden manuell überprüft und es dauert deshalb in der Regel einen Tag bis sie veröffentlicht werden.