Fix usage of fail_with
parent
1aba7550f9
commit
b4fa535f2b
|
@ -114,7 +114,7 @@ class Metasploit3 < Msf::Exploit::Remote
|
|||
# If the server returns 200 and the body contains our payload name,
|
||||
# we assume we uploaded the malicious file successfully
|
||||
if not res or res.code != 200
|
||||
return fail_with(Exploit::Failure::None, "File wasn't uploaded, aborting!")
|
||||
fail_with(Exploit::Failure::None, "#{peer} - File wasn't uploaded, aborting!")
|
||||
end
|
||||
|
||||
register_files_for_cleanup("/tmp/ApplianceUpdate")
|
||||
|
@ -129,7 +129,7 @@ class Metasploit3 < Msf::Exploit::Remote
|
|||
# If we don't get a 200 when we request our malicious payload, we suspect
|
||||
# we don't have a shell, either.
|
||||
if res and res.code != 200
|
||||
return fail_with(Exploit::Failure::None, "Exploit failed!")
|
||||
print_error("#{peer} - Unexpected response, probably the exploit failed")
|
||||
end
|
||||
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue