summaryrefslogtreecommitdiff
path: root/monitor.c
diff options
context:
space:
mode:
authordjm@openbsd.org <djm@openbsd.org>2019-10-31 21:23:19 +0000
committerDamien Miller <djm@mindrot.org>2019-11-01 09:46:10 +1100
commit9a14c64c38fc14d0029f1c7bc70cf62cc7f0fdf9 (patch)
treed79bb8d66eeba8e353f18dac919cb65d0ad896c7 /monitor.c
parent07da39f71d36fb547749a5b16aa8892e621a7e4a (diff)
upstream: Refactor signing - use sshkey_sign for everything,
including the new U2F signatures. Don't use sshsk_ecdsa_sign() directly, instead make it reachable via sshkey_sign() like all other signature operations. This means that we need to add a provider argument to sshkey_sign(), so most of this change is mechanically adding that. Suggested by / ok markus@ OpenBSD-Commit-ID: d5193a03fcfa895085d91b2b83d984a9fde76c8c
Diffstat (limited to 'monitor.c')
-rw-r--r--monitor.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/monitor.c b/monitor.c
index 00af44f98..a884d5f9d 100644
--- a/monitor.c
+++ b/monitor.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: monitor.c,v 1.199 2019/10/07 23:10:38 djm Exp $ */ 1/* $OpenBSD: monitor.c,v 1.200 2019/10/31 21:23:19 djm Exp $ */
2/* 2/*
3 * Copyright 2002 Niels Provos <provos@citi.umich.edu> 3 * Copyright 2002 Niels Provos <provos@citi.umich.edu>
4 * Copyright 2002 Markus Friedl <markus@openbsd.org> 4 * Copyright 2002 Markus Friedl <markus@openbsd.org>
@@ -678,7 +678,7 @@ mm_answer_sign(struct ssh *ssh, int sock, struct sshbuf *m)
678 678
679 if ((key = get_hostkey_by_index(keyid)) != NULL) { 679 if ((key = get_hostkey_by_index(keyid)) != NULL) {
680 if ((r = sshkey_sign(key, &signature, &siglen, p, datlen, alg, 680 if ((r = sshkey_sign(key, &signature, &siglen, p, datlen, alg,
681 compat)) != 0) 681 NULL, compat)) != 0)
682 fatal("%s: sshkey_sign failed: %s", 682 fatal("%s: sshkey_sign failed: %s",
683 __func__, ssh_err(r)); 683 __func__, ssh_err(r));
684 } else if ((key = get_hostkey_public_by_index(keyid, ssh)) != NULL && 684 } else if ((key = get_hostkey_public_by_index(keyid, ssh)) != NULL &&