From: Stefan Metzmacher Date: Thu, 3 May 2012 14:13:08 +0000 (+0200) Subject: s3:smbd: allow creating new spnego sessions only with a 0 vuid X-Git-Tag: samba-4.0.0alpha21~68 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=d58f7cd5469baba5b47bbd6923103aa4c6b42c91;p=thirdparty%2Fsamba.git s3:smbd: allow creating new spnego sessions only with a 0 vuid Found by the raw.context test. metze --- diff --git a/source3/smbd/sesssetup.c b/source3/smbd/sesssetup.c index 7d1535af5ac..f9ba9769b59 100644 --- a/source3/smbd/sesssetup.c +++ b/source3/smbd/sesssetup.c @@ -202,6 +202,11 @@ static void reply_sesssetup_and_X_spnego(struct smb_request *req) /* Do we have a valid vuid now ? */ if (!is_partial_auth_vuid(sconn, vuid)) { + if (vuid != 0) { + reply_force_doserror(req, ERRSRV, ERRbaduid); + return; + } + /* No, start a new authentication setup. */ vuid = register_initial_vuid(sconn); if (vuid == UID_FIELD_INVALID) {