Possible User Enumeration And Export Through Get-ADUser Cmdlet - PowerShell (via ps_script)

This rule detects use of the Get-ADUser cmdlet to collect user information and output it to a file

SigmamediumWindowsv1
sigma
title: Possible User Enumeration And Export Through Get-ADUser Cmdlet - PowerShell (via ps_script)
id: c8dd5004-4f7c-5d3e-8f67-839b935f8303
status: stable
description: This rule detects use of the Get-ADUser cmdlet to collect user information and output it to a file
references:
    - https://attack.mitre.org/techniques/T1033/
    - http://blog.talosintelligence.com/2022/09/lazarus-three-rats.html
    - https://www.microsoft.com/en-us/security/blog/2022/10/18/defenders-beware-a-case-for-post-ransomware-investigations/
author: Huntrule Team
date: 2026-02-21
tags:
    - attack.discovery
    - attack.t1033
logsource:
    product: windows
    category: ps_script
    definition: 'Requirements: Script Block Logging must be enabled'
detection:
    selection:
        ScriptBlockText|contains|all:
            - 'Get-ADUser '
            - ' -Filter \*'
        ScriptBlockText|contains:
            - ' > '
            - ' | Select '
            - 'Out-File'
            - 'Set-Content'
            - 'Add-Content'
    condition: selection
falsepositives:
    - Unknown
level: medium

Known false positives

  • Unknown

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