correct passive?() for post modules, see #3542

git-svn-id: file:///home/svn/framework3/trunk@11589 4d416f70-5f16-0410-b530-b9f4589650da
unstable
James Lee 2011-01-17 20:50:30 +00:00
parent 1c2a968327
commit 9df78e8f47
1 changed files with 8 additions and 5 deletions

View File

@ -19,6 +19,9 @@ class Post < Msf::Module
register_options( [
OptInt.new('SESSION', [ true, "The session to run this module on." ])
] , Msf::Post)
# Default stance is active
self.passive = (info['Passive'] and info['Passive'] == true) || false
end
#
@ -73,11 +76,8 @@ class Post < Msf::Module
{}
end
#
# Default stance is active
#
def passive
false
def passive?
self.passive
end
def compatible_sessions
@ -89,6 +89,9 @@ class Post < Msf::Module
sessions
end
attr_reader :passive
protected
attr_writer :passive
end
end