Trying the SSH component - WeOnlyDo Discussion board

Trying the SSH component (wodSSH / wodSSH.NET)

by Jef, Wednesday, November 01, 2006, 15:08 (6396 days ago)

Hi,
I have been trying all day to get the SSH component sample called Public Key Authorization to connect to my SSH server...unsucessfully.
I use DSA (private) keys. There is no doubt I have the same key/password on both sides. But the sample always answers that the username, password or key do not match...I have tried jsut about very combination!
Simple : if I get it to work, I buy it.
Jef

Re: Trying the SSH component

by wodSupport, Wednesday, November 01, 2006, 19:00 (6396 days ago) @ Jef

Jef,

what kind of SSH server are you running? Did you upload public key t o proper place on the server? That is requried so that server knows who you are.

Kreso

Re: Trying the SSH component

by jef, Thursday, November 02, 2006, 09:09 (6395 days ago) @ wodSupport

Hi,
yes I do import the key. What I do is :
1. I generate a DSA key from your GUI and save it to a file
2. I open the file and copy paste the private key into my SSH server.
3. the SSH server checks the key/password and accepts it : so the key is properly imported. I then set this key to be the active one for SSH.
4. I try to connect from your GUI by typing the IPAddress of the server and the username. But I never get as far as to get a request for password.
Please note that if I de-activate key/password authentication on my server: it works! So it is definitely a problem of certificate.
thank you
Jef

Re: Trying the SSH component

by wodDamir, Thursday, November 02, 2006, 09:25 (6395 days ago) @ jef

Jef,

When you set server to authenticate with PrivateKey, you usually don't need password, and that is why you aren't requested to provide one.

If you need to authenticate using both the login/password and PrivateKey, then you need to set Authentication Property to authBoth .

Also, what server are you using?

Regards,
Damba

Re: Trying the SSH component

by Jef, Thursday, November 02, 2006, 12:12 (6395 days ago) @ wodDamir

It is made by my employer and integrated in a box we have.

Yes, I found out that if I set authentication to 'password' on my server and the program, it works. But if I set both to PubKey, then it does not work. It appears that both key just do not match and I do not manage to get them to match either!
Am I right to open the saved file from your program an copy/paster it on my server ? Otherwise I have tried to export from my server, which would give something like this :

-----BEGIN INTERNAL CKM PRIVATE KEY-----
Proc-Type: 4,ENCRYPTED
DEK-Info: DES-EDE3-CBC,BC84AC603D654F0A

FVMnHKZeMzn550JrErVnSLwqOmPqmUxRJNoVjmkTs8Mitzc1J6KgIJ5L5UTxtzOA
wvaKS0SlzIwkR2nSCKD1ehtw7o1sgFfma4SZ/MwvROhon+nbg4X16i/LNZgYOLgt
VVZ5EGfRT5axLVdi1xSankIGH+NufJ1W6JGqgzpEJjKAd4x8QKIorRfL+kGsMerb
JFZiaACNwZ/bidoLqqS29N23mStP7sH/5pTdtOBptCwlfBoT1MqhmokKYk177x5D
85uAkuCPp6IJL+1PkMMKS0O4sPgvitt/AgMJbcls/nA3AXuhfm1wLJ0LjkTCIzT0
GpBHwPkR3V9c9/RSgI2CU+E+NaRBymaIWsQVDK3kqPgfIQrfs5GQ7JpF1wGxgfy3
bVvnVxhT3Fkw2wUD5qdUhYaZQMP6hvjn+7mUmC4C4+ui39hwT2KV7+Yhtu2HqSKj
h0szU/dO6Vgyq9tZXarvmbyj4yibsZDGbtolS+/+s2jlb4WWU17CqizyB5J8aBun
GLwfjXpbw/or2E/lZQqOfCi3dVnW17Cyi1iOladerxeFLjiCUiFeLjRHCHchKMx7
xoMMeucwh/Ciqnq6EHrwz0fQbz8RUU+s
-----END INTERNAL CKM PRIVATE KEY-----

Copy it to a file and load it, but it does not work either!


thanks
Jef

Re: Trying the SSH component

by wodDamir, Thursday, November 02, 2006, 12:26 (6395 days ago) @ Jef

Jef,

No, you cannot use the same key on client and server. The server uses PublicKey, and Client should use PrivateKey. They aren't the same.

When you use the Sample you mentioned, you should click Generate New Key . The PublicKey (for server) will be shown in TextBox. Import that key into your server. After that, specify file where you want to save your PrivateKey (Client key) and click Save key .

After that, you should be able to to login to server using the sample.

Regards,
Damba