summaryrefslogtreecommitdiff
path: root/sshd.c
diff options
context:
space:
mode:
authordjm@openbsd.org <djm@openbsd.org>2020-08-27 01:06:18 +0000
committerDamien Miller <djm@mindrot.org>2020-08-27 11:28:36 +1000
commit9b8ad93824c682ce841f53f3b5762cef4e7cc4dc (patch)
treed4523956d4623b19bf5904d1b92afeb2307f69d3 /sshd.c
parent1196d7f49d4fbc90f37e550de3056561613b0960 (diff)
upstream: support for user-verified FIDO keys
FIDO2 supports a notion of "user verification" where the user is required to demonstrate their identity to the token before particular operations (e.g. signing). Typically this is done by authenticating themselves using a PIN that has been set on the token. This adds support for generating and using user verified keys where the verification happens via PIN (other options might be added in the future, but none are in common use now). Practically, this adds another key generation option "verify-required" that yields a key that requires a PIN before each authentication. feedback markus@ and Pedro Martelletto; ok markus@ OpenBSD-Commit-ID: 57fd461e4366f87c47502c5614ec08573e6d6a15
Diffstat (limited to 'sshd.c')
-rw-r--r--sshd.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sshd.c b/sshd.c
index d9a159f6a..8aa7f3df6 100644
--- a/sshd.c
+++ b/sshd.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: sshd.c,v 1.560 2020/07/03 10:12:26 markus Exp $ */ 1/* $OpenBSD: sshd.c,v 1.561 2020/08/27 01:06:19 djm Exp $ */
2/* 2/*
3 * Author: Tatu Ylonen <ylo@cs.hut.fi> 3 * Author: Tatu Ylonen <ylo@cs.hut.fi>
4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland 4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -2338,19 +2338,19 @@ sshd_hostkey_sign(struct ssh *ssh, struct sshkey *privkey,
2338 if (use_privsep) { 2338 if (use_privsep) {
2339 if (privkey) { 2339 if (privkey) {
2340 if (mm_sshkey_sign(ssh, privkey, signature, slenp, 2340 if (mm_sshkey_sign(ssh, privkey, signature, slenp,
2341 data, dlen, alg, options.sk_provider, 2341 data, dlen, alg, options.sk_provider, NULL,
2342 ssh->compat) < 0) 2342 ssh->compat) < 0)
2343 fatal("%s: privkey sign failed", __func__); 2343 fatal("%s: privkey sign failed", __func__);
2344 } else { 2344 } else {
2345 if (mm_sshkey_sign(ssh, pubkey, signature, slenp, 2345 if (mm_sshkey_sign(ssh, pubkey, signature, slenp,
2346 data, dlen, alg, options.sk_provider, 2346 data, dlen, alg, options.sk_provider, NULL,
2347 ssh->compat) < 0) 2347 ssh->compat) < 0)
2348 fatal("%s: pubkey sign failed", __func__); 2348 fatal("%s: pubkey sign failed", __func__);
2349 } 2349 }
2350 } else { 2350 } else {
2351 if (privkey) { 2351 if (privkey) {
2352 if (sshkey_sign(privkey, signature, slenp, data, dlen, 2352 if (sshkey_sign(privkey, signature, slenp, data, dlen,
2353 alg, options.sk_provider, ssh->compat) < 0) 2353 alg, options.sk_provider, NULL, ssh->compat) < 0)
2354 fatal("%s: privkey sign failed", __func__); 2354 fatal("%s: privkey sign failed", __func__);
2355 } else { 2355 } else {
2356 if ((r = ssh_agent_sign(auth_sock, pubkey, 2356 if ((r = ssh_agent_sign(auth_sock, pubkey,