PowerShell Script Blocks Register Malicious XLL via Office COM Automation on Windows

Detects PowerShell Script Block content that uses COM automation to call .RegisterXLL for an Office XLL add-in.

FreeReviewedSigma · High · v2
Product
windows
Category
ps_script
Author
frack113 (SigmaHQ), DRL 1.1
Published
2021-12-28
Updated
2026-07-31

ATT&CK techniques

Persistence
  1. Recon

  2. Resource Dev

  3. Initial Access

  4. Execution

  5. Persistence

  6. Priv Esc

  7. Defense Evasion

  8. Cred Access

  9. Discovery

  10. Lateral Movement

  11. Collection

  12. C2

  13. Exfiltration

  14. Impact

What it detects

This rule identifies PowerShell script block content that creates a COM object for an Office application and invokes RegisterXLL, which can register and load an Office XLL add-in. Attackers may use this technique to execute code through Office extensibility mechanisms and establish persistence. The detection relies on script block text telemetry showing the use of new-object, COM automation, and the RegisterXLL method call.

Related detections3 linkedT1137.006 — drag to rearrange
Windows Registry: Excel Options Run Entry Point for XLL Add-in Persistence
Windows Registry Persistence via VSTO Add-ins in Microsoft Office
Windows Office Startup Add-In Persistence via .wll/.xll/.xlam
PowerShell Script Blocks Register Malicious XLL via Office COM Automation on Windows
Pivot detection · T1137.006 · 3 related

Changelog

v2
  1. v2
    Candidate ingested via manual entry.2026-07-31
  2. v1
    No changelog recorded for this version.2026-07-30

Detection content is published as a reviewed draft. Tune thresholds and exclusions against your own telemetry before enabling this rule for alerting.