mirror of
https://github.com/nmap/nmap.git
synced 2025-12-07 13:11:28 +00:00
Don't clobber version info in rmi-dumpregistry. See #1342
This commit is contained in:
@@ -1,4 +1,3 @@
|
|||||||
local nmap = require "nmap"
|
|
||||||
local rmi = require "rmi"
|
local rmi = require "rmi"
|
||||||
local shortport = require "shortport"
|
local shortport = require "shortport"
|
||||||
local stdnse = require "stdnse"
|
local stdnse = require "stdnse"
|
||||||
@@ -28,7 +27,7 @@ so-called "Custom data".
|
|||||||
-- @usage nmap --script rmi-dumpregistry -p 1098 <host>
|
-- @usage nmap --script rmi-dumpregistry -p 1098 <host>
|
||||||
-- @output
|
-- @output
|
||||||
-- PORT STATE SERVICE REASON
|
-- PORT STATE SERVICE REASON
|
||||||
-- 1099/tcp open java-rmi syn-ack
|
-- 1099/tcp open rmiregistry syn-ack
|
||||||
-- | rmi-dumpregistry:
|
-- | rmi-dumpregistry:
|
||||||
-- | jmxrmi
|
-- | jmxrmi
|
||||||
-- | javax.management.remote.rmi.RMIServerImpl_Stub
|
-- | javax.management.remote.rmi.RMIServerImpl_Stub
|
||||||
@@ -40,7 +39,7 @@ so-called "Custom data".
|
|||||||
--
|
--
|
||||||
-- @output
|
-- @output
|
||||||
-- PORT STATE SERVICE REASON
|
-- PORT STATE SERVICE REASON
|
||||||
-- 1099/tcp open java-rmi syn-ack
|
-- 1099/tcp open rmiregistry syn-ack
|
||||||
-- | rmi-dumpregistry:
|
-- | rmi-dumpregistry:
|
||||||
-- | cfassembler/default
|
-- | cfassembler/default
|
||||||
-- | coldfusion.flex.rmi.DataServicesCFProxyServer_Stub
|
-- | coldfusion.flex.rmi.DataServicesCFProxyServer_Stub
|
||||||
@@ -210,10 +209,6 @@ function action(host,port, args)
|
|||||||
table.insert(output, ("Registry listing failed (%s)"):format(tostring(j_array)))
|
table.insert(output, ("Registry listing failed (%s)"):format(tostring(j_array)))
|
||||||
return stdnse.format_output(false, output)
|
return stdnse.format_output(false, output)
|
||||||
end
|
end
|
||||||
-- It's definitely RMI!
|
|
||||||
port.version.name = 'java-rmi'
|
|
||||||
port.version.product = 'Java RMI Registry'
|
|
||||||
nmap.set_port_version(host,port)
|
|
||||||
|
|
||||||
-- Monkey patch the java-class in rmi, to set our own custom data formatter
|
-- Monkey patch the java-class in rmi, to set our own custom data formatter
|
||||||
-- for classpaths
|
-- for classpaths
|
||||||
|
|||||||
Reference in New Issue
Block a user