Detection rule
Potentially Suspicious NTFS Symlink Behavior Modification
Overview
Detects the modification of NTFS symbolic link behavior using fsutil, which could be used to enable remote to local or remote to remote symlinks for potential attacks.
- Rule id
c0b2768a-dd06-4671-8339-b16ca8d1f27f- ATT&CK techniques
- T1059 Command and Scripting Interpreter, T1222.001 File and Directory Permissions Modification: Windows Permissions
- Severity
- Medium
- Confidence
- Low
- Origin
- SigmaHQ (community)
- SigmaHQ status
test- Used in defense packs
- n0n, The Gentlemen, Akira, safepay, rhysida, Play, nightspire, majinahanashi
Validation
- ExperimentalSyntax checked only. Not yet tested on events.
- Test-data validatedMatched positive test events and ignored near-miss events. Not yet run in a production SIEM.
- SIEM-validatedRun in a real SIEM, with a recorded result.
2 of 2 positive test events matched; 1 of 1 near-miss events were correctly ignored. Community rule reused unmodified from SigmaHQ. OffSet7 converted it and tested it on synthetic events.
Detection logic and queries
Queries are shown exactly as generated. Test them in your environment before you deploy them.
Sigma
Sigma (YAML) · c0b2768a-dd06-4671-8339-b16ca8d1f27f
title: Potentially Suspicious NTFS Symlink Behavior Modification
id: c0b2768a-dd06-4671-8339-b16ca8d1f27f
status: test
description: |
Detects the modification of NTFS symbolic link behavior using fsutil, which could be used to enable remote to local or remote to remote symlinks for potential attacks.
references:
- https://www.cybereason.com/blog/cybereason-vs.-blackcat-ransomware
- https://learn.microsoft.com/fr-fr/windows-server/administration/windows-commands/fsutil-behavior
- https://thedfirreport.com/2025/06/30/hide-your-rdp-password-spray-leads-to-ransomhub-deployment/
author: frack113, The DFIR Report
date: 2022-03-02
modified: 2025-11-13
tags:
- attack.execution
- attack.defense-impairment
- attack.t1059
- attack.t1222.001
logsource:
category: process_creation
product: windows
detection:
selection_img_proxy:
# Note: Example command observed: cmd.exe /c "fsutil behaviour set SymlinkEvaluation"
- Image|endswith:
- '\cmd.exe'
- '\powershell.exe'
- '\pwsh.exe'
- OriginalFileName:
- 'Cmd.Exe'
- 'PowerShell.EXE'
- 'pwsh.dll'
selection_fsutil_cli:
CommandLine|contains|all:
- 'fsutil'
- 'behavior'
- 'set'
- 'SymlinkEvaluation'
selection_symlink_params:
CommandLine|contains:
- 'R2L:1' # Remote to Local
- 'R2R:1' # Remote to Remote
- 'L2L:1' # Local to Local
condition: all of selection_*
falsepositives:
- Legitimate usage, investigate the parent process and context to determine if benign.
level: medium
regression_tests_path: regression_data/rules/windows/process_creation/proc_creation_win_fsutil_symlinkevaluation/info.ymlQRadar AQL
IBM QRadar AQL (hunting query)Hunting query
Hunting search for the Log Activity tab or the API. It is not a QRadar rule.
AQL search for the Log Activity tab or the API. It is NOT a deployable QRadar rule: real-time detection in QRadar is a CRE (Custom Rule Engine) rule, for which this build only writes a design specification (qradar_cre).
SELECT * FROM events WHERE devicetype=12 AND (((LOWER("Process Path") LIKE '%\cmd.exe' OR LOWER("Process Path") LIKE '%\powershell.exe' OR LOWER("Process Path") LIKE '%\pwsh.exe') OR (LOWER("Process Name") LIKE '%\cmd.exe' OR LOWER("Process Name") LIKE '%\powershell.exe' OR LOWER("Process Name") LIKE '%\pwsh.exe')) OR (Filename IN('Cmd.Exe', 'PowerShell.EXE', 'pwsh.dll'))) AND (LOWER(Command) LIKE '%fsutil%' AND LOWER(Command) LIKE '%behavior%' AND LOWER(Command) LIKE '%set%' AND LOWER(Command) LIKE '%symlinkevaluation%') AND (LOWER(Command) LIKE '%r2l:1%' OR LOWER(Command) LIKE '%r2r:1%' OR LOWER(Command) LIKE '%l2l:1%')QRadar CRE
Design for the QRadar Rule Wizard. It is not importable and has not been tested in QRadar.
- Rule name
OffSet7: Potentially Suspicious NTFS Symlink Behavior Modification- Rule type
- Event rule (Local)
- Log source types
- Microsoft Windows Security Event Log DSM: Security 4688 (with command-line auditing) or Sysmon EID 1
Building blocks
BB:OffSet7:Potentially Suspicious NTFS Symlink Behavior Mod:selection_img_proxy(match)Any of the groups matches (OR): build one BB per group and a parent BB "when an event matches any of" them.Process Path / Process Nameends with:\cmd.exe,\powershell.exe,\pwsh.exeFilenameis equal to (case-insensitive):Cmd.Exe,PowerShell.EXE,pwsh.dll
BB:OffSet7:Potentially Suspicious NTFS Symlink Behavior Mod:selection_fsutil_cli(match)All test lines must match (AND).Commandcontains:fsutil,behavior,set,SymlinkEvaluation
BB:OffSet7:Potentially Suspicious NTFS Symlink Behavior Mod:selection_symlink_params(match)All test lines must match (AND).Commandcontains:R2L:1,R2R:1,L2L:1
Main rule, option A (building blocks)
- when the event(s) were detected by one or more of these log source types:
Microsoft Windows Security Event Log DSM: Security 4688 (with command-line auditing) or Sysmon EID 1 - when an event matches the condition built from these building blocks:
(ALL of [BB:OffSet7:Potentially Suspicious NTFS Symlink Behavior Mod:selection_img_proxy, BB:OffSet7:Potentially Suspicious NTFS Symlink Behavior Mod:selection_fsutil_cli, BB:OffSet7:Potentially Suspicious NTFS Symlink Behavior Mod:selection_symlink_params])
Main rule, option B (AQL filter test)
- when the event matches this AQL filter query:
devicetype=12 AND (((LOWER("Process Path") LIKE '%\cmd.exe' OR LOWER("Process Path") LIKE '%\powershell.exe' OR LOWER("Process Path") LIKE '%\pwsh.exe') OR (LOWER("Process Name") LIKE '%\cmd.exe' OR LOWER("Process Name") LIKE '%\powershell.exe' OR LOWER("Process Name") LIKE '%\pwsh.exe')) OR (Filename IN('Cmd.Exe', 'PowerShell.EXE', 'pwsh.dll'))) AND (LOWER(Command) LIKE '%fsutil%' AND LOWER(Command) LIKE '%behavior%' AND LOWER(Command) LIKE '%set%' AND LOWER(Command) LIKE '%symlinkevaluation%') AND (LOWER(Command) LIKE '%r2l:1%' OR LOWER(Command) LIKE '%r2r:1%' OR LOWER(Command) LIKE '%l2l:1%')
Rule response
- Severity 5, credibility 6, relevance 7
- Ensure the detected event is part of an offense; index offense on Log Source (host) and annotate with the rule title and OffSet7 rule id
- Respond no more than once per 30 minutes per Log Source (tune per environment)
Limitations
- QRadar AQL LIKE / CRE string tests are case-sensitive unless the property is lower-cased; the AQL option uses LOWER() where the backend applied it.
Splunk
Splunk SPLSearch
Search for Splunk with Windows/Sysmon field names. A scheduled search or ES correlation search also needs a schedule, time range, throttling and an adaptive response, set in your environment.
(Image IN ("*\\cmd.exe", "*\\powershell.exe", "*\\pwsh.exe") OR OriginalFileName IN ("Cmd.Exe", "PowerShell.EXE", "pwsh.dll")) CommandLine="*fsutil*" CommandLine="*behavior*" CommandLine="*set*" CommandLine="*SymlinkEvaluation*" (CommandLine IN ("*R2L:1*", "*R2R:1*", "*L2L:1*"))Splunk savedsearches.conf stanzaScheduled search template
Template stanza. Review schedule, alert actions and index/sourcetype for your environment before enabling.
[default]
dispatch.earliest_time = -30d
dispatch.latest_time = now
[Potentially Suspicious NTFS Symlink Behavior Modification]
description = Detects the modification of NTFS symbolic link behavior using fsutil, which could be used to enable remote to local or remote to remote symlinks for potential attacks.
search = (Image IN ("*\\cmd.exe", "*\\powershell.exe", "*\\pwsh.exe") OR OriginalFileName IN ("Cmd.Exe", "PowerShell.EXE", "pwsh.dll")) CommandLine="*fsutil*" CommandLine="*behavior*" CommandLine="*set*" CommandLine="*SymlinkEvaluation*" (CommandLine IN ("*R2L:1*", "*R2R:1*", "*L2L:1*"))Microsoft Sentinel
Microsoft Sentinel KQL (ASIM)Hunting query
Hunting query over ASIM-normalized tables. An analytics rule also needs a schedule, entity mapping and alert grouping.
imProcessCreate
| where ((TargetProcessName endswith "\\cmd.exe" or TargetProcessName endswith "\\powershell.exe" or TargetProcessName endswith "\\pwsh.exe") or (TargetProcessFileOriginalName in~ ("Cmd.Exe", "PowerShell.EXE", "pwsh.dll"))) and (TargetProcessCommandLine contains "fsutil" and TargetProcessCommandLine contains "behavior" and TargetProcessCommandLine contains "set" and TargetProcessCommandLine contains "SymlinkEvaluation") and (TargetProcessCommandLine contains "R2L:1" or TargetProcessCommandLine contains "R2R:1" or TargetProcessCommandLine contains "L2L:1")Defender XDR
Microsoft Defender XDR KQLHunting query
Advanced hunting query. A custom detection rule also needs a frequency, impacted entities and actions.
DeviceProcessEvents
| where ((FolderPath endswith "\\cmd.exe" or FolderPath endswith "\\powershell.exe" or FolderPath endswith "\\pwsh.exe") or (ProcessVersionInfoOriginalFileName in~ ("Cmd.Exe", "PowerShell.EXE", "pwsh.dll"))) and (ProcessCommandLine contains "fsutil" and ProcessCommandLine contains "behavior" and ProcessCommandLine contains "set" and ProcessCommandLine contains "SymlinkEvaluation") and (ProcessCommandLine contains "R2L:1" or ProcessCommandLine contains "R2R:1" or ProcessCommandLine contains "L2L:1")Elastic
Elastic Lucene (ECS)Hunting query
Lucene query over ECS fields (Winlogbeat/Elastic Agent Windows mappings). A detection rule also needs an index pattern, schedule and actions.
((process.executable:(*\\cmd.exe OR *\\powershell.exe OR *\\pwsh.exe)) OR (process.pe.original_file_name:(Cmd.Exe OR PowerShell.EXE OR pwsh.dll))) AND (process.command_line:*fsutil* AND process.command_line:*behavior* AND process.command_line:*set* AND process.command_line:*SymlinkEvaluation*) AND (process.command_line:(*R2L\:1* OR *R2R\:1* OR *L2L\:1*))Elastic EQL (ECS)Hunting query
EQL query over ECS fields. Usable in an Elastic Security EQL rule after review; index pattern and schedule are set per environment.
any where ((process.executable like~ ("*\\cmd.exe", "*\\powershell.exe", "*\\pwsh.exe")) or (process.pe.original_file_name like~ ("Cmd.Exe", "PowerShell.EXE", "pwsh.dll"))) and (process.command_line:"*fsutil*" and process.command_line:"*behavior*" and process.command_line:"*set*" and process.command_line:"*SymlinkEvaluation*") and (process.command_line like~ ("*R2L:1*", "*R2R:1*", "*L2L:1*"))Elastic ES|QL (ECS)Hunting query
ES|QL query over ECS fields; the FROM clause uses * and must be narrowed to your indices.
from * metadata _id, _index, _version | where (ends_with(process.executable, "\\cmd.exe") or ends_with(process.executable, "\\powershell.exe") or ends_with(process.executable, "\\pwsh.exe") or process.pe.original_file_name in ("Cmd.Exe", "PowerShell.EXE", "pwsh.dll")) and process.command_line like "*fsutil*" and process.command_line like "*behavior*" and process.command_line like "*set*" and process.command_line like "*SymlinkEvaluation*" and (process.command_line like "*R2L:1*" or process.command_line like "*R2R:1*" or process.command_line like "*L2L:1*")Required telemetry
- Log source
product: windows · category: process_creation- Fields used
CommandLineImageOriginalFileName
False positives
- Legitimate usage, investigate the parent process and context to determine if benign.
Investigation and response
No OffSet7 investigation guidance has been written for this rule yet. Start from the false positives above and the ATT&CK technique pages.
References
Author and attribution
- Author
- frack113, The DFIR Report
- Source
- SigmaHQ ·
rules/windows/process_creation/proc_creation_win_fsutil_symlinkevaluation.yml - Upstream commit
9688134317a2- Licence
- Detection Rule License (DRL) 1.1
Version history
- Version 1Imported from SigmaHQ
- OffSet7 build · SigmaHQ
9688134317a2