EldoS | Feel safer!

Software components for data protection, secure storage and transfer

TELSimpleSSHClient.Open() freezes system for 30 seconds

Also by EldoS: Rethync
The cross-platform framework that simplifies synchronizing data between mobile and desktop applications and servers and cloud storages
Posted: 02/20/2015 12:29:14
by hillrom (Standard support level)
Joined: 09/18/2014
Posts: 1

For some reason, on an imex35 running Windows CE 6.0, calling TELSimpleSSHClient.Open() causes the whole application to freeze for 30 seconds, CPU jumps to 100%.

This is for version

I know that the simpleSSHClient is synchronous, but 30 seconds seems excessive. The SSHClient is connecting directly to an ethernet device on a USB dongle.

Is this normal behavior?

Here is the code

                // Configure the SSH client.
                _SshClient = new TElSimpleSSHClient();
                _SshClient.Address = ModuleIpAddress;
                _SshClient.Port = ModuleSshPortNumber;
                _SshClient.UseInternalSocket = true;
                _SshClient.AuthenticationTypes = SBSSHConstants.Unit.SSH_AUTH_TYPE_PASSWORD;
                _SshClient.Username = ModuleUsername;
                _SshClient.Password = ModulePassword;

                // Register the required event handlers.
                _SshClient.OnError += OnSshClientOnErrorEvent;
                _SshClient.OnCloseConnection += new SBSSHCommon.TSSHCloseConnectionEvent(OnSshClientOnCloseConnection);
                _SshClient.OnAuthenticationSuccess += OnSshClientOnAuthenticationSuccessEvent;
                _SshClient.OnAuthenticationFailed += OnSshClientOnAuthenticationFailedEvent;
                _SshClient.OnKeyValidate += OnSshClientOnKeyValidateEvent;

                // Open the SSH connection with the WB45 module.
Posted: 02/20/2015 13:39:48
by Eugene Mayevski (EldoS Corp.)

There are several reasons possible. First there's socket connection established, then there's SSH handshake done (which involves some cryptographic operations). 30 seconds is surely too much but it is possible that it's socket layer causing the delay for whatever reason (and it would be nice to check this).

First of all let's try the same code on desktop (possibly with the sample application or with your code, -- it doesn't matter much). Will it work correctly?

Sincerely yours
Eugene Mayevski



Topic viewed 474 times

Number of guests: 1, registered members: 0, in total hidden: 0


Back to top

As of July 15, 2016 EldoS Corporation will operate as a division of /n software inc. For more information, please read the announcement.

Got it!