File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed
modules/auxiliary/scanner/http Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -53,13 +53,14 @@ def run_host(ip)
53
53
print_status ( "#{ ip } :#{ rport } Subject: #{ cert . subject } " )
54
54
print_status ( "#{ ip } :#{ rport } Issuer: #{ cert . issuer } " )
55
55
print_status ( "#{ ip } :#{ rport } Signature Alg: #{ cert . signature_algorithm } " )
56
- public_key = cert . public_key . to_pem ( )
56
+ public_key = cert . public_key . to_pem ( )
57
57
# removing header and footer
58
58
public_key = public_key . sub ( "-----BEGIN RSA PUBLIC KEY-----" , "" )
59
59
public_key = public_key . sub ( "-----END RSA PUBLIC KEY-----" , "" )
60
- public_key_size = Rex ::Text . decode_base64 ( public_key ) . size
61
- # removing 12 bytes for some shmoo of exponent and modulus
62
- print_status ( "#{ ip } :#{ rport } Public Key Size: #{ ( public_key_size - 12 ) * 8 } bits" )
60
+ public_key_size = Rex ::Text . decode_base64 ( public_key ) . size
61
+ # removing 12 bytes for some shmoo of exponent and modulus and turn bytes into bits
62
+ public_key_size = ( public_key_size - 12 ) * 8
63
+ print_status ( "#{ ip } :#{ rport } Public Key Size: #{ public_key_size } bits" )
63
64
print_status ( "#{ ip } :#{ rport } Not Valid Before: #{ cert . not_before } " )
64
65
print_status ( "#{ ip } :#{ rport } Not Valid After: #{ cert . not_after } " )
65
66
You can’t perform that action at this time.
0 commit comments