A simple daemon checks every 20 seconds if a plink ssh tunnel (with port forwarding) is still alive, if not it is re-established.
Platform: ms-winThis can be useful as a quick solution on ms-win client machines.
The Script relies on plink.exe and pskill.exe, which are not included here. Use the links on the right to get plink.exe and pskill.exe.
Platform: unix and othersplink is also available for unix systems. It should be easy to modify the script.
Client configThere is a config section at the beginning of telnet.py:
TESTHOST = "127.0.0.1" TESTPORT = "2121"
TELNET_TIMEOUT = 10
PSKILLPATH = 'c:\\Programme\\pylink\\pskill.exe'
You also have to adjust the connect.cmd, insert your ssh username and password and the server:
plink -l root -pw mysecretpass -D 127.0.0.1:1080 -L 127.0.0.1:2121:localhost:21 server.example.com
In this example the -D is a proxy forwarding. (So in this case we want to use the server as a socks 5 proxy). The second forwarding -L (Port 2121) is only used to test if the tunnel is still alive (see TESTHOST and TESTPORT in telnet.py).
Server configYou need an ssh server running and some service on the server that can be checked with telnet. This service needs to accept tcp connectins from localhost only, and for testing the connection is just opened and closed immedeateley. Could be a webserver or an ftp server.
Use Patent Claims
Include Install Instructions
These details are provided for information only. No information here is legal advice and should not be used as such.