lib/scanner/ssl.rb in yawast-0.4.0.beta4 vs lib/scanner/ssl.rb in yawast-0.4.0.beta5

- old
+ new

@@ -105,11 +105,11 @@ end def self.get_ciphers(uri) puts 'Supported Ciphers (based on your OpenSSL version):' - dns = Resolv::DNS.new() + dns = Resolv::DNS.new if IPAddress.valid? uri.host ip = IPAddress.parse uri.host else ip = dns.getaddresses(uri.host)[0] @@ -118,11 +118,11 @@ #find all versions that don't include '_server' or '_client' versions = OpenSSL::SSL::SSLContext::METHODS.find_all { |v| !v.to_s.include?('_client') && !v.to_s.include?('_server')} versions.each do |version| #ignore SSLv23, as it's an auto-negotiate, which just adds noise - if version.to_s != "SSLv23" + if version.to_s != 'SSLv23' ciphers = OpenSSL::SSL::SSLContext.new(version).ciphers puts "\tChecking for #{version.to_s} suites (#{ciphers.count} possible suites)" ciphers.each do |cipher| #try to connect and see what happens @@ -195,10 +195,10 @@ req.use_ssl = uri.scheme == 'https' req.keep_alive_timeout = 600 headers = Yawast::Shared::Http.get_headers #force 3DES - this is to ensure that 3DES specific limits are caught - req.ciphers = ["3DES"] + req.ciphers = ['3DES'] req.start do |http| 10000.times do |i| http.head(uri.path, headers)