This reverts commit 96945442ff.

With this PR, the following now appears in framework.log:

````
[07/30/2014 14:01:37] [e(0)] core: Error updating module details for
auxiliary/fuzzers/http/http_form_field: NoMethodError undefined method
`name' for []:Array
````
bug/bundler_fix
Tod Beardsley 2014-07-30 14:06:46 -05:00
parent 4ed085d0d2
commit 3320a1ef77
1 changed files with 9 additions and 7 deletions

View File

@ -16,23 +16,25 @@ module Msf::Module::HasActions
def action
sa = datastore['ACTION']
sa ? find_action(sa) : find_action(default_action)
return find_action(default_action) if not sa
return find_action(sa)
end
def find_action(name)
if name
actions.each do |a|
return a if a.name == name
end
return nil if not name
actions.each do |a|
return a if a.name == name
end
return nil
end
#
# Returns a boolean indicating whether this module should be run passively
#
def passive?
act = action
act ? passive_action?(act.name) : self.passive
act = action()
return passive_action?(act.name) if act
return self.passive
end
#