Windows file events: Winrm.vbs payload XSL execution artifacts WsmPty.xsl/WsmTxt.xsl outside system folders

Alert on WsmPty.xsl/WsmTxt.xsl files written outside System32 and SysWOW64, consistent with WinRM VBScript misuse.

FreeReviewedSigma · Medium · v2
Product
windows
Category
file_event
Author
Julia Fomina, oscd.community (SigmaHQ), DRL 1.1
Published
2020-10-06
Updated
2026-07-31
title: "Windows file events: Winrm.vbs payload XSL execution artifacts WsmPty.xsl/WsmTxt.xsl outside system folders"
id: 5152038c-f9c6-4eec-b552-ad3dd47a9c3a
related:
  - id: 074e0ded-6ced-4ebd-8b4d-53f55908119d
    type: derived
  - id: d353dac0-1b41-46c2-820c-d7d2561fc6ed
    type: derived
status: test
description: This rule identifies file activity where attacker-controlled Winrm.vbs-related artifacts named WsmPty.xsl or WsmTxt.xsl are written outside the Windows System32 or SysWOW64 directories. Attackers may use these XSL files as part of a WinRM-related application whitelist bypass and unsigned code execution workflow. It relies on Windows file event telemetry capturing TargetFilename and whether the file is located in system folders.
references:
  - https://posts.specterops.io/application-whitelisting-bypass-and-arbitrary-unsigned-code-execution-technique-in-winrm-vbs-c8c24fb40404
  - https://github.com/SigmaHQ/sigma/blob/master/rules/windows/file/file_event/file_event_win_winrm_awl_bypass.yml
author: Julia Fomina, oscd.community, Huntrule Team
date: 2020-10-06
modified: 2022-11-28
tags:
  - attack.stealth
  - attack.t1216
logsource:
  product: windows
  category: file_event
detection:
  system_files:
    TargetFilename|endswith:
      - WsmPty.xsl
      - WsmTxt.xsl
  in_system_folder:
    TargetFilename|startswith:
      - C:\Windows\System32\
      - C:\Windows\SysWOW64\
  condition: system_files and not in_system_folder
falsepositives:
  - Unlikely
level: medium
license: DRL-1.1