Detectionhightest

NTFS Alternate Data Stream

Detects writing data into NTFS alternate data streams from powershell. Needs Script Block Logging.

Open in Detection LabConvert ruleBuild Package
Sami RuohonenCreated 2018-07-24Updated 2022-12-258c521530-5169-495d-a199-0a3a881ad24ewindows
Log Source
WindowsPowerShell Script
ProductWindows← raw: windows
CategoryPowerShell Script← raw: ps_script

Definition

Requirements: Script Block Logging must be enabled

Detection Logic
Detection Logic2 selectors
detection:
    selection_content:
        ScriptBlockText|contains:
            - set-content
            - add-content
    selection_stream:
        ScriptBlockText|contains: '-stream'
    condition: all of selection*
False Positives
Unknown

False positive likelihood has not been assessed. Additional context may be needed during triage.

Testing & Validation

Regression Tests

by frack113
Positive Detection Test1 matchevtx

Microsoft-Windows-PowerShell

Rule Metadata
Rule ID
8c521530-5169-495d-a199-0a3a881ad24e
Status
test
Level
high
Type
Detection
Created
2018-07-24
Modified
2022-12-25
Path
rules/windows/powershell/powershell_script/posh_ps_ntfs_ads_access.yml
Raw Tags
attack.stealthattack.t1564.004attack.executionattack.t1059.001
View on GitHub