summaryrefslogtreecommitdiffstats
path: root/usr.bin/ssh/sshkey.c
diff options
context:
space:
mode:
authormarkus <markus@openbsd.org>2019-11-13 07:53:10 +0000
committermarkus <markus@openbsd.org>2019-11-13 07:53:10 +0000
commitd3c68393d78899c96f18a7d321d9ac2085c47a51 (patch)
treee50ddc2992903346b2a084c5b7230f52cc83ffc1 /usr.bin/ssh/sshkey.c
parentdrm/i915/cmdparser: Fix jump whitelist clearing (diff)
downloadwireguard-openbsd-d3c68393d78899c96f18a7d321d9ac2085c47a51.tar.xz
wireguard-openbsd-d3c68393d78899c96f18a7d321d9ac2085c47a51.zip
fix shield/unshield for xmss keys:
- in ssh-agent we need to delay the call to shield until we have received key specific options. - when serializing xmss keys for shield we need to deal with all optional components (e.g. state might not be loaded). ok djm@
Diffstat (limited to 'usr.bin/ssh/sshkey.c')
-rw-r--r--usr.bin/ssh/sshkey.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/ssh/sshkey.c b/usr.bin/ssh/sshkey.c
index c61b74a71fa..5ecf1ee21d2 100644
--- a/usr.bin/ssh/sshkey.c
+++ b/usr.bin/ssh/sshkey.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sshkey.c,v 1.90 2019/11/12 19:33:08 markus Exp $ */
+/* $OpenBSD: sshkey.c,v 1.91 2019/11/13 07:53:10 markus Exp $ */
/*
* Copyright (c) 2000, 2001 Markus Friedl. All rights reserved.
* Copyright (c) 2008 Alexander von Gernler. All rights reserved.
@@ -2004,7 +2004,7 @@ sshkey_shield_private(struct sshkey *k)
if (sshkey_is_shielded(k) && (r = sshkey_unshield_private(k)) != 0)
goto out;
if ((r = sshkey_private_serialize_opt(k, prvbuf,
- SSHKEY_SERIALIZE_FULL)) != 0)
+ SSHKEY_SERIALIZE_SHIELD)) != 0)
goto out;
/* pad to cipher blocksize */
i = 0;