]> git.ipfire.org Git - thirdparty/openssh-portable.git/commitdiff
upstream: when compiled with GSSAPI support, cache supported method
authordjm@openbsd.org <djm@openbsd.org>
Fri, 21 Sep 2018 12:23:17 +0000 (12:23 +0000)
committerDamien Miller <djm@mindrot.org>
Fri, 21 Sep 2018 12:49:27 +0000 (22:49 +1000)
OIDs by calling ssh_gssapi_prepare_supported_oids() regardless of whether
GSSAPI authentication is enabled in the main config.

This avoids sandbox violations for configurations that enable GSSAPI
auth later, e.g.

Match user djm
GSSAPIAuthentication yes

bz#2107; ok dtucker@

OpenBSD-Commit-ID: a5dd42d87c74e27cfb712b15b0f97ab20e0afd1d

sshd.c

diff --git a/sshd.c b/sshd.c
index 98beb1ed536a4e91b8c79d1d2752eff136ebf8cb..ba26287ba04023a8e4c4278d3397b0c4553fea00 100644 (file)
--- a/sshd.c
+++ b/sshd.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sshd.c,v 1.514 2018/08/13 02:41:05 djm Exp $ */
+/* $OpenBSD: sshd.c,v 1.516 2018/09/21 12:23:17 djm Exp $ */
 /*
  * Author: Tatu Ylonen <ylo@cs.hut.fi>
  * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -536,8 +536,7 @@ privsep_preauth_child(void)
 
 #ifdef GSSAPI
        /* Cache supported mechanism OIDs for later use */
-       if (options.gss_authentication)
-               ssh_gssapi_prepare_supported_oids();
+       ssh_gssapi_prepare_supported_oids();
 #endif
 
        reseed_prngs();