Merge pull request #424 from mr64bit/fix_agent_shell

Fix agent shell commands, broken in commit 3148493
mdns
Chris Ross 2016-12-23 20:36:55 -05:00 committed by GitHub
commit 89d06f06fb
1 changed files with 2 additions and 3 deletions

View File

@ -1624,8 +1624,7 @@ class PowerShellAgentMenu(cmd.Cmd):
if line != "":
# task the agent with this shell command
self.mainMenu.agents.add_agent_ta
sk_db(self.sessionID, "TASK_SHELL", "shell " + str(line))
self.mainMenu.agents.add_agent_task_db(self.sessionID, "TASK_SHELL", "shell " + str(line))
# update the agent log
msg = "Tasked agent to run shell command " + line
self.mainMenu.agents.save_agent_log(self.sessionID, msg)
@ -3289,7 +3288,7 @@ class ModuleMenu(cmd.Cmd):
elif line.split(' ')[1].lower().endswith("host"):
return [helpers.lhost()]
elif line.split(' ')[1].lower().endswith("language"):
languages = ['powershell', 'python']
end_line = ' '.join(line.split(' ')[1:])