1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-24 08:29:04 +00:00

Support RPCBIND 3 and 4, not only portmap 2. See #1469

This commit is contained in:
dmiller
2019-04-15 19:35:24 +00:00
parent ef132f2f24
commit 85ec647932
2 changed files with 109 additions and 47 deletions

View File

@@ -117,14 +117,17 @@ action = function(host, port)
end
end
table.insert( result, ("%-7d %-10s %5d/%s %s"):format(progid, table.concat(v2.version, ","), v2.port, proto, rpc.Util.ProgNumberToName(progid) or "") )
if v2.port then
-- TODO: report other transports that don't have a port; e.g. "local"
table.insert( result, ("%-7d %-10s %5d/%-4s %s"):format(progid, table.concat(v2.version, ","), v2.port, proto, rpc.Util.ProgNumberToName(progid) or "") )
end
end
end
table.sort(result)
if (#result > 0) then
table.insert(result, 1, "program version port/proto service")
table.insert(result, 1, "program version port/proto service")
end
return xmlout, stdnse.format_output( true, result )