Skip to content

Commit cc47f8f

Browse files
author
Brent Cook
committed
Land rapid7#5265, handle SSL being disabled in the SSL version scanner
2 parents 59ccf93 + 9b17191 commit cc47f8f

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

modules/auxiliary/scanner/http/ssl_version.rb

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,24 +52,20 @@ def initialize
5252
# Fingerprint a single host
5353
def run_host(ip)
5454
begin
55-
connect
5655
res = send_request_raw({ 'uri' => '/', 'method' => 'GET' })
5756
fp = http_fingerprint(:response => res)
5857
if fp
5958
vprint_status("#{peer} connected and fingerprinted: #{fp}")
6059
# TODO: Interrogate the connection itself to see what version
6160
# was used. Where that actually lives is eluding me. :/
62-
if datastore['SSLVersion'] == 'SSL3'
61+
if datastore['SSL'] && datastore['SSLVersion'] == 'SSL3'
6362
print_good("#{peer} accepts SSLv3")
6463
report_poodle_vuln(ip)
6564
end
6665
end
6766
rescue ::OpenSSL::SSL::SSLError => e
6867
ssl_version = e.message.match(/ state=([^\s]+)/)[1]
6968
vprint_status("#{peer} does not accept #{ssl_version}")
70-
rescue ::Timeout::Error, ::Errno::EPIPE
71-
ensure
72-
disconnect
7369
end
7470
end
7571

0 commit comments

Comments
 (0)