1
0
mirror of https://github.com/nmap/nmap.git synced 2026-01-01 20:39:02 +00:00

Fixed bug so that empty passwords are printed as <empty> in script results.

Bug reported by Toni Ruottu http://seclists.org/nmap-dev/2011/q1/789
This commit is contained in:
patrik
2011-03-12 23:50:57 +00:00
parent dc9d0bc0e7
commit 72b7fcc299

View File

@@ -262,7 +262,7 @@ Account =
if ( #self.username > 0 ) then
creds = ("%s:%s"):format( self.username, #self.password > 0 and self.password or "<empty>" )
else
creds = ("%s"):format( self.password )
creds = ("%s"):format( ( self.password and #self.password > 0 ) and self.password or "<empty>" )
end
-- An account have the following states