Windows File Events: Suspicious Legitimate Apps Dropping Script Files
Detects Windows legitimate/signed executables dropping script files (.ps1, .vbs, .js, etc.) to disk, indicating potential script-based abuse.
FreeUnreviewedSigmahighv1
windows-file-events-suspicious-legitimate-apps-dropping-script-files-7d604714
title: "Windows File Events: Suspicious Legitimate Apps Dropping Script Files"
id: f16a5953-5806-4085-b638-d1dacc0de7a3
status: test
description: This rule flags Windows processes commonly abused in script-based execution that write script file types to disk. It targets cases where a trusted application drops .bat, .js, .ps1, .vbs, .wsf, and other script-like artifacts, which can indicate malware staging or code execution using a legitimate executable. It relies on file creation telemetry that records the initiating process image path and the target filename extensions, with a specific exclusion for the mshta.exe → .hta pairing.
references:
- https://github.com/Neo23x0/sysmon-config/blob/3f808d9c022c507aae21a9346afba4a59dd533b9/sysmonconfig-export-block.xml#L1326
- https://dmpdump.github.io/posts/TelegramRat/
- https://www.virustotal.com/gui/file/a0d5b30578acd1df9139e7a8a4bfc659dc2cf48f4dc0c5804b70890adeb9fa21/behavior
- https://github.com/SigmaHQ/sigma/blob/master/rules/windows/file/file_event/file_event_win_susp_legitimate_app_dropping_script.yml
author: frack113, Florian Roth (Nextron Systems), Huntrule Team
date: 2022-08-21
modified: 2026-05-11
tags:
- attack.stealth
- attack.t1218
logsource:
product: windows
category: file_event
detection:
selection:
Image|endswith:
- \eqnedt32.exe
- \wordpad.exe
- \wordview.exe
- \certutil.exe
- \certoc.exe
- \CertReq.exe
- \Desktopimgdownldr.exe
- \esentutl.exe
- \mshta.exe
- \AcroRd32.exe
- \RdrCEF.exe
- \hh.exe
- \finger.exe
TargetFilename|endswith:
- .bat
- .chm
- .csproj
- .hta
- .js
- .jse
- .proj
- .ps1
- .py
- .scf
- .vbe
- .vbs
- .wsf
- .wsh
filter_main_mshta:
Image|endswith: \mshta.exe
TargetFilename|endswith: .hta
condition: selection and not 1 of filter_main_*
falsepositives:
- Unknown
level: high
regression_tests_path: regression_data/rules/windows/file/file_event/file_event_win_susp_legitimate_app_dropping_script/info.yml
license: DRL-1.1
related:
- id: 7d604714-e071-49ff-8726-edeb95a70679
type: derived
What it detects
This rule flags Windows processes commonly abused in script-based execution that write script file types to disk. It targets cases where a trusted application drops .bat, .js, .ps1, .vbs, .wsf, and other script-like artifacts, which can indicate malware staging or code execution using a legitimate executable. It relies on file creation telemetry that records the initiating process image path and the target filename extensions, with a specific exclusion for the mshta.exe → .hta pairing.
Known false positives
- Unknown
Detection content is published as a reviewed draft. Tune thresholds and exclusions against your own telemetry before enabling this rule for alerting.