Browse Source

Add sanity check for NUM_REQUESTS

Jon Hart 5 years ago
parent
commit
e86b18cdd4
No account linked to committer's email address
1 changed files with 7 additions and 0 deletions
  1. 7
    0
      lib/msf/core/auxiliary/drdos.rb

+ 7
- 0
lib/msf/core/auxiliary/drdos.rb View File

@@ -17,6 +17,13 @@ module Auxiliary::DRDoS
17 17
       ], self.class)
18 18
   end
19 19
 
20
+  def setup
21
+    super
22
+    if spoofed? && datastore['NUM_REQUESTS'] < 1
23
+      raise Msf::OptionValidateError.new(['NUM_REQUESTS']), 'The number of requests must be >= 1'
24
+    end
25
+  end
26
+
20 27
   def prove_amplification(response_map)
21 28
     vulnerable = false
22 29
     proofs = []

Loading…
Cancel
Save