r6020: Never do NT status codes with protocols before NT1 as we don't get client...
authorJeremy Allison <jra@samba.org>
Thu, 24 Mar 2005 01:02:52 +0000 (01:02 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 15:56:16 +0000 (10:56 -0500)
Jeremy.
(This used to be commit 4868e4202775c1c0a60828e0c6f6fa23cf8346e1)

source3/smbd/sesssetup.c

index e1fb71d575489d2b8ffbdd023002739fd7995330..48524b472d2d1923339c29a8f1d59538e75e0981 100644 (file)
@@ -677,6 +677,10 @@ int reply_sesssetup_and_X(connection_struct *conn, char *inbuf,char *outbuf,
 
        if (Protocol < PROTOCOL_NT1) {
                uint16 passlen1 = SVAL(inbuf,smb_vwv7);
+
+               /* Never do NT status codes with protocols before NT1 as we don't get client caps. */
+               remove_from_common_flags2(FLAGS2_32_BIT_ERROR_CODES);
+
                if ((passlen1 > MAX_PASS_LEN) || (passlen1 > smb_bufrem(inbuf, smb_buf(inbuf)))) {
                        return ERROR_NT(NT_STATUS_INVALID_PARAMETER);
                }