diff options
Diffstat (limited to 'include/libssh')
| -rw-r--r-- | include/libssh/messages.h | 2 | ||||
| -rw-r--r-- | include/libssh/server.h | 13 |
2 files changed, 14 insertions, 1 deletions
diff --git a/include/libssh/messages.h b/include/libssh/messages.h index 667f7cca..17e25320 100644 --- a/include/libssh/messages.h +++ b/include/libssh/messages.h @@ -28,7 +28,7 @@ struct ssh_auth_request { char *username; int method; char *password; - struct ssh_public_key_struct *public_key; + struct ssh_key_struct *pubkey; char signature_state; char kbdint_response; }; diff --git a/include/libssh/server.h b/include/libssh/server.h index cb12c133..48f0eabd 100644 --- a/include/libssh/server.h +++ b/include/libssh/server.h @@ -281,6 +281,19 @@ LIBSSH_API const char *ssh_message_auth_user(ssh_message msg); * @see ssh_message_type() */ LIBSSH_API const char *ssh_message_auth_password(ssh_message msg); + +/** + * @brief Get the publickey of the authenticated user. + * + * @param[in] msg The message to get the public key from. + * + * @return The public key or NULL. + * + * @see ssh_message_get() + * @see ssh_message_type() + */ +LIBSSH_API ssh_key ssh_message_auth_pubkey(ssh_message msg); + LIBSSH_API ssh_public_key ssh_message_auth_publickey(ssh_message msg); LIBSSH_API int ssh_message_auth_kbdint_is_response(ssh_message msg); LIBSSH_API enum ssh_publickey_state_e ssh_message_auth_publickey_state(ssh_message msg); |
