summaryrefslogtreecommitdiff
path: root/auth2.c
diff options
context:
space:
mode:
authordjm@openbsd.org <djm@openbsd.org>2018-09-13 02:08:33 +0000
committerDamien Miller <djm@mindrot.org>2018-09-13 12:12:33 +1000
commit482d23bcacdd3664f21cc82a5135f66fc598275f (patch)
tree362f697a94da0a765d1dabcfbf33370b2a4df121 /auth2.c
parentd70d061828730a56636ab6f1f24fe4a8ccefcfc1 (diff)
downloadopenssh-git-482d23bcacdd3664f21cc82a5135f66fc598275f.tar.gz
upstream: hold our collective noses and use the openssl-1.1.x API in
OpenSSH; feedback and ok tb@ jsing@ markus@ OpenBSD-Commit-ID: cacbcac87ce5da0d3ca7ef1b38a6f7fb349e4417
Diffstat (limited to 'auth2.c')
-rw-r--r--auth2.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/auth2.c b/auth2.c
index ab879589..4d19957a 100644
--- a/auth2.c
+++ b/auth2.c
@@ -706,7 +706,7 @@ auth2_record_key(Authctxt *authctxt, int authenticated,
struct sshkey **tmp, *dup;
int r;
- if ((r = sshkey_demote(key, &dup)) != 0)
+ if ((r = sshkey_from_private(key, &dup)) != 0)
fatal("%s: copy key: %s", __func__, ssh_err(r));
sshkey_free(authctxt->auth_method_key);
authctxt->auth_method_key = dup;
@@ -715,7 +715,7 @@ auth2_record_key(Authctxt *authctxt, int authenticated,
return;
/* If authenticated, make sure we don't accept this key again */
- if ((r = sshkey_demote(key, &dup)) != 0)
+ if ((r = sshkey_from_private(key, &dup)) != 0)
fatal("%s: copy key: %s", __func__, ssh_err(r));
if (authctxt->nprev_keys >= INT_MAX ||
(tmp = recallocarray(authctxt->prev_keys, authctxt->nprev_keys,