check for a ancestors instead of a straight comparison of classes when matching payloads for generics, fixes #3477

git-svn-id: file:///home/svn/framework3/trunk@11585 4d416f70-5f16-0410-b530-b9f4589650da
unstable
James Lee 2011-01-17 17:15:43 +00:00
parent 4384618950
commit 63934c34ec
1 changed files with 2 additions and 2 deletions

View File

@ -239,10 +239,10 @@ class PayloadSet < ModuleSet
next if (p.kind_of?(Msf::Payload::Generic))
# Check to see if the handler classes match.
next if (handler and p.handler_klass != handler)
next if (handler and not p.handler_klass.ancestors.include?(handler))
# Check to see if the session classes match.
next if (session and p.session != session)
next if (session and not p.session.ancestors.include?(session))
# Check for matching payload types
next if (payload_type and p.payload_type != payload_type)