← Back to SOC feed Coverage →

Invoke-Obfuscation Via Use MSHTA

sigma HIGH SigmaHQ
T1027T1059.001
imProcessCreate
evasionpowershell
This rule was pulled from an open-source repository and enriched with AI. Validate in a test environment before deploying to production.
View original rule at SigmaHQ →
Retrieved: 2026-05-09T11:00:00Z · Confidence: medium

Hunt Hypothesis

Detects Obfuscated Powershell via use MSHTA in Scripts

Detection Rule

Sigma (Original)

title: Invoke-Obfuscation Via Use MSHTA
id: ac20ae82-8758-4f38-958e-b44a3140ca88
status: test
description: Detects Obfuscated Powershell via use MSHTA in Scripts
references:
    - https://github.com/SigmaHQ/sigma/issues/1009   # (Task31)
author: Nikita Nazarov, oscd.community
date: 2020-10-08
modified: 2022-03-08
tags:
    - attack.stealth
    - attack.t1027
    - attack.execution
    - attack.t1059.001
logsource:
    category: process_creation
    product: windows
detection:
    selection:
        CommandLine|contains|all:
            - 'set'
            - '&&'
            - 'mshta'
            - 'vbscript:createobject'
            - '.run'
            - '(window.close)'
    condition: selection
falsepositives:
    - Unknown
level: high

KQL (Azure Sentinel)

imProcessCreate
| where TargetProcessCommandLine contains "set" and TargetProcessCommandLine contains "&&" and TargetProcessCommandLine contains "mshta" and TargetProcessCommandLine contains "vbscript:createobject" and TargetProcessCommandLine contains ".run" and TargetProcessCommandLine contains "(window.close)"

Required Data Sources

Sentinel TableNotes
imProcessCreateEnsure this data connector is enabled

False Positive Guidance

MITRE ATT&CK Context

References

Original source: https://github.com/SigmaHQ/sigma/blob/master/rules/windows/process_creation/proc_creation_win_hktl_invoke_obfuscation_via_use_mhsta.yml