fixes #4131, EXE::Custom NameError

bug/bundler_fix
Joshua Smith 2014-11-05 22:10:54 -06:00
parent 54c1e13a98
commit 265c178c52
1 changed files with 3 additions and 2 deletions

View File

@ -38,10 +38,11 @@ module Exploit::EXE
obfus_eicar.join("-").upcase
end
def get_custom_exe(path=nil)
def get_custom_exe(path = nil)
path ||= datastore['EXE::Custom']
print_status("Using custom payload #{path}, RHOST and RPORT settings will be ignored!")
datastore['DisablePayloadHandler'] = true
exe = ''
::File.open(path,'rb') {|f| exe = f.read(f.stat.size)}
exe
end
@ -160,7 +161,7 @@ protected
end
def exe_post_generation(opts)
if (opts[:fellback])
if opts[:fellback]
print_status("Warning: Falling back to default template: #{opts[:fellback]}")
end
end