X-Git-Url: http://git.samba.org/samba.git/?p=nivanova%2Fsamba-autobuild%2F.git;a=blobdiff_plain;f=source3%2Fsmbd%2Fnegprot.c;fp=source3%2Fsmbd%2Fnegprot.c;h=2d5edf1282c0ce1edab8339eae4397e400d19fc3;hp=27366ea0013aa8ca6080d79972b31ca9ede7e824;hb=378706266496ce79c1887fe96ab3b15f56770244;hpb=0122f45f053ecc545950c31bf1fb33fba143478c diff --git a/source3/smbd/negprot.c b/source3/smbd/negprot.c index 27366ea0013..2d5edf1282c 100644 --- a/source3/smbd/negprot.c +++ b/source3/smbd/negprot.c @@ -28,6 +28,13 @@ #include "auth/gensec/gensec.h" #include "../libcli/smb/smb_signing.h" +/* + * MS-CIFS, 2.2.4.52.2 SMB_COM_NEGOTIATE Response: + * If the server does not support any of the listed dialects, it MUST return a + * DialectIndex of 0XFFFF + */ +#define NO_PROTOCOL_CHOSEN 0xffff + extern fstring remote_proto; static void get_challenge(struct smbXsrv_connection *xconn, uint8_t buff[8]) @@ -748,7 +755,7 @@ void reply_negprot(struct smb_request *req) DBG_NOTICE("No protocol supported !\n"); reply_outbuf(req, 1, 0); - SSVAL(req->outbuf, smb_vwv0, choice); + SSVAL(req->outbuf, smb_vwv0, NO_PROTOCOL_CHOSEN); ok = srv_send_smb(xconn, (char *)req->outbuf, false, 0, false, NULL);