diff --git a/monkey_island/cc/resources/pthmap.py b/monkey_island/cc/resources/pthmap.py
index ffb681c75..f9819dd79 100644
--- a/monkey_island/cc/resources/pthmap.py
+++ b/monkey_island/cc/resources/pthmap.py
@@ -120,6 +120,12 @@ class Machine(object):
if self.latest_system_info.count() > 0:
self.latest_system_info = self.latest_system_info[0]
+ def __eq__(self, other):
+ if isinstance(other, self.__class__):
+ return self.monkey_guid == other.monkey_guid
+ else:
+ return False
+
@cache
def GetMimikatzOutput(self):
doc = self.latest_system_info
@@ -940,6 +946,7 @@ class PassTheHashMap(object):
def main():
pth = PassTheHashMap()
+ print """"""
print "
Pass The Hash Report
"
print "Duplicated Passwords
"
@@ -1010,7 +1017,13 @@ def main():
print """"""
for sid in pth.GetThreateningUsersByVictim(m):
- print """- {username}
""".format(sid=sid, username=pth.GetUsernameBySid(sid))
+ print """- {username} attackers:
""".format(sid=sid, username=pth.GetUsernameBySid(sid))
+
+ for mm in pth.GetAttackersBySid(sid):
+ if m == mm:
+ continue
+ print """- {ip}
""".format(ip=mm.GetIp())
+ print """ """
print """ | """
print """"""
@@ -1034,7 +1047,13 @@ def main():
print """"""
for sid in pth.GetThreateningUsersByVictim(m):
- print """- {username}
""".format(sid=sid, username=pth.GetUsernameBySid(sid))
+ print """- {username} attackers:
""".format(sid=sid, username=pth.GetUsernameBySid(sid))
+
+ for mm in pth.GetAttackersBySid(sid):
+ if m == mm:
+ continue
+ print """- {ip}
""".format(ip=mm.GetIp())
+ print """ """
print """ | """
print """"""
@@ -1177,13 +1196,13 @@ def main():
""".format(username=pth.GetUsernameBySid(sid), sid=sid, secret=pth.GetSecretBySid(sid), domain=pth.GetSidInfo(sid)["Domain"])
- print """Possible Victims Machines
"""
+ print """Machines the sid is local admin on
"""
print """"""
for m in pth.GetVictimsBySid(sid):
print """- {ip} ({hostname})
""".format(ip=m.GetIp(), hostname=m.GetHostName())
print """
"""
- print """Possible Attackers Machines
"""
+ print """Machines the sid is in thier cache
"""
print """"""
for m in pth.GetAttackersBySid(sid):
print """- {ip} ({hostname})
""".format(ip=m.GetIp(), hostname=m.GetHostName())