My first steps: Linux <-> WIN2000+Delphi 6

Discussion of open issues, suggestions and bugs regarding network security and data protection solution - SecureBridge
Post Reply
teunis
Posts: 48
Joined: Wed 01 Feb 2006 14:15
Location: Curacao

My first steps: Linux <-> WIN2000+Delphi 6

Post by teunis » Tue 12 Jun 2007 00:46

OpenSSH on a linux machine
WITH PuTTY on WIN2000P machine I can make a SSH Connection
and also make a tunnel to 3306 on the linux machine
Authentication is username + password.

Form1 with ScFileStorage1
Path specified to server publickey (see below)
Password empty

ScSSHClient1
Authentication atPassword
Hostname address linux machine
HostKeyName ssh_host_rsa_key.pub
(copied from /etc/ssh/ on linux machine to scFileStorage1.path on Win2000),
User + Password (the same as I use to connect with PuTTY)
ScSSHClient1.Connect gives "Host key not verified"
Can anyone give me a hint?
Thanks Teunis :)

Dimon
Devart Team
Posts: 2910
Joined: Mon 05 Mar 2007 16:32

Post by Dimon » Tue 12 Jun 2007 11:32

The "Host key not verified" message informs that the server key was not found or it is not equal to the received server key.

In your case ScFileStorage can not open the key your have set, as the TScFileStorage class work with keys which saved in itself format. You should import your indicate key in the storage for using.
For that you should select the ScFileStorage component on your form. Perform a double click on it, and create a new key by click the "New" button. Click the "Import from..." button and import the server key. After that set created key name in the HostKeyName property, and connect to the SSH server anew.

Also you can use the ImportFrom method for import key in run time.

teunis
Posts: 48
Joined: Wed 01 Feb 2006 14:15
Location: Curacao

Post by teunis » Tue 12 Jun 2007 13:15

The publickey of the server has been imported
On ScSSHClient1.Connect I get now "Authentication failed"
User and Password are the same as with PuTTY
Dimon will you be so kind and give me one more hint?
Thanks Teunis
:?:

teunis
Posts: 48
Joined: Wed 01 Feb 2006 14:15
Location: Curacao

Post by teunis » Wed 13 Jun 2007 20:05

On the linux machine I changed the sshd_config

#Authentication
PasswordAuthentication yes
#the default value is no

Now I can connect
Next step to find out is the authentication with public keys
:D

Post Reply