From: Jeremy Allison Date: Wed, 1 Oct 2014 21:20:10 +0000 (-0700) Subject: s3: smb2cli: query info return length check was reversed. X-Git-Tag: samba-4.0.23~48 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6642684cc01545e59613ee0845c1ee2dfffee478;p=thirdparty%2Fsamba.git s3: smb2cli: query info return length check was reversed. Make it identical to the check in libcli/smb/smb2cli_ioctl.c https://bugzilla.samba.org/show_bug.cgi?id=10848 Signed-off-by: Jeremy Allison Reviewed-by: "Stefan (metze) Metzmacher" Reviewed-by: David Disseldorp Autobuild-User(master): Jeremy Allison Autobuild-Date(master): Thu Oct 2 04:42:26 CEST 2014 on sn-devel-104 (cherry picked from commit 6c05cd3e895831be7d9a68a51de2048d04c188a0) Autobuild-User(v4-0-test): Karolin Seeger Autobuild-Date(v4-0-test): Thu Oct 9 23:25:47 CEST 2014 on sn-devel-104 --- diff --git a/libcli/smb/smb2cli_query_info.c b/libcli/smb/smb2cli_query_info.c index 80cec9c3cc9..0be37365a3b 100644 --- a/libcli/smb/smb2cli_query_info.c +++ b/libcli/smb/smb2cli_query_info.c @@ -152,7 +152,7 @@ static void smb2cli_query_info_done(struct tevent_req *subreq) return; } - if (output_buffer_length < dyn_len) { + if (output_buffer_length > dyn_len) { tevent_req_nterror( req, NT_STATUS_INVALID_NETWORK_RESPONSE); return;