Skip to content

Commit

Permalink
Update misc.py
Browse files Browse the repository at this point in the history
  • Loading branch information
doomedraven committed Feb 7, 2025
1 parent 626449d commit c5a91ca
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions modules/signatures/windows/misc.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,8 +123,7 @@ class PotentialProtocolTunnelingViaLegitUtilities(Signature):
evented = True

def run(self):
cmdlines = self.results.get("behavior").get("summary").get("executed_commands")
for cmdline in cmdlines:
for cmdline in self.results.get("behavior", {}).get("summary", {}).get("executed_commands", []):
lower = cmdline.lower()
if (
"3389" in lower
Expand Down Expand Up @@ -606,8 +605,7 @@ class MountCopyToWebDavShare(Signature):
evented = True

def run(self):
cmdlines = self.results.get("behavior").get("summary").get("executed_commands")
for cmdline in cmdlines:
for cmdline in self.results.get("behavior", {}).get("summary", {}).get("executed_commands", []):
lower = cmdline.lower()
if ("rundll32.exe" in lower and "\\program files\\microsoft office\\root\\office16\\mlcfg32.cpl" in lower) or (
any(
Expand All @@ -624,7 +622,7 @@ def run(self):
if (
("explorer.exe" in lower and "\\" in lower and "@" in lower)
or ("net.exe" in lower and "use" in lower)
or (any(arg in lower for arg in ("http", "webdav")) and "/user" in lower and not "//localhost" in lower)
or (any(arg in lower for arg in ("http", "webdav")) and "/user" in lower and "//localhost" not in lower)
or (
any(proc in lower for proc in ("expand.exe", "xcopy.exe", "cmd.exe"))
and any(arg in lower for arg in ("\\\\webdav", "davwwwroot"))
Expand Down

0 comments on commit c5a91ca

Please sign in to comment.