Subject: Re: [libssh2] Publickey auth with SSH Tectia servers

Re: [libssh2] Publickey auth with SSH Tectia servers

From: Sara Golemon <pollita_at_libssh2.org>
Date: Mon, 15 Jan 2007 10:02:52 -0800

Jussi.Mononen_at_comptel.com wrote:
>>> The problem is that if I try to use libssh2_file_read_publickey
>>> -function with a publickey converted to SECSH format it
>>> failes "Invalid key data, not base64 encoded". As a result I can
>>> use only OpenSSH formatted keys and that is unacceptable from the
>>> Tectia server point of view.
> as a solution the libssh2_file_read_publickey -function should be able
> to read both formats of public key files. Now it simply expects the key
> body to start from the second line of the key file failing miserably to
> parse SECSH formatted keys which have begin and end markers as well as
> header and comment fields.
>
> A simple string comparison test against the first line of the key file
> is enough to distinguish SECSH and OpenSSH formatted keys. Then
> libssh2_file_read_publickey -function would only need a way to extract
> the public key body from the SECSH formatted file in order to use it.
> Thus it would be possible to use OpenSSH formatted private key and SECSH
> formatted public key together in authentication.
>
> Does this sound reasonable?
>
> I am currently using version 0.12 and I can not switch to the latest
> version very easily. If I submit a patch for this could someone
> introduce it to the CVS taking care of possible merging at the same
> time?
>
Sounds very reasonable, the original public key parser was a Q&D hack
which (had I understood the OpenSSL API better), shouldn't have even
been necessary. I can't do commits right now either, but hopefully one
of the other folks on the list can push it for you.

-Sara

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
libssh2-devel mailing list
libssh2-devel_at_lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libssh2-devel
Received on 2007-01-15