Skip to content

Commit

Permalink
Merge pull request #1 from komand/use_exploit_fix
Browse files Browse the repository at this point in the history
fixed AttributeError when setting exploit
  • Loading branch information
lmilby-r7 authored Feb 28, 2018
2 parents e3f9edf + 74efbae commit d482b5a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/metasploit/msfrpc.py
Original file line number Diff line number Diff line change
Expand Up @@ -1328,8 +1328,11 @@ def __init__(self, rpc, mtype, mname):
self.modulename = mname
self.rpc = rpc
self._info = rpc.call(MsfRpcMethod.ModuleInfo, mtype, mname)
property_attributes = ["advanced", "evasion", "options", "required", "runoptions"]
for k in self._info:
setattr(self, k, self._info.get(k))
if k not in property_attributes:
# don't try to set property attributes
setattr(self, k, self._info.get(k))
self._moptions = rpc.call(MsfRpcMethod.ModuleOptions, mtype, mname)
self._roptions = []
self._aoptions = []
Expand Down

0 comments on commit d482b5a

Please sign in to comment.