Use FileDropper

bug/bundler_fix
jvazquez-r7 2014-09-19 16:58:21 -05:00
parent 6fd5027e05
commit 0267e889e2
1 changed files with 2 additions and 0 deletions

View File

@ -10,6 +10,7 @@ class Metasploit3 < Msf::Exploit::Remote
include Msf::Exploit::Remote::Tcp
include Msf::Exploit::Remote::HttpClient
include Msf::Exploit::FileDropper
def initialize(info = {})
super(update_info(info,
@ -106,6 +107,7 @@ class Metasploit3 < Msf::Exploit::Remote
if res && res.code == 200 && res.body && res.body.to_s =~ /Success! File location.*>.*#{target_uri.path.to_s}(.*)#{payload_name}</
upload_path = $1
print_good("#{peer} - File uploaded to #{upload_path}")
register_file_for_cleanup(payload_name)
else
fail_with(Failure::Unknown, "#{peer} - Upload failed")
end