Make EXE::Custom an OptPath so it can be tab'd
parent
bc9014e912
commit
1eb4900102
|
@ -16,7 +16,7 @@ module Exploit::EXE
|
|||
|
||||
register_advanced_options(
|
||||
[
|
||||
OptString.new( 'EXE::Custom', [ false, 'Use custom exe instead of automatically generating a payload exe']),
|
||||
OptPath.new( 'EXE::Custom', [ false, 'Use custom exe instead of automatically generating a payload exe']),
|
||||
OptString.new( 'EXE::Path', [ false, 'The directory in which to look for the executable template' ]),
|
||||
OptString.new( 'EXE::Template', [ false, 'The executable template file name.' ]),
|
||||
OptBool.new( 'EXE::Inject', [ false, 'Set to preserve the original EXE function' ]),
|
||||
|
@ -26,6 +26,7 @@ module Exploit::EXE
|
|||
end
|
||||
|
||||
def get_custom_exe
|
||||
print_status("Using custom executable #{datastore["EXE::Custom"]}, RHOST and RPORT settins will be ignored!")
|
||||
datastore['DisablePayloadHandler'] = true
|
||||
file = ::File.open(datastore['EXE::Custom'],'rb')
|
||||
exe = file.read(file.stat.size)
|
||||
|
|
Loading…
Reference in New Issue