Prefix the module name if it was not provided. Fixes #5309 by making this work either way

git-svn-id: file:///home/svn/framework3/trunk@13647 4d416f70-5f16-0410-b530-b9f4589650da
unstable
HD Moore 2011-08-28 20:27:47 +00:00
parent 6853221762
commit 1c401908f1
1 changed files with 4 additions and 0 deletions

View File

@ -229,6 +229,10 @@ class RPC_Module < RPC_Base
private
def _find_module(mtype,mname)
if mname !~ /^(exploit|payload|nop|encoder|auxiliary|post)$/
mname = mtype + "/" + mname
end
mod = self.framework.modules.create(mname)
error(500, "Invalid Module") if not mod
mod