1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-31 20:09:02 +00:00

Fix endianness bug making RFB 3.3 not detect auth type

This commit is contained in:
dmiller
2016-04-02 15:54:32 +00:00
parent 6c7655c24f
commit 56d71fe6df

View File

@@ -222,7 +222,7 @@ VNC = {
return false, "VNC:handshake failed to receive security data"
end
vncsec.types[1] = select(2, bin.unpack("I", tmp) )
vncsec.types[1] = select(2, bin.unpack(">I", tmp) )
self.vncsec = vncsec
-- do we have an invalid security type, if so we need to handle an
@@ -355,7 +355,7 @@ VNC = {
return false, "Failed to retrieve authentication status from server"
end
if ( select(2, bin.unpack("I", result) ) ~= 0 ) then
if ( select(2, bin.unpack(">I", result) ) ~= 0 ) then
return false, "Authentication failed"
end
return true