publickey auth - WeOnlyDo Discussion board

publickey auth (wodSSHServer)

by Jeff, Tuesday, March 28, 2006, 02:14 (6598 days ago)


I am trying to verify the public key sent over a SSH connection (from the private key on the client side) in the LoginPubKey event, and I don't know what steps to take to compare the PublicKey to the one in a file.

Help!

Re: publickey auth

by Jeff, Tuesday, March 28, 2006, 02:17 (6598 days ago) @ Jeff


This is the example I am looking at right now.

Private Sub wodSSHD1_LoginPubkey(ByVal User As
wodSSHDComLIB.ISSHUser, ByVal Login As String, ByVal
PublicKey As String, Action As wodSSHDComLIB.SSHActions)
If Login = joe And PublicKey = ssh-rsa
AAAAB3NzaC1.....A5dxuzFobhu+m1xgv8= Then
Action = Allow
End If
End Sub


This is what the public key looks like in the file.
-----BEGIN RSA PUBLIC KEY-----
MIGJAoGBALT3gV03ajV/gBRcAWJBmpT421Kr9QGosGpPhx622TqM4LJ6uNNyeUAU
r4ZtocaqYH4jONOz8m+63o5KyZT8rleQZiRGycqFkfpKtg7qAbnKosHZO5pIPefd
fL0F+PdFwT8IneHB02jvkyZ3DkB0CSdhaMT3pkGsonik1nnzP3AHAgMBAAE=
-----END RSA PUBLIC KEY-----

Is it even possible?

Re: publickey auth

by wodSupport, Tuesday, March 28, 2006, 02:21 (6598 days ago) @ Jeff

Jeff,

where did you get those public keys from? I know what's the problem - you're checking if public key is in OpenSSH format (that's how wodSSHServer gives it to you), and your file holds SSH.COM (Tectia) format.

Can you convert your public key in OpenSSH format too?

Kreso

Re: publickey auth

by Jeff, Tuesday, March 28, 2006, 02:25 (6598 days ago) @ wodSupport


I think they were created with OpenSSL (.pem)? Are the formats very different - does the data look very different as a string?

Thank you in advance for your help!

Re: publickey auth

by Jeff, Tuesday, March 28, 2006, 03:03 (6597 days ago) @ Jeff


I found that the openssh keys look just like the one returned by wodssh (imagine that). I suppose this is the only format that can be used....?

Re: publickey auth

by wodDrazen, Tuesday, March 28, 2006, 10:34 (6597 days ago) @ Jeff

Hi Jeff,

Maybe you can send us your public key to try to open it over here and duplicate your problem.
You can send us your key on techsupport@weonlydo.com

Hope I helped.

Regards,
Drazen