Force option validation in exploit_simple for e & p

unstable
HD Moore 2012-03-12 22:57:23 -05:00
parent 1cf25e58d5
commit be6a64b3f7
1 changed files with 7 additions and 1 deletions

View File

@ -72,6 +72,9 @@ module Exploit
"You must specify a payload.", caller
end
# Verify the options
exploit.options.validate(exploit.datastore)
# Start it up
driver = ExploitDriver.new(exploit.framework)
@ -98,6 +101,9 @@ module Exploit
# Force the payload to share the exploit's datastore
driver.payload.share_datastore(driver.exploit.datastore)
# Verify the payload options
driver.payload.options.validate(driver.payload.datastore)
# If we still have no target index, try to use the datastore's index
target_idx = opts['Target'] || exploit.default_target