diff options
Diffstat (limited to 'include/libssh')
-rw-r--r-- | include/libssh/libssh.h | 5 | ||||
-rw-r--r-- | include/libssh/pki.h | 8 |
2 files changed, 13 insertions, 0 deletions
diff --git a/include/libssh/libssh.h b/include/libssh/libssh.h index 7357129..ac73bc0 100644 --- a/include/libssh/libssh.h +++ b/include/libssh/libssh.h @@ -433,6 +433,11 @@ LIBSSH_API int ssh_key_import_private(ssh_session session, const char *filename, const char *passphrase, ssh_key *pkey); +LIBSSH_API int ssh_pki_import_pubkey_base64(ssh_session session, + const char *b64_key, + enum ssh_keytypes_e type, + ssh_key *pkey); + LIBSSH_API int ssh_userauth_pki_pubkey(ssh_session session, const char *username, ssh_string publickey, ssh_key privatekey); LIBSSH_API void ssh_print_hexa(const char *descr, const unsigned char *what, size_t len); diff --git a/include/libssh/pki.h b/include/libssh/pki.h index 615b7c0..49f8a5e 100644 --- a/include/libssh/pki.h +++ b/include/libssh/pki.h @@ -62,6 +62,14 @@ ssh_key pki_private_key_from_base64(ssh_session session, const char *b64_key, const char *passphrase); ssh_key pki_publickey_from_privatekey(ssh_key privkey); +int pki_pubkey_build_dss(ssh_key key, + ssh_string p, + ssh_string q, + ssh_string g, + ssh_string pubkey); +int pki_pubkey_build_rsa(ssh_key key, + ssh_string e, + ssh_string n); struct signature_struct *pki_do_sign(ssh_key privatekey, const unsigned char *hash); |