Potentially Suspicious Call To Win32_NTEventlogFile Class - PSScript (via ps_script)

This rule detects use of the WMI class "Win32_NTEventlogFile" in a potentially anomalous way (delete, backup, change permissions, etc.) from a PowerShell script

SigmamediumWindowsv1
sigma
title: Potentially Suspicious Call To Win32_NTEventlogFile Class - PSScript (via ps_script)
id: c5918a36-69ce-5002-b921-225a446c8ada
status: stable
description: This rule detects use of the WMI class "Win32_NTEventlogFile" in a potentially anomalous way (delete, backup, change permissions, etc.) from a PowerShell script
references:
    - https://learn.microsoft.com/en-us/previous-versions/windows/desktop/legacy/aa394225(v=vs.85)
author: Huntrule Team
date: 2026-06-08
tags:
    - attack.defense-impairment
    - attack.defense-evasion
    - attack.t1070.001
logsource:
    category: ps_script
    product: windows
    definition: bade5735-5ab0-4aa7-a642-a11be0e40872
detection:
    selection_class:
        ScriptBlockText|contains: 'Win32_NTEventlogFile'
    selection_function:
        ScriptBlockText|contains:
            - '.BackupEventlog('
            - '.ChangeSecurityPermissions('
            - '.ChangeSecurityPermissionsEx('
            - '.ClearEventLog('
            - '.Delete('
            - '.DeleteEx('
            - '.Rename('
            - '.TakeOwnerShip('
            - '.TakeOwnerShipEx('
    condition: all of 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.