using a ssh connection in a java app
807603Jan 26 2008 — edited Jan 28 2008Hello,
I have developped an application with a connection to a database through port 9001 (hsqldb database).
When the database is on a server over Internet, I use a ssh connection with the -L option to make a tunnel from the local 9001 port to the distant one.
But I have to launch ssh before to launch my app. Is there a way to do better ? Is there in the java API a way to use a ssh connection with tunneling option ? The solution should work both on windows and Linux (on windows I use Putty to make the tunnel).
Thanks for your advice.
Jean.