Skip to content

Commit a038922

Browse files
committed
Land rapid7#7657, use platform for session_compatible? to support shell sessions
2 parents d08aff2 + 9ba6797 commit a038922

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/msf/core/post_mixin.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -162,14 +162,14 @@ def session_compatible?(sess_or_sid)
162162

163163
# Types are okay, now check the platform.
164164
if self.platform and self.platform.kind_of?(Msf::Module::PlatformList)
165-
return false unless self.platform.supports?(Msf::Module::PlatformList.transform(s.base_platform))
165+
return false unless self.platform.supports?(Msf::Module::PlatformList.transform(s.platform))
166166
end
167167

168168
# Check to make sure architectures match
169169
mod_arch = self.module_info['Arch']
170170
unless mod_arch.nil?
171171
mod_arch = [mod_arch] unless mod_arch.kind_of?(Array)
172-
return false unless mod_arch.include? s.base_arch
172+
return false unless mod_arch.include? s.arch
173173
end
174174

175175
# If we got here, we haven't found anything that definitely

0 commit comments

Comments
 (0)