diff options
author | djm@openbsd.org <djm@openbsd.org> | 2021-09-07 08:03:51 +0200 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2021-09-07 08:05:37 +0200 |
commit | ca0e455b9331213ff9505a21b94c38e34faa2bba (patch) | |
tree | bee3ccdf65be2ae3787ae0e9e5e14723dcaffd42 /ssh-keygen.c | |
parent | upstream: revision 1.381 neglected to remove (diff) | |
download | openssh-ca0e455b9331213ff9505a21b94c38e34faa2bba.tar.xz openssh-ca0e455b9331213ff9505a21b94c38e34faa2bba.zip |
upstream: avoid NULL deref in -Y find-principals. Report and fix
from Carlo Marcelo Arenas Belón
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
OpenBSD-Commit-ID: 6238486f8ecc888d6ccafcd9ad99e621bb41f1e0
Diffstat (limited to 'ssh-keygen.c')
-rw-r--r-- | ssh-keygen.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/ssh-keygen.c b/ssh-keygen.c index 18e9f1d18..cf5d95af7 100644 --- a/ssh-keygen.c +++ b/ssh-keygen.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ssh-keygen.c,v 1.435 2021/08/11 08:54:17 djm Exp $ */ +/* $OpenBSD: ssh-keygen.c,v 1.436 2021/09/07 06:03:51 djm Exp $ */ /* * Author: Tatu Ylonen <ylo@cs.hut.fi> * Copyright (c) 1994 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland @@ -2680,7 +2680,8 @@ sig_process_opts(char * const *opts, size_t nopts, uint64_t *verify_timep, time_t now; *verify_timep = 0; - *print_pubkey = 0; + if (print_pubkey == NULL) + *print_pubkey = 0; for (i = 0; i < nopts; i++) { if (strncasecmp(opts[i], "verify-time=", 12) == 0) { if (parse_absolute_time(opts[i] + 12, |