Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Karam Chand
September 4, 2004, 6:15 am
rate this thread
I have a app that connects to MySQL database server. I want to support
SSH port forwarding for security reasons. For this I am using PLINK to
initialize a SSH tunnel session.
I am calling up PLINK from my app using CreateProcess() in the
char appname = "\"c:\temp\plink.exe\" -l user -pw pwd -L
3307:127.0.0.1:3306 -P 22 localhost";
si.cb = sizeof( si );
si.dwFlags = STARTF_USESHOWWINDOW;
si.wShowWindow = SW_SHOW;
prret = CreateProcess ( NULL, appname, NULL, NULL, FALSE, NULL, NULL,
NULL, &si, pi );
pi is passed as a parameter to the function.
After the createprocess statement the console window comes up and I
know it has successfully created a session.
But whatever I do, I cant connect to the MySQL server on port 3307
which it should?
The best part is that if I run plink cmd.exe with the same exact
parameter, I am able to connect to port 3307. Do I need to do
something special to start off plink correctly from my app.
I have searched the groups and everybody seems to have use this
without any problem except me :(
What I am doing wrong?
Please help as my project is kinda stuck without it...
- » ssh on command line: force using a group size (prime size) of 1024 (and no...
- — Newest thread in » Secure Shell Forum