summaryrefslogtreecommitdiffstats
path: root/usr.bin/ssh/ssh-sk.c
diff options
context:
space:
mode:
authordjm <djm@openbsd.org>2019-11-16 22:42:30 +0000
committerdjm <djm@openbsd.org>2019-11-16 22:42:30 +0000
commitc649572790f4a3584f57168e9acafcebd7f23ca1 (patch)
treefa4ebe7135a421676726b05ad1f5550d45903f59 /usr.bin/ssh/ssh-sk.c
parentalways use ssh-sk-helper, even for the internal USB HID support. (diff)
downloadwireguard-openbsd-c649572790f4a3584f57168e9acafcebd7f23ca1.tar.xz
wireguard-openbsd-c649572790f4a3584f57168e9acafcebd7f23ca1.zip
a little debug() in the security key interface
Diffstat (limited to 'usr.bin/ssh/ssh-sk.c')
-rw-r--r--usr.bin/ssh/ssh-sk.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/usr.bin/ssh/ssh-sk.c b/usr.bin/ssh/ssh-sk.c
index 51ad9a505db..a1d770ff179 100644
--- a/usr.bin/ssh/ssh-sk.c
+++ b/usr.bin/ssh/ssh-sk.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ssh-sk.c,v 1.12 2019/11/14 21:27:30 djm Exp $ */
+/* $OpenBSD: ssh-sk.c,v 1.13 2019/11/16 22:42:30 djm Exp $ */
/*
* Copyright (c) 2019 Google LLC
*
@@ -256,6 +256,10 @@ sshsk_enroll(int type, const char *provider_path, const char *application,
int r = SSH_ERR_INTERNAL_ERROR;
int alg;
+ debug("%s: provider \"%s\", application \"%s\", flags 0x%02x, "
+ "challenge len %zu", __func__, provider_path, application,
+ flags, challenge_buf == NULL ? 0 : sshbuf_len(challenge_buf));
+
*keyp = NULL;
if (attest)
sshbuf_reset(attest);
@@ -453,6 +457,9 @@ sshsk_sign(const char *provider_path, const struct sshkey *key,
struct sshbuf *inner_sig = NULL, *sig = NULL;
uint8_t message[32];
+ debug("%s: provider \"%s\", key \"%s\", flags 0x%02x", __func__,
+ provider_path, sshkey_type(key), key->sk_flags);
+
if (sigp != NULL)
*sigp = NULL;
if (lenp != NULL)