From e8155e8443c9451b52729c6f31332464fc09d03e Mon Sep 17 00:00:00 2001 From: djm Date: Wed, 24 May 2023 23:01:06 +0000 Subject: [PATCH] fix AuthorizedPrincipalsCommand when AuthorizedKeysCommand appears previously in configuration. Reported by John Meyers in bz3574 ok dtucker@ --- usr.bin/ssh/servconf.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.bin/ssh/servconf.c b/usr.bin/ssh/servconf.c index 3794c31da6b..6d056f7d0ae 100644 --- a/usr.bin/ssh/servconf.c +++ b/usr.bin/ssh/servconf.c @@ -1,5 +1,5 @@ -/* $OpenBSD: servconf.c,v 1.392 2023/03/05 05:34:09 dtucker Exp $ */ +/* $OpenBSD: servconf.c,v 1.393 2023/05/24 23:01:06 djm Exp $ */ /* * Copyright (c) 1995 Tatu Ylonen , Espoo, Finland * All rights reserved @@ -2346,7 +2346,7 @@ process_server_config_line_depth(ServerOptions *options, char *line, fatal("%.200s line %d: %s must be an absolute path", filename, linenum, keyword); } - if (*activep && options->authorized_keys_command == NULL) + if (*activep && *charptr == NULL) *charptr = xstrdup(str + len); argv_consume(&ac); break; -- 2.20.1