Pro Module API
pro.module_search
The pro.module_search method scans the module database and returns any entries matching the specified search query.
Request Example
[ "pro.module_search", "<token>", "dcom" ]
Response Example
{ "matches"=>
{"exploit/windows/dcerpc/ms03_026_dcom"=>
{"type" => "exploit",
"name" => "Microsoft RPC DCOM Interface Overflow",
"rank" => 500,
"description" => "Long description…",
"license" => "Metasploit Framework License (BSD)",
"filepath" => "[..]/windows/dcerpc/ms03_026_dcom.rb",
"version" => "11545",
"arch" => [],
"platform" => [],
"references" =>
[["CVE", "2003-0352"],
["OSVDB", "2100"],
["MSB", "MS03-026"],
["BID", "8205"]],
"authors" =>
["hdm <hdm[at]metasploit.com>",
"spoonm <spoonm@no$email.com>",
"cazz <bmc[at]shmoo.com>"],
"privileged" => true,
"disclosure_date" => 1058313600,
"targets" => {0=>"Windows NT SP3-6a/2000/XP/2003 Universal"},
"default_target" =>"0",
"stance" => "aggressive"}, …
}
}
}
pro.module_validate
The pro.module_validate method is used to determine whether a set of options satisfies the requirements of a given module.
Request Example
[ "pro.module_validate", "<token>",
"exploit/windows/smb/psexec", {
"RHOST" => "1.2.3.4"
}
]
Response Example
{ "result" => "success" }
Invalid options would result in the following:
Response Example
{
"result" => "failure",
"error" => "The following options failed to validate: RHOST."
}
pro.modules
The pro.modules method returns the full set of modules for a given type
Request Example
[ "pro.modules", "<token>", "post" ]
Response Example
{"modules" =>
{ "post/linux/gather/checkvm" =>
{"type" => "post",
"name" => "Linux Gather Virtual Environment Detection",
"rank" => 300,
"description" => "Long description…",
"license" => "Metasploit Framework License (BSD)",
"filepath" => "[…]post/linux/gather/checkvm.rb",
"version" => "13173",
"arch" => [],
"platform" => ["Msf::Module::Platform::Linux"],
"references" => [],
"authors" => ["Carlos Perez <carlos_perez[at]darkoperator.com>"],
"privileged" => false}, …
}
}
}