From 6f8f255ea24012891f1f3cd4323cf6e432ea496a Mon Sep 17 00:00:00 2001 From: djm Date: Thu, 11 Jan 2024 01:51:16 +0000 Subject: [PATCH] ensure key_fd is filled when DSA is disabled; spotted by tb@ --- usr.bin/ssh/ssh-keysign.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/usr.bin/ssh/ssh-keysign.c b/usr.bin/ssh/ssh-keysign.c index 8f36d9f16dd..97a117ed951 100644 --- a/usr.bin/ssh/ssh-keysign.c +++ b/usr.bin/ssh/ssh-keysign.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ssh-keysign.c,v 1.72 2024/01/11 01:45:36 djm Exp $ */ +/* $OpenBSD: ssh-keysign.c,v 1.73 2024/01/11 01:51:16 djm Exp $ */ /* * Copyright (c) 2002 Markus Friedl. All rights reserved. * @@ -190,6 +190,9 @@ main(int argc, char **argv) if (fd > 2) close(fd); + for (i = 0; i < NUM_KEYTYPES; i++) + key_fd[i] = -1; + i = 0; /* XXX This really needs to read sshd_config for the paths */ #ifdef WITH_DSA -- 2.20.1