SSHServer events in C# console application - WeOnlyDo Discussion board

SSHServer events in C# console application (General questions)

by gumma, Wednesday, February 02, 2005, 11:35 (7031 days ago)

Hello,

I am trying out evaluation version of SSHServer.
I need to wrap a proprietary protocol to secure communication.
It works fine in a winform application but not in console application... The server starts but no event is raised when a client tries to connect to the server. Have I missed something?

Source code is very simple:

static void Main(string[] args) {
// ...
sshServer = new wodSSHDClass();
sshServer.Connecting += new _IwodSSHDEvents_ConnectingEventHandler(sshServer_Connecting);
sshServer.Start(myPort);
// ...
}

private static void sshServer_Connecting(SSHUser user, ref SSHActions action) {
Console.WriteLine( Connection... );
}


Thanks


Complete thread: