Fix the regex flags
parent
3c72467b7d
commit
381297ba93
|
@ -43,8 +43,6 @@ class Metasploit3 < Msf::Auxiliary
|
||||||
print_status("#{ip} No certificate subject or CN found")
|
print_status("#{ip} No certificate subject or CN found")
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
|
|
||||||
issuer_pattern = Regexp.new(datastore['ISSUER'])
|
|
||||||
sub = cert.subject.to_a
|
sub = cert.subject.to_a
|
||||||
|
|
||||||
before = Time.parse("#{cert.not_before}")
|
before = Time.parse("#{cert.not_before}")
|
||||||
|
@ -61,7 +59,7 @@ class Metasploit3 < Msf::Auxiliary
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
if ( "#{cert.issuer}" !~ /#{issuer_pattern}/)
|
if cert.issuer.to_s !~ /#{datastore['ISSUER']}/n
|
||||||
print_good("#{ip} - '#{vhostn}' : #{cert.issuer} (BAD ISSUER)" )
|
print_good("#{ip} - '#{vhostn}' : #{cert.issuer} (BAD ISSUER)" )
|
||||||
elsif datastore['SHOWALL']
|
elsif datastore['SHOWALL']
|
||||||
# show verbose as status
|
# show verbose as status
|
||||||
|
|
Loading…
Reference in New Issue