summaryrefslogtreecommitdiffstats
path: root/web/attachments/95011-check_nmap.patch
blob: 3e41addf1878c3cbb36001664900143da81c2f44 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
--- ./contrib/check_nmap.py	2002-02-28 01:42:54.000000000 -0500
+++ ./contrib/check_nmap.py	2004-07-23 16:03:17.000000000 -0400
@@ -8,7 +8,7 @@
 # License: GPL
 # Copyright (c)  2000 Jacob Lundqvist (jaclu@galdrion.com)
 #
-_version_ = '1.20'
+_version_ = '1.21'
 #
 #
 # Description:
@@ -25,6 +25,7 @@
 #
 # History
 # -------
+# 1.21	 2004-07-23 rippeld@hillsboroughcounty.org Updated parsing of nmap output to correctly identify closed ports
 # 1.20   2000-07-15 jaclu Updated params to correctly comply to plugin-standard
 #                         moved support classes to utils.py
 # 1.16   2000-07-14 jaclu made options and return codes more compatible with 
@@ -276,7 +277,8 @@
 		if string.find(s,'/')<1:
 		    continue
 		p=string.split(s,'/')[0]
-		self.active_ports.append(int(p))
+		if string.find(l,'open')>1:
+		    self.active_ports.append(int(p))
 	except:
 	    # failure due to strange output...
 	    pass