[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Question on privatekey_from_file


Hi,

Recently I am trying to use privatekey_from_file without a public key. I
think I can do it by:

privatekey_from_file -> publickey_from_privatekey -> publickey_to_string

But in order to call privatekey_from_file, I have to tell it the key
type (RSA or DSS). Previously I could get the key type from
publickey_from_file, but now I can't since I don't have the public key
file.

I know it's quite easy to tell the keytype from the private key file by
simply read the first line... but any reason why this cannot be done
automatically inside libssh?

Thanks,

Vic




Follow-Ups:
Re: Question on privatekey_from_fileVic Lee <llyzs@xxxxxxx>
Re: Question on privatekey_from_fileAndreas Schneider <mail@xxxxxxxxxxxx>
Archive administrator: postmaster@lists.cynapses.org