Add confirmation datastore option
parent
a92256e8d1
commit
ffd90a3d38
|
@ -42,10 +42,19 @@ class Metasploit3 < Msf::Auxiliary
|
||||||
[
|
[
|
||||||
OptString.new('TARGETURI', [true, 'The URI path to the web application', '/']),
|
OptString.new('TARGETURI', [true, 'The URI path to the web application', '/']),
|
||||||
OptString.new('FILE', [true, 'The file to obtain', '/a10data/key/mydomain.tld']),
|
OptString.new('FILE', [true, 'The file to obtain', '/a10data/key/mydomain.tld']),
|
||||||
OptInt.new('DEPTH', [true, 'The max traversal depth to root directory', 10])
|
OptInt.new('DEPTH', [true, 'The max traversal depth to root directory', 10]),
|
||||||
|
OptBool.new('CONFIRM', [true, 'Run the module, even when it will delete files', false]),
|
||||||
], self.class)
|
], self.class)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def run
|
||||||
|
unless datastore['CONFIRM']
|
||||||
|
print_error("This module will delete files on vulnerable systems. Please, set CONFIRM in order to run it.")
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
|
super
|
||||||
|
end
|
||||||
|
|
||||||
def run_host(ip)
|
def run_host(ip)
|
||||||
peer = "#{ip}:#{rport}"
|
peer = "#{ip}:#{rport}"
|
||||||
|
|
Loading…
Reference in New Issue