RE: Remote connection to linux server
- Subject: RE: Remote connection to linux server
- From: "Charles@Hinet" <cylee@xxxxxxxxxxxxxx>
- Reply-to: libssh@xxxxxxxxxx
- Date: Tue, 19 May 2015 18:14:48 +0800
- To: <libssh@xxxxxxxxxx>
What version are you using?
I got the same error on 0.7.0, but 0.6.5 was OK on Windows 7/2012R2.
From: Gigin Jose (RBEI/EIA1) [mailto:Gigin.Jose@xxxxxxxxxxxx]
Sent: Tuesday, May 19, 2015 4:17 PM
Subject: Remote connection to linux server
I am trying to use libssh library for developing ssh client application on
windows PC. The client application connects to ssh server running on remote
ubuntu linux PC. The authentication system on the remote ubuntu is using a
username and password.
Is it possible to establish the remote connection using libssh library.
My following code gives me an error connecting to the remote host:
char *password = "pass123";
unsigned char *hash = NULL;
ssh_session my_ssh_session = ssh_new();
if (my_ssh_session == NULL)
int verbosity = SSH_LOG_PROTOCOL;
int port = 22;
set_options = ssh_options_set(my_ssh_session, SSH_OPTIONS_HOST,
set_options = ssh_options_set(my_ssh_session,
set_options = ssh_options_set(my_ssh_session, SSH_OPTIONS_PORT,
ssh_options_set(my_ssh_session, SSH_OPTIONS_USER, "user");
rc = ssh_connect(my_ssh_session);
if (rc != SSH_OK)
fprintf(stderr, "Error connecting to localhost: %s\n",
fprintf(stdout,"CONNECTION ESTABLISHED !! \n");
rc = ssh_userauth_password(my_ssh_session, "user", password);
The error says: Error connecting to localhost: crypt_set_algorithms2: no
crypto algorithm function found for 3des-cbc. The api ssh_connect()return
-1, and the api ssh_userauth_password retruns 4.
Why is this ? Do I need to use separate libraries for authenticating with
Archive administrator: firstname.lastname@example.org