aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libssh/auth.c3
-rw-r--r--libssh/keyfiles.c8
2 files changed, 6 insertions, 5 deletions
diff --git a/libssh/auth.c b/libssh/auth.c
index 2e801947..53baa85c 100644
--- a/libssh/auth.c
+++ b/libssh/auth.c
@@ -378,7 +378,7 @@ error:
* two different logins in a row.
*
* @param[in] type The type of the public key. This value is given by
- * publickey_from_file().
+ * publickey_from_file() or ssh_privatekey_type().
*
* @param[in] publickey A public key returned by publickey_from_file().
*
@@ -393,6 +393,7 @@ error:
*
* @see publickey_from_file()
* @see privatekey_from_file()
+ * @see ssh_privatekey_type()
* @see ssh_userauth_pubkey()
*/
int ssh_userauth_offer_pubkey(ssh_session session, const char *username,
diff --git a/libssh/keyfiles.c b/libssh/keyfiles.c
index 0fa67b33..8c50776c 100644
--- a/libssh/keyfiles.c
+++ b/libssh/keyfiles.c
@@ -364,11 +364,11 @@ static ssh_buffer privatekey_file_to_buffer(FILE *fp, int type,
}
switch(type) {
- case TYPE_DSS:
+ case SSH_KEYTYPE_DSS:
header_begin = DSA_HEADER_BEGIN;
header_end = DSA_HEADER_END;
break;
- case TYPE_RSA:
+ case SSH_KEYTYPE_RSA:
header_begin = RSA_HEADER_BEGIN;
header_end = RSA_HEADER_END;
break;
@@ -468,7 +468,7 @@ static int read_rsa_privatekey(FILE *fp, gcry_sexp_t *r,
ssh_buffer buffer = NULL;
int rc = 1;
- buffer = privatekey_file_to_buffer(fp, TYPE_RSA, cb, userdata, desc);
+ buffer = privatekey_file_to_buffer(fp, SSH_KEYTYPE_RSA, cb, userdata, desc);
if (buffer == NULL) {
return 0;
}
@@ -537,7 +537,7 @@ static int read_dsa_privatekey(FILE *fp, gcry_sexp_t *r, ssh_auth_callback cb,
ssh_string v = NULL;
int rc = 1;
- buffer = privatekey_file_to_buffer(fp, TYPE_DSS, cb, userdata, desc);
+ buffer = privatekey_file_to_buffer(fp, SSH_KEYTYPE_DSS, cb, userdata, desc);
if (buffer == NULL) {
return 0;
}