← Back to SOC feed Coverage →

Scripting/CommandLine Process Spawned Regsvr32

sigma MEDIUM SigmaHQ
T1218.010
imProcessCreate
powershell
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-18T23:00:00Z · Confidence: medium

Hunt Hypothesis

Detects various command line and scripting engines/processes such as “PowerShell”, “Wscript”, “Cmd”, etc. spawning a “regsvr32” instance.

Detection Rule

Sigma (Original)

title: Scripting/CommandLine Process Spawned Regsvr32
id: ab37a6ec-6068-432b-a64e-2c7bf95b1d22
related:
    - id: 8e2b24c9-4add-46a0-b4bb-0057b4e6187d
      type: obsolete
status: test
description: Detects various command line and scripting engines/processes such as "PowerShell", "Wscript", "Cmd", etc. spawning a "regsvr32" instance.
references:
    - https://web.archive.org/web/20171001085340/https://subt0x10.blogspot.com/2017/04/bypass-application-whitelisting-script.html
    - https://app.any.run/tasks/34221348-072d-4b70-93f3-aa71f6ebecad/
author: Florian Roth (Nextron Systems), Nasreddine Bencherchali (Nextron Systems)
date: 2023-05-26
tags:
    - attack.stealth
    - attack.t1218.010
logsource:
    category: process_creation
    product: windows
detection:
    selection:
        ParentImage|endswith:
            - '\cmd.exe'
            - '\cscript.exe'
            - '\mshta.exe'
            - '\powershell_ise.exe'
            - '\powershell.exe'
            - '\pwsh.exe'
            - '\wscript.exe'
        Image|endswith: '\regsvr32.exe'
    filter_main_rpcproxy:
        ParentImage: C:\Windows\System32\cmd.exe
        CommandLine|endswith: ' /s C:\Windows\System32\RpcProxy\RpcProxy.dll'
    condition: selection and not 1 of filter_main_*
falsepositives:
    - Legitimate ".bat", ".hta", ".ps1" or ".vbs" scripts leverage legitimately often. Apply additional filter and exclusions as necessary
    - Some legitimate Windows services
level: medium # Can be reduced to low if you experience a ton of FP

KQL (Azure Sentinel)

imProcessCreate
| where (((ParentProcessName endswith "\\cmd.exe" or ParentProcessName endswith "\\cscript.exe" or ParentProcessName endswith "\\mshta.exe" or ParentProcessName endswith "\\powershell_ise.exe" or ParentProcessName endswith "\\powershell.exe" or ParentProcessName endswith "\\pwsh.exe" or ParentProcessName endswith "\\wscript.exe") or (ActingProcessName endswith "\\cmd.exe" or ActingProcessName endswith "\\cscript.exe" or ActingProcessName endswith "\\mshta.exe" or ActingProcessName endswith "\\powershell_ise.exe" or ActingProcessName endswith "\\powershell.exe" or ActingProcessName endswith "\\pwsh.exe" or ActingProcessName endswith "\\wscript.exe")) and TargetProcessName endswith "\\regsvr32.exe") and (not(((ParentProcessName =~ "C:\\Windows\\System32\\cmd.exe" or ActingProcessName =~ "C:\\Windows\\System32\\cmd.exe") and TargetProcessCommandLine endswith " /s C:\\Windows\\System32\\RpcProxy\\RpcProxy.dll")))

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_regsvr32_susp_parent.yml