Skip to content

Commit b2de5ab

Browse files
committed
Fix rapid7#9075, super setup fix for local exploits
1 parent 88585a5 commit b2de5ab

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

lib/msf/core/post.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ def setup
3434
raise Msf::MissingActionError, "Please use: #{m.actions.collect {|e| e.name} * ", "}"
3535
end
3636

37-
# PostMixin
37+
# Msf::Module(Msf::PostMixin)#setup
3838
super
3939
end
4040

lib/msf/core/post_mixin.rb

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,9 @@ def setup
3939
print_warning('SESSION may not be compatible with this module.')
4040
end
4141

42+
# Msf::Exploit#setup for exploits, NoMethodError for post modules
43+
super rescue NoMethodError
44+
4245
check_for_session_readiness() if session.type == "meterpreter"
4346

4447
@session.init_ui(self.user_input, self.user_output)

0 commit comments

Comments
 (0)