diff --git a/nselib/smb.lua b/nselib/smb.lua index 1f40e3439..0e96ff261 100644 --- a/nselib/smb.lua +++ b/nselib/smb.lua @@ -543,7 +543,7 @@ function start_netbios(host, port, name) 0x44, -- length netbios.name_encode(name), -- server name netbios.name_encode("NMAP") -- client name - ); + ); stdnse.print_debug(3, "SMB: Connecting to %s", host.ip) socket:set_timeout(TIMEOUT) @@ -1867,8 +1867,8 @@ function read_file(smb, offset, count, overrides) return false, "SMB: ERROR: Server returned less data than it was supposed to (one or more fields are missing); aborting [25]" end if(status ~= 0 and - (status ~= status_codes.NT_STATUS_BUFFER_OVERFLOW and (smb['filetype'] == filetype_codes.FILE_TYPE_BYTE_MODE_PIPE or - smb['filetype'] == filetype_codes.FILE_TYPE_MESSAGE_MODE_PIPE) ) ) then + (status ~= status_codes.NT_STATUS_BUFFER_OVERFLOW and (smb['filetype'] == filetype_codes.FILE_TYPE_BYTE_MODE_PIPE or + smb['filetype'] == filetype_codes.FILE_TYPE_MESSAGE_MODE_PIPE) ) ) then return false, get_status_name(status) end @@ -1995,9 +1995,9 @@ function close_file(smb, overrides) header = smb_encode_header(smb, command_codes['SMB_COM_CLOSE'], overrides) parameters = bin.pack("