@@ -180,9 +180,12 @@ class Cert < ApiObject
180
180
:crlURIs ,
181
181
:ocspURIs ,
182
182
:revocationStatus ,
183
+ :crlRevocationStatus ,
184
+ :ocspRevocationStatus ,
183
185
:sgc? ,
184
186
:validationType ,
185
- :issues
187
+ :issues ,
188
+ :sct?
186
189
187
190
def valid?
188
191
issues == 0
@@ -196,9 +199,18 @@ def invalid?
196
199
class ChainCert < ApiObject
197
200
has_fields :subject ,
198
201
:label ,
202
+ :notBefore ,
203
+ :notAfter ,
199
204
:issuerSubject ,
200
205
:issuerLabel ,
206
+ :sigAlg ,
201
207
:issues ,
208
+ :keyAlg ,
209
+ :keySize ,
210
+ :keyStrength ,
211
+ :revocationStatus ,
212
+ :crlRevocationStatus ,
213
+ :ocspRevocationStatus ,
202
214
:raw
203
215
204
216
def valid?
@@ -212,12 +224,7 @@ def invalid?
212
224
213
225
class Chain < ApiObject
214
226
has_objects_list :certs , ChainCert
215
- has_fields :subject ,
216
- :label ,
217
- :issuerSubject ,
218
- :issuerLabel ,
219
- :issues ,
220
- :raw
227
+ has_fields :issues
221
228
222
229
def valid?
223
230
issues == 0
@@ -354,6 +361,8 @@ class EndpointDetails < ApiObject
354
361
:npnProtocols ,
355
362
:sessionTickets ,
356
363
:ocspStapling? ,
364
+ :staplingRevocationStatus ,
365
+ :staplingRevocationErrorMessage ,
357
366
:sniRequired? ,
358
367
:httpStatusCode ,
359
368
:httpForwarding ,
@@ -364,8 +373,11 @@ class EndpointDetails < ApiObject
364
373
has_fields :heartbleed? ,
365
374
:heartbeat? ,
366
375
:openSslCcs ,
376
+ :poodle? ,
367
377
:poodleTls ,
368
- :fallbackScsv?
378
+ :fallbackScsv? ,
379
+ :freak? ,
380
+ :hasSct
369
381
end
370
382
371
383
class Endpoint < ApiObject
@@ -375,6 +387,7 @@ class Endpoint < ApiObject
375
387
:statusDetails ,
376
388
:statusDetailsMessage ,
377
389
:grade ,
390
+ :gradeTrustIgnored ,
378
391
:hasWarnings? ,
379
392
:isExceptional? ,
380
393
:progress ,
@@ -408,7 +421,7 @@ def initialize(info = {})
408
421
SSL/TLS assessment during a penetration test.
409
422
} ,
410
423
'License' => MSF_LICENSE ,
411
- 'Author' =>
424
+ 'Author' =>
412
425
[
413
426
'Denis Kolegov <dnkolegov[at]gmail.com>' ,
414
427
'Francois Chagnon' # ssllab.rb author (https://github.com/Shopify/ssllabs.rb)
@@ -472,6 +485,8 @@ def output_endpoint_data(r)
472
485
report_bad "Overall rating: #{ r . grade } - Server's certificate is not trusted"
473
486
end
474
487
488
+ report_warning "Grade is #{ r . grade_trust_ignored } , if trust issues are ignored)" if r . grade . to_s != r . grade_trust_ignored . to_s
489
+
475
490
# Supported protocols
476
491
r . details . protocols . each do |i |
477
492
p = ssl_protocols . detect { |x | x [ :id ] == i . id }
@@ -511,7 +526,12 @@ def output_endpoint_data(r)
511
526
report_good "BEAST attack - No"
512
527
end
513
528
514
- # puts "POODLE (SSLv3)- ?"
529
+ # POODLE (SSLv3)
530
+ if r . details . poodle?
531
+ report_bad "POODLE SSLv3 - Vulnerable"
532
+ else
533
+ report_good "POODLE SSLv3 - Not vulnerable"
534
+ end
515
535
516
536
# POODLE TLS
517
537
case r . details . poodle_tls
@@ -520,16 +540,23 @@ def output_endpoint_data(r)
520
540
when 0
521
541
report_warning "POODLE TLS - Unknown"
522
542
when 1
523
- report_good "POODLE TLS - No "
543
+ report_good "POODLE TLS - Not vulnerable "
524
544
when 2
525
- report_bad "POODLE TLS - Yes "
545
+ report_bad "POODLE TLS - Vulnerable "
526
546
end
527
547
528
548
# Downgrade attack prevention
529
549
if r . details . fallback_scsv?
530
- report_good "Downgrade attack prevention - Yes"
550
+ report_good "Downgrade attack prevention - Yes, TLS_FALLBACK_SCSV supported "
531
551
else
532
- report_bad "Downgrade attack prevention - No"
552
+ report_bad "Downgrade attack prevention - No, TLS_FALLBACK_SCSV not supported"
553
+ end
554
+
555
+ # Freak
556
+ if r . details . freak?
557
+ report_bad "Freak - Vulnerable"
558
+ else
559
+ report_good "Freak - Not vulnerable"
533
560
end
534
561
535
562
# RC4
@@ -553,7 +580,7 @@ def output_endpoint_data(r)
553
580
if r . details . heartbleed?
554
581
report_bad "Heartbleed (vulnerability) - Yes"
555
582
else
556
- report_good "Heartbeat (vulnerability) - No"
583
+ report_good "Heartbleed (vulnerability) - No"
557
584
end
558
585
559
586
# OpenSSL CCS
@@ -687,7 +714,7 @@ def output_testing_details(r)
687
714
return unless r . status == "IN_PROGRESS"
688
715
689
716
if r . endpoints . length == 1
690
- print_status "#{ r . host } (#{ r . endpoints [ 0 ] . ip_address } ) - Progress #{ r . endpoints [ 0 ] . progress } % (#{ r . endpoints [ 0 ] . status_details_message } )"
717
+ print_status "#{ r . host } (#{ r . endpoints [ 0 ] . ip_address } ) - Progress #{ [ r . endpoints [ 0 ] . progress , 0 ] . max } % (#{ r . endpoints [ 0 ] . status_details_message } )"
691
718
elsif r . endpoints . length > 1
692
719
in_progress_srv_num = 0
693
720
ready_srv_num = 0
@@ -696,7 +723,7 @@ def output_testing_details(r)
696
723
case e . status_message . to_s
697
724
when "In progress"
698
725
in_progress_srv_num += 1
699
- print_status "Scanned host: #{ e . ip_address } (#{ e . server_name } )- #{ e . progress } % complete (#{ e . status_details_message } )"
726
+ print_status "Scanned host: #{ e . ip_address } (#{ e . server_name } )- #{ [ e . progress , 0 ] . max } % complete (#{ e . status_details_message } )"
700
727
when "Pending"
701
728
pending_srv_num += 1
702
729
when "Ready"
@@ -715,7 +742,6 @@ def valid_hostname?(hostname)
715
742
716
743
def run
717
744
delay = datastore [ 'DELAY' ]
718
-
719
745
hostname = datastore [ 'HOSTNAME' ]
720
746
unless valid_hostname? ( hostname )
721
747
print_status "Invalid hostname"
0 commit comments