@@ -52,17 +52,15 @@ def bigip_http?(ip, port, ssl, verbose = false)
52
52
return true if server =~ /BIG\- IP/ || server =~ /BigIP/
53
53
end
54
54
rescue ::Rex ::ConnectionRefused
55
- print_status ( "#{ ip } :#{ port } - TCP port closed" ) if verbose
55
+ vprint_error ( "#{ ip } :#{ port } - Connection refused" )
56
56
rescue ::Rex ::ConnectionError
57
- print_error ( "#{ ip } :#{ port } - Connection error" )
57
+ vprint_error ( "#{ ip } :#{ port } - Connection error" )
58
58
rescue ::OpenSSL ::SSL ::SSLError
59
- print_error ( "#{ ip } :#{ port } - SSL/TLS connection error" )
60
- rescue => e
61
- print_error ( "#{ ip } :#{ port } - Connection failed" ) if verbose
59
+ vprint_error ( "#{ ip } :#{ port } - SSL/TLS connection error" )
62
60
end
63
61
end
64
62
rescue Timeout ::Error
65
- print_error ( "#{ ip } :#{ port } - HTTP connection timed out" ) if verbose
63
+ vprint_error ( "#{ ip } :#{ port } - HTTP connection timed out" ) if verbose
66
64
end
67
65
return false
68
66
end
@@ -74,15 +72,15 @@ def run_host(ip)
74
72
ports . each do |port |
75
73
next if port == 443
76
74
if bigip_http? ( ip , port , ssl = false , verbose )
77
- print_status ( "#{ ip } :#{ port } - BigIP HTTP virtual server found" )
75
+ print_good ( "#{ ip } :#{ port } - BigIP HTTP virtual server found" )
78
76
ports . delete ( port )
79
77
end
80
78
end
81
79
82
80
ports . each do |port |
83
81
next if port == 80
84
82
if bigip_http? ( ip , port , ssl = true , verbose )
85
- print_status ( "#{ ip } :#{ port } - BigIP HTTP virtual server found" )
83
+ print_good ( "#{ ip } :#{ port } - BigIP HTTP virtual server found" )
86
84
end
87
85
end
88
86
0 commit comments