From de460c242e01b791b00ed758ef7e6cd817629f21 Mon Sep 17 00:00:00 2001 From: david Date: Mon, 5 Aug 2013 23:52:57 +0000 Subject: [PATCH] Fix the test for an unmatched service in skypev2-version.nse. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Marin Maržić noticed that port.service is set even for unmatched services. We want this script to run especially for ports 80 and 443. http://seclists.org/nmap-dev/2012/q4/490 --- scripts/skypev2-version.nse | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/skypev2-version.nse b/scripts/skypev2-version.nse index fe0cee236..146a4407b 100644 --- a/scripts/skypev2-version.nse +++ b/scripts/skypev2-version.nse @@ -22,7 +22,7 @@ portrule = function(host, port) port.service == nil or port.service == "" or port.service == "unknown") and port.protocol == "tcp" and port.state == "open" - and port.service ~= "http" and port.service ~= "ssl/http" + and port.version.name_confidence < 10 and not(shortport.port_is_excluded(port.number,port.protocol)) end