Detection rules › Sigma

Sigma rules: 3h

RuleSeverity
AppX Located in Uncommon Directory Added to Deployment Pipelinemedium
Arbitrary Binary Execution Using GUP Utilitymedium
Arbitrary File Download Via ConfigSecurityPolicy.EXEmedium
Azure Unusual Authentication Interruptionmedium
Cscript/Wscript Uncommon Script Extension Executionhigh
DNS Server Discovery Via LDAP Querylow
EventLog Query Requests By Builtin Utilitiesmedium
File Decryption Using Gpg4winmedium
Google Workspace Role Modified or Deletedmedium
Hypervisor Enforced Paging Translation Disabledhigh
Insecure Transfer Via Curl.EXEmedium
Local Firewall Rules Enumeration Via NetFirewallRule Cmdletlow
Microsoft Defender Blocked from Loading Unsigned DLLhigh
Mimikatz Pass-the-hash loginhigh
New network file share createdmedium
Potential GobRAT File Discovery Via Grephigh
Potential Hidden Directory Creation Via NTFS INDEX_ALLOCATION Stream - CLImedium
Potential Lateral Movement via Windows Remote Shellmedium
Potential Persistence Via Microsoft Compatibility Appraisermedium
Potential SAP NetWeaver Webshell Creation - Linuxmedium
Potential SpEL Injection In Spring Frameworkhigh
Potential Suspicious Winget Package Installationhigh
Potentially Suspicious Long Filename Pattern - Linuxlow
RBAC Permission Enumeration Attemptlow
Rhadamanthys Stealer Module Launch Via Rundll32.EXEmedium
SMB over QUIC Via Net.EXEmedium
Startup/Logon Script Added to Group Policy Objectmedium
Suspicious FromBase64String Usage On Gzip Archive - Ps Scriptmedium
System Information Discovery Using Ioregmedium
UAC Bypass Using WOW64 Logger DLL Hijackhigh
Uncommon GrantedAccess Flags On LSASSmedium
Uninstall Crowdstrike Falcon Sensorhigh
WMI registrationhigh
Wusa.EXE Executed By Parent Process Located In Suspicious Locationhigh

AppX Located in Uncommon Directory Added to Deployment Pipeline

#
Status
test
Severity
medium
Author
Nasreddine Bencherchali (Nextron Systems)
Source
github.com/SigmaHQ/sigma

Detects an appx package that was added to the pipeline of the "to be processed" packages that is located in uncommon locations.

MITRE ATT&CK Coverage

TacticTechniques
StealthNo specific technique

Telemetry Coverage

Rule Body

title: AppX Located in Uncommon Directory Added to Deployment Pipeline
id: c977cb50-3dff-4a9f-b873-9290f56132f1
status: test
description: |
    Detects an appx package that was added to the pipeline of the "to be processed" packages that is located in uncommon locations.
references:
    - Internal Research
    - https://www.sentinelone.com/labs/inside-malicious-windows-apps-for-malware-deployment/
    - https://learn.microsoft.com/en-us/windows/win32/appxpkg/troubleshooting
    - https://news.sophos.com/en-us/2021/11/11/bazarloader-call-me-back-attack-abuses-windows-10-apps-mechanism/
author: Nasreddine Bencherchali (Nextron Systems)
date: 2023-01-11
modified: 2025-12-03
tags:
    - attack.stealth
logsource:
    product: windows
    service: appxdeployment-server
detection:
    selection:
        EventID: 854
    filter_main_generic:
        Path|contains:
            # Paths can be written using forward slash if the "file://" protocol is used
            - ':/Program%20Files' # Also covers 'file:///C:/Program%20Files%20(x86)/'
            - ':/Windows/System32/'
            - ':\Program Files (x86)\'
            - ':\Program Files\'
            - ':\Windows\ImmersiveControlPanel\'
            - ':\Windows\PrintDialog\'
            - ':\Windows\SystemApps\'
            - 'AppData/Local/Temp/WinGet/Microsoft.Winget.Source'
            - 'x-windowsupdate://'
    filter_main_specific:
        Path|contains:
            - 'https://installer.teams.static.microsoft/'
            - 'https://res.cdn.office.net' # Example https://res.cdn.office.net/nativehost/5mttl/installer/v2/1.2025.617.100/Microsoft.OutlookForWindows_x64.msix
            - 'https://statics.teams.cdn.live.net/'
            - 'https://statics.teams.cdn.office.net/'
            - 'microsoft.com' # Example: https://go.microsoft.com/fwlink/?linkid=2160968
    filter_optional_onedrive:
        Path|contains: 'AppData\Local\Microsoft\OneDrive\'
    filter_optional_winget:
        Path|contains:
            - 'AppData/Local/Temp/WinGet/Microsoft.Winget.Source'
            - 'AppData\Local\Temp\WinGet\Microsoft.Winget.Source'
    filter_optional_x_windowsupdate:
        Path|contains: 'x-windowsupdate://'
    condition: selection and not 1 of filter_main_* and not 1 of filter_optional_*
falsepositives:
    - Unknown
level: medium
regression_tests_path: regression_data/rules/windows/builtin/appxdeployment_server/win_appxdeployment_server_uncommon_package_locations/info.yml

Stages and Predicates

Stage 0: condition

selection and not 1 of filter_main_* and not 1 of filter_optional_*

Stage 1: selection

selection:
    EventID: 854

Stage 2: not filter_main_*

filter_main_generic:
    Path|contains:
        - ':/Program%20Files'
        - ':/Windows/System32/'
        - ':\Program Files (x86)\'
        - ':\Program Files\'
        - ':\Windows\ImmersiveControlPanel\'
        - ':\Windows\PrintDialog\'
        - ':\Windows\SystemApps\'
        - 'AppData/Local/Temp/WinGet/Microsoft.Winget.Source'
        - 'x-windowsupdate://'
filter_main_specific:
    Path|contains:
        - 'https://installer.teams.static.microsoft/'
        - 'https://res.cdn.office.net'
        - 'https://statics.teams.cdn.live.net/'
        - 'https://statics.teams.cdn.office.net/'
        - 'microsoft.com'

Stage 3: not filter_optional_*

filter_optional_onedrive:
    Path|contains: 'AppData\Local\Microsoft\OneDrive\'
filter_optional_winget:
    Path|contains:
        - 'AppData/Local/Temp/WinGet/Microsoft.Winget.Source'
        - 'AppData\Local\Temp\WinGet\Microsoft.Winget.Source'
filter_optional_x_windowsupdate:
    Path|contains: 'x-windowsupdate://'

Exclusions

The rule actively suppresses these predicates.

FieldKindExcluded valuesSearch
Pathmatch:/Program%20Filesexcludes:Path field:"Path" value:":/Program%20Files"
Pathmatch:/Windows/System32/excludes:Path field:"Path" value:":/Windows/System32/"
Pathmatch:\Program Files (x86)\excludes:Path field:"Path" value:":\Program Files (x86)\"
Pathmatch:\Program Files\excludes:Path field:"Path" value:":\Program Files\"
Pathmatch:\Windows\ImmersiveControlPanel\excludes:Path field:"Path" value:":\Windows\ImmersiveControlPanel\"
Pathmatch:\Windows\PrintDialog\excludes:Path field:"Path" value:":\Windows\PrintDialog\"
Pathmatch:\Windows\SystemApps\excludes:Path field:"Path" value:":\Windows\SystemApps\"
PathmatchAppData/Local/Temp/WinGet/Microsoft.Winget.Sourceexcludes:Path field:"Path" value:"AppData/Local/Temp/WinGet/Microsoft.Winget.Source"
Pathmatchhttps://installer.teams.static.microsoft/excludes:Path field:"Path" value:"https://installer.teams.static.microsoft/"
Pathmatchhttps://res.cdn.office.netexcludes:Path field:"Path" value:"https://res.cdn.office.net"
Pathmatchhttps://statics.teams.cdn.live.net/excludes:Path field:"Path" value:"https://statics.teams.cdn.live.net/"
Pathmatchhttps://statics.teams.cdn.office.net/excludes:Path field:"Path" value:"https://statics.teams.cdn.office.net/"
Pathmatchmicrosoft.comexcludes:Path field:"Path" value:"microsoft.com"
Pathmatchx-windowsupdate://excludes:Path field:"Path" value:"x-windowsupdate://"
PathmatchAppData\Local\Microsoft\OneDrive\excludes:Path field:"Path" value:"AppData\Local\Microsoft\OneDrive\"
PathmatchAppData\Local\Temp\WinGet\Microsoft.Winget.Sourceexcludes:Path field:"Path" value:"AppData\Local\Temp\WinGet\Microsoft.Winget.Source"

Arbitrary Binary Execution Using GUP Utility

#
Status
test
Severity
medium
Author
Nasreddine Bencherchali (Nextron Systems)
Source
github.com/SigmaHQ/sigma

Detects execution of the Notepad++ updater (gup) to launch other commands or executables

Known False Positives

  • Other parent binaries using GUP not currently identified

MITRE ATT&CK Coverage

TacticTechniques
ExecutionNo specific technique

Telemetry Coverage

Rule Body

title: Arbitrary Binary Execution Using GUP Utility
id: d65aee4d-2292-4cea-b832-83accd6cfa43
status: test
description: Detects execution of the Notepad++ updater (gup) to launch other commands or executables
references:
    - https://twitter.com/nas_bench/status/1535322445439180803
author: Nasreddine Bencherchali (Nextron Systems)
date: 2022-06-10
modified: 2023-03-02
tags:
    - attack.execution
logsource:
    category: process_creation
    product: windows
detection:
    selection:
        ParentImage|endswith: '\gup.exe'
        Image|endswith: '\explorer.exe'
    filter:
        Image|endswith: '\explorer.exe'
        CommandLine|contains: '\Notepad++\notepad++.exe'
    filter_parent:
        ParentImage|contains: '\Notepad++\updater\'
    filter_null:
        CommandLine: null
    condition: selection and not 1 of filter*
falsepositives:
    - Other parent binaries using GUP not currently identified
level: medium

Stages and Predicates

Stage 0: condition

selection and not 1 of filter*

Stage 1: selection

selection:
    ParentImage|endswith: '\gup.exe'
    Image|endswith: '\explorer.exe'

Stage 2: not filter*

filter:
    Image|endswith: '\explorer.exe'
    CommandLine|contains: '\Notepad++\notepad++.exe'
filter_parent:
    ParentImage|contains: '\Notepad++\updater\'
filter_null:
    CommandLine: null

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
Imageends_with
  • \explorer.exe corpus 13 (sigma 13)
field:"Image" kind:ends_with value:"\explorer.exe"
ParentImageends_with
  • \gup.exe corpus 2 (sigma 2)
field:"ParentImage" kind:ends_with value:"\gup.exe"

Exclusions

The rule actively suppresses these predicates.

FieldKindExcluded valuesSearch
CommandLinematch\Notepad++\notepad++.exeexcludes:CommandLine field:"CommandLine" value:"\Notepad++\notepad++.exe"
Imageends_with\explorer.exeexcludes:Image field:"Image" value:"\explorer.exe"
CommandLineis_null(no value, null check)excludes:CommandLine
ParentImagematch\Notepad++\updater\excludes:ParentImage field:"ParentImage" value:"\Notepad++\updater\"

Arbitrary File Download Via ConfigSecurityPolicy.EXE

#
Status
test
Severity
medium
Author
frack113
Source
github.com/SigmaHQ/sigma

Detects the execution of "ConfigSecurityPolicy.EXE", a binary part of Windows Defender used to manage settings in Windows Defender. Users can configure different pilot collections for each of the co-management workloads. It can be abused by attackers in order to upload or download files.

MITRE ATT&CK Coverage

TacticTechniques
Exfiltration

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 1: Process creation

Rule Body

title: Arbitrary File Download Via ConfigSecurityPolicy.EXE
id: 1f0f6176-6482-4027-b151-00071af39d7e
status: test
description: |
    Detects the execution of "ConfigSecurityPolicy.EXE", a binary part of Windows Defender used to manage settings in Windows Defender.
    Users can configure different pilot collections for each of the co-management workloads.
    It can be abused by attackers in order to upload or download files.
references:
    - https://lolbas-project.github.io/lolbas/Binaries/ConfigSecurityPolicy/
author: frack113
date: 2021-11-26
modified: 2022-05-16
tags:
    - attack.exfiltration
    - attack.t1567
logsource:
    category: process_creation
    product: windows
detection:
    selection_img:
        - CommandLine|contains: ConfigSecurityPolicy.exe
        - Image|endswith: '\ConfigSecurityPolicy.exe'
        - OriginalFileName: 'ConfigSecurityPolicy.exe'
    selection_url:
        CommandLine|contains:
            - 'ftp://'
            - 'http://'
            - 'https://'
    condition: all of selection_*
falsepositives:
    - Unknown
level: medium

Stages and Predicates

Stage 0: condition

all of selection_*

Stage 1: selection_img

selection_img:
    - CommandLine|contains: ConfigSecurityPolicy.exe
    - Image|endswith: '\ConfigSecurityPolicy.exe'
    - OriginalFileName: 'ConfigSecurityPolicy.exe'

Stage 2: selection_url

selection_url:
    CommandLine|contains:
        - 'ftp://'
        - 'http://'
        - 'https://'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • ConfigSecurityPolicy.exe
  • ftp:// corpus 12 (sigma 11, elastic 1)
  • http:// corpus 20 (sigma 18, elastic 1, splunk 1)
  • https:// corpus 20 (sigma 18, elastic 1, splunk 1)
field:"CommandLine" kind:match
Imageends_with
  • \ConfigSecurityPolicy.exe
field:"Image" kind:ends_with value:"\ConfigSecurityPolicy.exe"
OriginalFileNameeq
  • ConfigSecurityPolicy.exe
field:"OriginalFileName" kind:eq value:"ConfigSecurityPolicy.exe"

Azure Unusual Authentication Interruption

#
Status
test
Severity
medium
Author
Austin Songer @austinsonger
Source
github.com/SigmaHQ/sigma

Detects when there is a interruption in the authentication process.

MITRE ATT&CK Coverage

TacticTechniques
Initial Access
Persistence
Privilege Escalation
Stealth

Telemetry Coverage

Rule Body

title: Azure Unusual Authentication Interruption
id: 8366030e-7216-476b-9927-271d79f13cf3
status: test
description: Detects when there is a interruption in the authentication process.
references:
    - https://learn.microsoft.com/en-us/entra/architecture/security-operations-privileged-accounts
author: Austin Songer @austinsonger
date: 2021-11-26
modified: 2022-12-18
tags:
    - attack.privilege-escalation
    - attack.persistence
    - attack.initial-access
    - attack.stealth
    - attack.t1078
logsource:
    product: azure
    service: signinlogs
detection:
    selection_50097:
        ResultType: 50097
        ResultDescription: 'Device authentication is required'
    selection_50155:
        ResultType: 50155
        ResultDescription: 'DeviceAuthenticationFailed'
    selection_50158:
        ResultType: 50158
        ResultDescription: 'ExternalSecurityChallenge - External security challenge was not satisfied'
    condition: 1 of selection_*
falsepositives:
    - Unknown
level: medium

Stages and Predicates

Stage 0: condition

1 of selection_*

Stage 1: selection_50097

selection_50097:
    ResultType: 50097
    ResultDescription: 'Device authentication is required'

Stage 2: selection_50155

selection_50155:
    ResultType: 50155
    ResultDescription: 'DeviceAuthenticationFailed'

Stage 3: selection_50158

selection_50158:
    ResultType: 50158
    ResultDescription: 'ExternalSecurityChallenge - External security challenge was not satisfied'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
ResultDescriptioneq
  • Device authentication is required
  • DeviceAuthenticationFailed
  • ExternalSecurityChallenge - External security challenge was not satisfied
field:"azure_ad::result_reason" kind:eq
ResultTypeeq
  • 50097
  • 50155
  • 50158
field:"ResultType" kind:eq

Cscript/Wscript Uncommon Script Extension Execution

#
Status
test
Severity
high
Author
Nasreddine Bencherchali (Nextron Systems)
Source
github.com/SigmaHQ/sigma

Detects Wscript/Cscript executing a file with an uncommon (i.e. non-script) extension

MITRE ATT&CK Coverage

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 1: Process creation

Rule Body

title: Cscript/Wscript Uncommon Script Extension Execution
id: 99b7460d-c9f1-40d7-a316-1f36f61d52ee
status: test
description: Detects Wscript/Cscript executing a file with an uncommon (i.e. non-script) extension
references:
    - Internal Research
author: Nasreddine Bencherchali (Nextron Systems)
date: 2023-05-15
modified: 2023-06-19
tags:
    - attack.execution
    - attack.t1059.005
    - attack.t1059.007
logsource:
    category: process_creation
    product: windows
detection:
    selection_img:
        - OriginalFileName:
              - 'wscript.exe'
              - 'cscript.exe'
        - Image|endswith:
              - '\wscript.exe'
              - '\cscript.exe'
    selection_extension:
        CommandLine|contains:
            # Note: add additional potential suspicious extension
            # We could specify the "//E:" flag to avoid typos by admin. But since that's prone to blind spots via the creation of assoc it's better not to include it
            - '.csv'
            - '.dat'
            - '.doc'
            - '.gif'
            - '.jpeg'
            - '.jpg'
            - '.png'
            - '.ppt'
            - '.txt'
            - '.xls'
            - '.xml'
    condition: all of selection_*
falsepositives:
    - Unknown
level: high
regression_tests_path: regression_data/rules/windows/process_creation/proc_creation_win_wscript_cscript_uncommon_extension_exec/info.yml

Stages and Predicates

Stage 0: condition

all of selection_*

Stage 1: selection_img

selection_img:
    - OriginalFileName:
          - 'wscript.exe'
          - 'cscript.exe'
    - Image|endswith:
          - '\wscript.exe'
          - '\cscript.exe'

Stage 2: selection_extension

selection_extension:
    CommandLine|contains:
        - '.csv'
        - '.dat'
        - '.doc'
        - '.gif'
        - '.jpeg'
        - '.jpg'
        - '.png'
        - '.ppt'
        - '.txt'
        - '.xls'
        - '.xml'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • .csv corpus 2 (sigma 2)
  • .dat corpus 4 (sigma 3, elastic 1)
  • .doc corpus 4 (sigma 4)
  • .gif corpus 9 (sigma 8, elastic 1)
  • .jpeg corpus 7 (sigma 6, elastic 1)
  • .jpg corpus 8 (sigma 7, elastic 1)
  • .png corpus 8 (sigma 7, elastic 1)
  • .ppt corpus 4 (sigma 4)
  • .txt corpus 9 (sigma 9)
  • .xls corpus 4 (sigma 4)
  • .xml corpus 6 (sigma 4, splunk 2)
field:"CommandLine" kind:match
Imageends_with
  • \cscript.exe corpus 72 (sigma 72)
  • \wscript.exe corpus 74 (sigma 74)
field:"Image" kind:ends_with
OriginalFileNameeq
  • cscript.exe corpus 32 (sigma 17, elastic 15)
  • wscript.exe corpus 37 (elastic 20, sigma 17)
field:"OriginalFileName" kind:eq

DNS Server Discovery Via LDAP Query

#
Status
test
Severity
low
Author
frack113
Source
github.com/SigmaHQ/sigma

Detects DNS server discovery via LDAP query requests from uncommon applications

Known False Positives

  • Likely

MITRE ATT&CK Coverage

TacticTechniques
Discovery

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 22: DNSEvent (DNS query)

Rule Body

title: DNS Server Discovery Via LDAP Query
id: a21bcd7e-38ec-49ad-b69a-9ea17e69509e
status: test
description: Detects DNS server discovery via LDAP query requests from uncommon applications
references:
    - https://github.com/redcanaryco/atomic-red-team/blob/980f3f83fd81f37c1ca9c02dccfd1c3d9f9d0841/atomics/T1016/T1016.md#atomic-test-9---dns-server-discovery-using-nslookup
    - https://learn.microsoft.com/en-us/openspecs/windows_protocols/ms-adts/7fcdce70-5205-44d6-9c3a-260e616a2f04
author: frack113
date: 2022-08-20
modified: 2023-09-18
tags:
    - attack.discovery
    - attack.t1482
logsource:
    product: windows
    category: dns_query
detection:
    selection:
        QueryName|startswith: '_ldap.'
    filter_main_generic:
        Image|contains:
            - ':\Program Files\'
            - ':\Program Files (x86)\'
            - ':\Windows\'
    filter_main_defender:
        Image|contains: ':\ProgramData\Microsoft\Windows Defender\Platform\'
        Image|endswith: '\MsMpEng.exe'
    filter_main_unknown:
        Image: '<unknown process>'
    filter_optional_azure:
        Image|startswith: 'C:\WindowsAzure\GuestAgent'
    filter_main_null:
        Image: null
    filter_optional_browsers:
        # Note: This list is for browsers installed in the user context. To avoid basic evasions based on image name. Best to baseline this list with the browsers you use internally and add their full paths.
        Image|endswith:
            - '\chrome.exe'
            - '\firefox.exe'
            - '\opera.exe'
    condition: selection and not 1 of filter_main_* and not 1 of filter_optional_*
falsepositives:
    - Likely
# Note: Incrase the level once a baseline is established
level: low

Stages and Predicates

Stage 0: condition

selection and not 1 of filter_main_* and not 1 of filter_optional_*

Stage 1: selection

selection:
    QueryName|startswith: '_ldap.'

Stage 2: not filter_main_*

filter_main_generic:
    Image|contains:
        - ':\Program Files\'
        - ':\Program Files (x86)\'
        - ':\Windows\'
filter_main_defender:
    Image|contains: ':\ProgramData\Microsoft\Windows Defender\Platform\'
    Image|endswith: '\MsMpEng.exe'
filter_main_unknown:
    Image: '<unknown process>'
filter_main_null:
    Image: null

Stage 3: not filter_optional_*

filter_optional_azure:
    Image|startswith: 'C:\WindowsAzure\GuestAgent'
filter_optional_browsers:
    Image|endswith:
        - '\chrome.exe'
        - '\firefox.exe'
        - '\opera.exe'

Indicators

These rows show field, operator, and value matches.

Exclusions

The rule actively suppresses these predicates.

FieldKindExcluded valuesSearch
Imageends_with\MsMpEng.exeexcludes:Image field:"Image" value:"\MsMpEng.exe"
Imagematch:\ProgramData\Microsoft\Windows Defender\Platform\excludes:Image field:"Image" value:":\ProgramData\Microsoft\Windows Defender\Platform\"
Imageeq<unknown process>excludes:Image field:"Image" value:"<unknown process>"
Imageis_null(no value, null check)excludes:Image
Imagematch:\Program Files (x86)\excludes:Image field:"Image" value:":\Program Files (x86)\"
Imagematch:\Program Files\excludes:Image field:"Image" value:":\Program Files\"
Imagematch:\Windows\excludes:Image field:"Image" value:":\Windows\"
Imageends_with\chrome.exeexcludes:Image field:"Image" value:"\chrome.exe"
Imageends_with\firefox.exeexcludes:Image field:"Image" value:"\firefox.exe"
Imageends_with\opera.exeexcludes:Image field:"Image" value:"\opera.exe"
Imagestarts_withC:\WindowsAzure\GuestAgentexcludes:Image field:"Image" value:"C:\WindowsAzure\GuestAgent"

EventLog Query Requests By Builtin Utilities

#
Status
test
Severity
medium
Author
Ali Alwashali, Nasreddine Bencherchali (Nextron Systems)
Source
github.com/SigmaHQ/sigma

Detect attempts to query the contents of the event log using command line utilities. Attackers use this technique in order to look for sensitive information in the logs such as passwords, usernames, IPs, etc.

Known False Positives

  • Legitimate log access by administrators or troubleshooting tools

MITRE ATT&CK Coverage

TacticTechniques
Credential Access

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 1: Process creation

Rule Body

title: EventLog Query Requests By Builtin Utilities
id: 9cd55b6c-430a-4fa9-96f4-7cadf5229e9f
related:
    - id: beaa66d6-aa1b-4e3c-80f5-e0145369bfaf
      type: derived
status: test
description: |
    Detect attempts to query the contents of the event log using command line utilities. Attackers use this technique in order to look for sensitive information in the logs such as passwords, usernames, IPs, etc.
references:
    - https://learn.microsoft.com/en-us/powershell/module/microsoft.powershell.diagnostics/get-winevent?view=powershell-7.3
    - https://learn.microsoft.com/en-us/powershell/module/microsoft.powershell.management/get-eventlog?view=powershell-5.1
    - http://www.solomonson.com/posts/2010-07-09-reading-eventviewer-command-line/
    - https://learn.microsoft.com/en-us/windows-server/administration/windows-commands/wevtutil
author: Ali Alwashali, Nasreddine Bencherchali (Nextron Systems)
date: 2023-11-20
modified: 2024-01-24
tags:
    - attack.t1552
    - attack.credential-access
    - detection.threat-hunting
logsource:
    product: windows
    category: process_creation
detection:
    selection_wmi:
        CommandLine|contains|all:
            - 'Select'
            - 'Win32_NTLogEvent'
    selection_wevtutil_img:
        - Image|endswith: '\wevtutil.exe'
        - OriginalFileName: 'wevtutil.exe'
    selection_wevtutil_cli:
        CommandLine|contains:
            - ' qe '
            - ' query-events '
    selection_wmic_img:
        - Image|endswith: '\wmic.exe'
        - OriginalFileName: 'wmic.exe'
    selection_wmic_cli:
        CommandLine|contains: ' ntevent'
    selection_cmdlet:
        CommandLine|contains:
            - 'Get-WinEvent '
            - 'get-eventlog '
    condition: selection_wmi or all of selection_wevtutil_* or all of selection_wmic_* or selection_cmdlet
falsepositives:
    - Legitimate log access by administrators or troubleshooting tools
level: medium
regression_tests_path: regression_data/rules-threat-hunting/windows/process_creation/proc_creation_win_susp_event_log_query/info.yml

Stages and Predicates

Stage 0: condition

selection_wmi or all of selection_wevtutil_* or all of selection_wmic_* or selection_cmdlet

Stage 1: selection_wmi

selection_wmi:
    CommandLine|contains|all:
        - 'Select'
        - 'Win32_NTLogEvent'

Stage 2: selection_wevtutil_img

selection_wevtutil_img:
    - Image|endswith: '\wevtutil.exe'
    - OriginalFileName: 'wevtutil.exe'

Stage 3: selection_wevtutil_cli

selection_wevtutil_cli:
    CommandLine|contains:
        - ' qe '
        - ' query-events '

Stage 4: selection_wmic_img

selection_wmic_img:
    - Image|endswith: '\wmic.exe'
    - OriginalFileName: 'wmic.exe'

Stage 5: selection_wmic_cli

selection_wmic_cli:
    CommandLine|contains: ' ntevent'

Stage 6: selection_cmdlet

selection_cmdlet:
    CommandLine|contains:
        - 'Get-WinEvent '
        - 'get-eventlog '

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • ntevent corpus 2 (sigma 2)
  • qe corpus 2 (sigma 2)
  • query-events corpus 2 (sigma 2)
  • Get-WinEvent corpus 2 (sigma 2)
  • Select corpus 4 (sigma 4)
  • Win32_NTLogEvent corpus 3 (sigma 2, splunk 1)
  • get-eventlog corpus 2 (sigma 2)
field:"CommandLine" kind:match
Imageends_with
  • \wevtutil.exe corpus 9 (sigma 9)
  • \wmic.exe corpus 62 (sigma 62)
field:"Image" kind:ends_with
OriginalFileNameeq
  • wevtutil.exe corpus 7 (sigma 5, splunk 2)
  • wmic.exe corpus 74 (sigma 38, elastic 18, splunk 18)
field:"OriginalFileName" kind:eq

File Decryption Using Gpg4win

#
Status
test
Severity
medium
Author
Nasreddine Bencherchali (Nextron Systems)
Source
github.com/SigmaHQ/sigma

Detects usage of Gpg4win to decrypt files

MITRE ATT&CK Coverage

TacticTechniques
ExecutionNo specific technique

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 1: Process creation

Rule Body

title: File Decryption Using Gpg4win
id: 037dcd71-33a8-4392-bb01-293c94663e5a
status: test
description: Detects usage of Gpg4win to decrypt files
references:
    - https://blogs.vmware.com/security/2022/11/batloader-the-evasive-downloader-malware.html
    - https://www.gpg4win.de/documentation.html
    - https://news.sophos.com/en-us/2022/01/19/zloader-installs-remote-access-backdoors-and-delivers-cobalt-strike/
author: Nasreddine Bencherchali (Nextron Systems)
date: 2023-08-09
tags:
    - attack.execution
logsource:
    category: process_creation
    product: windows
detection:
    selection_metadata:
        - Image|endswith:
              - '\gpg.exe'
              - '\gpg2.exe'
        - Description: 'GnuPG’s OpenPGP tool'
    selection_cli:
        CommandLine|contains|all:
            - ' -d '
            - 'passphrase'
    condition: all of selection_*
falsepositives:
    - Unknown
level: medium

Stages and Predicates

Stage 0: condition

all of selection_*

Stage 1: selection_metadata

selection_metadata:
    - Image|endswith:
          - '\gpg.exe'
          - '\gpg2.exe'
    - Description: 'GnuPG’s OpenPGP tool'

Stage 2: selection_cli

selection_cli:
    CommandLine|contains|all:
        - ' -d '
        - 'passphrase'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • -d corpus 8 (sigma 7, splunk 1)
  • passphrase corpus 2 (sigma 2)
field:"CommandLine" kind:match
Descriptioneq
  • GnuPG’s OpenPGP tool corpus 4 (sigma 4)
field:"Description" kind:eq value:"GnuPG’s OpenPGP tool"
Imageends_with
  • \gpg.exe corpus 4 (sigma 4)
  • \gpg2.exe corpus 4 (sigma 4)
field:"Image" kind:ends_with

Google Workspace Role Modified or Deleted

#
Status
test
Severity
medium
Author
Austin Songer
Source
github.com/SigmaHQ/sigma

Detects when an a role is modified or deleted in Google Workspace.

MITRE ATT&CK Coverage

TacticTechniques
ImpactNo specific technique

Telemetry Coverage

Rule Body

title: Google Workspace Role Modified or Deleted
id: 6aef64e3-60c6-4782-8db3-8448759c714e
status: test
description: Detects when an a role is modified or deleted in Google Workspace.
references:
    - https://cloud.google.com/logging/docs/audit/gsuite-audit-logging#3
    - https://developers.google.com/admin-sdk/reports/v1/appendix/activity/admin-delegated-admin-settings
author: Austin Songer
date: 2021-08-24
modified: 2023-10-11
tags:
    - attack.impact
logsource:
    product: gcp
    service: google_workspace.admin
detection:
    selection:
        eventService: admin.googleapis.com
        eventName:
            - DELETE_ROLE
            - RENAME_ROLE
            - UPDATE_ROLE
    condition: selection
falsepositives:
    - Unknown

level: medium

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    eventService: admin.googleapis.com
    eventName:
        - DELETE_ROLE
        - RENAME_ROLE
        - UPDATE_ROLE

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
eventNameeq
  • DELETE_ROLE
  • RENAME_ROLE
  • UPDATE_ROLE
field:"aws::eventName" kind:eq
eventServiceeq
  • admin.googleapis.com corpus 7 (sigma 7)
field:"gcp::service_name" kind:eq value:"admin.googleapis.com"

Hypervisor Enforced Paging Translation Disabled

#
Status
test
Severity
high
Author
Nasreddine Bencherchali (Nextron Systems)
Source
github.com/SigmaHQ/sigma

Detects changes to the "DisableHypervisorEnforcedPagingTranslation" registry value. Where the it is set to "1" in order to disable the Hypervisor Enforced Paging Translation feature.

MITRE ATT&CK Coverage

TacticTechniques
Defense Impairment

Telemetry Coverage

Rule Body

title: Hypervisor Enforced Paging Translation Disabled
id: 7f2954d2-99c2-4d42-a065-ca36740f187b
status: test
description: |
    Detects changes to the "DisableHypervisorEnforcedPagingTranslation" registry value. Where the it is set to "1" in order to disable the Hypervisor Enforced Paging Translation feature.
references:
    - https://twitter.com/standa_t/status/1808868985678803222
    - https://github.com/AaLl86/WindowsInternals/blob/070dc4f317726dfb6ffd2b7a7c121a33a8659b5e/Slides/Hypervisor-enforced%20Paging%20Translation%20-%20The%20end%20of%20non%20data-driven%20Kernel%20Exploits%20(Recon2024).pdf
author: Nasreddine Bencherchali (Nextron Systems)
date: 2024-07-05
tags:
    - attack.defense-impairment
    - attack.t1685
logsource:
    category: registry_set
    product: windows
detection:
    selection:
        TargetObject|endswith: '\DisableHypervisorEnforcedPagingTranslation'
        Details: 'DWORD (0x00000001)'
    condition: selection
falsepositives:
    - Unknown
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    TargetObject|endswith: '\DisableHypervisorEnforcedPagingTranslation'
    Details: 'DWORD (0x00000001)'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
Detailseq
  • DWORD (0x00000001) corpus 36 (sigma 36)
field:"Details" kind:eq value:"DWORD (0x00000001)"
TargetObjectends_with
  • \DisableHypervisorEnforcedPagingTranslation
field:"TargetObject" kind:ends_with value:"\DisableHypervisorEnforcedPagingTranslation"

Insecure Transfer Via Curl.EXE

#
Status
test
Severity
medium
Author
X__Junior (Nextron Systems)
Source
github.com/SigmaHQ/sigma

Detects execution of "curl.exe" with the "--insecure" flag.

Known False Positives

  • Access to badly maintained internal or development systems

MITRE ATT&CK Coverage

TacticTechniques
ExecutionNo specific technique

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 1: Process creation

Rule Body

title: Insecure Transfer Via Curl.EXE
id: cb9cc1d1-e84e-4bdc-b7ad-c31b1b7908ec
status: test
description: Detects execution of "curl.exe" with the "--insecure" flag.
references:
    - https://curl.se/docs/manpage.html
author: X__Junior (Nextron Systems)
date: 2023-06-30
tags:
    - attack.execution
logsource:
    product: windows
    category: process_creation
detection:
    selection_img:
        - Image|endswith: '\curl.exe'
        - OriginalFileName: 'curl.exe'
    selection_cli:
        - CommandLine|re: '\s-k\s'
        - CommandLine|contains: '--insecure'
    condition: all of selection_*
falsepositives:
    - Access to badly maintained internal or development systems
level: medium
regression_tests_path: regression_data/rules/windows/process_creation/proc_creation_win_curl_insecure_connection/info.yml

Stages and Predicates

Stage 0: condition

all of selection_*

Stage 1: selection_img

selection_img:
    - Image|endswith: '\curl.exe'
    - OriginalFileName: 'curl.exe'

Stage 2: selection_cli

selection_cli:
    - CommandLine|re: '\s-k\s'
    - CommandLine|contains: '--insecure'

Indicators

These rows show field, operator, and value matches.

Local Firewall Rules Enumeration Via NetFirewallRule Cmdlet

#
Status
test
Severity
low
Author
Christopher Peacock @SecurePeacock, SCYTHE @scythe_io
Source
github.com/SigmaHQ/sigma

Detects execution of "Get-NetFirewallRule" or "Show-NetFirewallRule" to enumerate the local firewall rules on a host.

Known False Positives

  • Administration scripts

MITRE ATT&CK Coverage

Telemetry Coverage

Rule Body

title: Local Firewall Rules Enumeration Via NetFirewallRule Cmdlet
id: ea207a23-b441-4a17-9f76-ad5be47d51d3
status: test
description: Detects execution of "Get-NetFirewallRule" or "Show-NetFirewallRule" to enumerate the local firewall rules on a host.
references:
    - https://learn.microsoft.com/en-us/powershell/module/netsecurity/get-netfirewallrule?view=windowsserver2022-ps
    - https://learn.microsoft.com/en-us/powershell/module/netsecurity/show-netfirewallrule?view=windowsserver2022-ps
author: Christopher Peacock @SecurePeacock, SCYTHE @scythe_io
date: 2023-07-13
tags:
    - detection.threat-hunting
    - attack.discovery
    - attack.t1518.001
    - attack.t1016
logsource:
    product: windows
    category: ps_module
    definition: 0ad03ef1-f21b-4a79-8ce8-e6900c54b65b
detection:
    selection_payload:
        Payload|contains:
            - 'Get-NetFirewallRule'
            - 'Show-NetFirewallRule'
    selection_contextinfo:
        ContextInfo|contains:
            - 'Get-NetFirewallRule'
            - 'Show-NetFirewallRule'
    condition: 1 of selection_*
falsepositives:
    - Administration scripts
level: low

Stages and Predicates

Stage 0: condition

1 of selection_*

Stage 1: selection_payload

selection_payload:
    Payload|contains:
        - 'Get-NetFirewallRule'
        - 'Show-NetFirewallRule'

Stage 2: selection_contextinfo

selection_contextinfo:
    ContextInfo|contains:
        - 'Get-NetFirewallRule'
        - 'Show-NetFirewallRule'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
ContextInfomatch
  • Get-NetFirewallRule
  • Show-NetFirewallRule
field:"ContextInfo" kind:match
Payloadmatch
  • Get-NetFirewallRule corpus 2 (sigma 2)
  • Show-NetFirewallRule
field:"Payload" kind:match

Microsoft Defender Blocked from Loading Unsigned DLL

#
Status
test
Severity
high
Author
Bhabesh Raj
Source
github.com/SigmaHQ/sigma

Detects Code Integrity (CI) engine blocking Microsoft Defender's processes (MpCmdRun and NisSrv) from loading unsigned DLLs which may be an attempt to sideload arbitrary DLL

MITRE ATT&CK Coverage

Telemetry Coverage

Rule Body

title: Microsoft Defender Blocked from Loading Unsigned DLL
id: 0b0ea3cc-99c8-4730-9c53-45deee2a4c86
status: test
description: Detects Code Integrity (CI) engine blocking Microsoft Defender's processes (MpCmdRun and NisSrv) from loading unsigned DLLs which may be an attempt to sideload arbitrary DLL
references:
    - https://www.sentinelone.com/blog/living-off-windows-defender-lockbit-ransomware-sideloads-cobalt-strike-through-microsoft-security-tool
author: Bhabesh Raj
date: 2022-08-02
modified: 2022-09-28
tags:
    - attack.privilege-escalation
    - attack.persistence
    - attack.execution
    - attack.stealth
    - attack.t1574.001
logsource:
    product: windows
    service: security-mitigations
detection:
    selection:
        EventID:
            - 11
            - 12 # MDE: ExploitGuardNonMicrosoftSignedBlocked
        ProcessPath|endswith:
            - '\MpCmdRun.exe'
            - '\NisSrv.exe'
    condition: selection
falsepositives:
    - Unknown
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    EventID:
        - 11
        - 12
    ProcessPath|endswith:
        - '\MpCmdRun.exe'
        - '\NisSrv.exe'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
ProcessPathends_with
  • \MpCmdRun.exe
  • \NisSrv.exe
field:"ProcessPath" kind:ends_with

Mimikatz Pass-the-hash login

#
Status
experimental
Severity
high
Author
mdecrevoisier
Source
github.com/mdecrevoisier/SIGMA-detection-rules

Detects scenarios where an attacker uses the Mimikatz Pass-the-hash feature to move laterally. Correlation with others event IDs can be done in the following way:| ID 4624 TargetLogonId + ID 4672 SubjectLogonId + ID 4688 TargetLogonId. Having those 3 elements together allows to bring in light what was exactly done.

Known False Positives

  • Runas.exe executed with /netonly parameter

MITRE ATT&CK Coverage

Telemetry Coverage

Rule Body

title: Mimikatz Pass-the-hash login
description: Detects scenarios where an attacker uses the Mimikatz Pass-the-hash feature to move laterally. Correlation with others event IDs can be done in the following way:| ID 4624 TargetLogonId + ID 4672 SubjectLogonId + ID 4688 TargetLogonId. Having those 3 elements together allows to bring in light what was exactly done.
references:
- https://github.com/mdecrevoisier/EVTX-to-MITRE-Attack/tree/master/TA0008-Lateral%20Movement/T1550-Use%20Alternate%20Authentication%20Material
- https://stealthbits.com/blog/passing-the-hash-with-mimikatz/
- https://s3cur3th1ssh1t.github.io/Named-Pipe-PTH/
- https://thedfirreport.com/2022/11/14/bumblebee-zeros-in-on-meterpreter/
- https://thedfirreport.com/2023/06/12/a-truly-graceful-wipe-out/
tags:
- attack.lateral_movement
- attack.t1550.002
author: mdecrevoisier
status: experimental
logsource:
  product: windows
  service: security
detection: # command: 'privilege::debug' + 'sekurlsa::pth /user:<user> /domain:<domain> /ntlm:<hash> /run:<command>'
  selection:
    EventID: 4624
    LogonType: 9 # New credentials
    LogonProcessName: seclogo
    AuthenticationPackageName: Negotiate
    ProcessName: 'C:\Windows\System32\svchost.exe'
    IpAddress: '::1'
  #filter: # if 'token::elevate' command is used, both Subject and Target will be related to SYSTEM account. Therefore the filter needs to be removed.
    #SubjectUserName|endswith: '$'
    #TargetUserName|endswith: '$'
  condition: selection and not filter
falsepositives:
- Runas.exe executed with /netonly parameter
level: high

Stages and Predicates

Stage 0: condition

selection and not filter

Stage 1: selection

selection:
  EventID: 4624
  LogonType: 9
  LogonProcessName: seclogo
  AuthenticationPackageName: Negotiate
  ProcessName: 'C:\Windows\System32\svchost.exe'
  IpAddress: '::1'

Indicators

These rows show field, operator, and value matches.

New network file share created

#
Status
experimental
Severity
medium
Author
mdecrevoisier
Source
github.com/mdecrevoisier/SIGMA-detection-rules

Detects scenarios when a new file share is created.

Known False Positives

  • Administrator actvity

MITRE ATT&CK Coverage

Telemetry Coverage

Rule Body

title: New network file share created
description: Detects scenarios when a new file share is created.
references:
- https://github.com/mdecrevoisier/EVTX-to-MITRE-Attack/tree/master/TA0008-Lateral%20Movement/T1021.002%20-SMB%20Windows%20Admin%20Shares
- https://docs.microsoft.com/en-us/windows/security/threat-protection/auditing/event-5142
tags:
- attack.lateral_movement
- attack.t1021.002
author: mdecrevoisier
status: experimental
logsource:
  product: windows
  service: security
detection:
  selection:
    EventID: 5142
  filter:
    SubjectUserName|endswith: '$' # Share created by the system are ignored
  condition: selection and not filter
falsepositives:
- Administrator actvity
level: medium

Stages and Predicates

Stage 0: condition

selection and not filter

Stage 1: selection

selection:
  EventID: 5142

Stage 2: not filter

filter:
  SubjectUserName|endswith: '$'

Exclusions

The rule actively suppresses these predicates.

FieldKindExcluded valuesSearch
SubjectUserNameends_with$excludes:SubjectUserName field:"SubjectUserName" value:"$"

Potential GobRAT File Discovery Via Grep

#
Status
test
Severity
high
Author
Joseliyo Sanchez, @Joseliyo_Jstnk
Source
github.com/SigmaHQ/sigma

Detects the use of grep to discover specific files created by the GobRAT malware

MITRE ATT&CK Coverage

TacticTechniques
Discovery

Telemetry Coverage

PlatformRecord / event type
LinuxEvent ID 1: Process Create

Rule Body

title: Potential GobRAT File Discovery Via Grep
id: e34cfa0c-0a50-4210-9cb3-5632d08eb041
status: test
description: Detects the use of grep to discover specific files created by the GobRAT malware
references:
    - https://blogs.jpcert.or.jp/en/2023/05/gobrat.html
    - https://www.virustotal.com/gui/file/60bcd645450e4c846238cf0e7226dc40c84c96eba99f6b2cffcd0ab4a391c8b3/detection
    - https://www.virustotal.com/gui/file/3e44c807a25a56f4068b5b8186eee5002eed6f26d665a8b791c472ad154585d1/detection
author: Joseliyo Sanchez, @Joseliyo_Jstnk
date: 2023-06-02
tags:
    - attack.discovery
    - attack.t1082
logsource:
    category: process_creation
    product: linux
detection:
    selection:
        Image|endswith: '/grep'
        CommandLine|contains:
            - 'apached'
            - 'frpc'
            - 'sshd.sh'
            - 'zone.arm'
    condition: selection
falsepositives:
    - Unknown
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    Image|endswith: '/grep'
    CommandLine|contains:
        - 'apached'
        - 'frpc'
        - 'sshd.sh'
        - 'zone.arm'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • apached
  • frpc
  • sshd.sh
  • zone.arm
field:"CommandLine" kind:match
Imageends_with
  • /grep corpus 7 (sigma 7)
field:"Image" kind:ends_with value:"/grep"

Potential Hidden Directory Creation Via NTFS INDEX_ALLOCATION Stream - CLI

#
Status
test
Severity
medium
Author
Nasreddine Bencherchali (Nextron Systems), Scoubi (@ScoubiMtl)
Source
github.com/SigmaHQ/sigma

Detects command line containing reference to the "::$index_allocation" stream, which can be used as a technique to prevent access to folders or files from tooling such as "explorer.exe" or "powershell.exe"

Known False Positives

  • Unlikely

MITRE ATT&CK Coverage

Telemetry Coverage

Rule Body

title: Potential Hidden Directory Creation Via NTFS INDEX_ALLOCATION Stream - CLI
id: 0900463c-b33b-49a8-be1d-552a3b553dae
related:
    - id: a8f866e1-bdd4-425e-a27a-37619238d9c7
      type: similar
status: test
description: |
    Detects command line containing reference to the "::$index_allocation" stream, which can be used as a technique to prevent access to folders or files from tooling such as "explorer.exe" or "powershell.exe"
references:
    - https://twitter.com/pfiatde/status/1681977680688738305
    - https://soroush.me/blog/2010/12/a-dotty-salty-directory-a-secret-place-in-ntfs-for-secret-files/
    - https://sec-consult.com/blog/detail/pentesters-windows-ntfs-tricks-collection/
    - https://github.com/redcanaryco/atomic-red-team/blob/5c3b23002d2bbede3c07e7307165fc2a235a427d/atomics/T1564.004/T1564.004.md#atomic-test-5---create-hidden-directory-via-index_allocation
    - https://learn.microsoft.com/en-us/openspecs/windows_protocols/ms-fscc/c54dec26-1551-4d3a-a0ea-4fa40f848eb3
author: Nasreddine Bencherchali (Nextron Systems), Scoubi (@ScoubiMtl)
date: 2023-10-09
tags:
    - attack.stealth
    - attack.t1564.004
logsource:
    product: windows
    category: process_creation
detection:
    selection:
        # Note: Both Sysmon and ETW are unable to log the presence of such stream in the CommandLine. But EDRs such as Crowdstrike are able to using for example CMD console history. Users are advised to test this before usage
        CommandLine|contains: '::$index_allocation'
    condition: selection
falsepositives:
    - Unlikely
level: medium
regression_tests_path: regression_data/rules/windows/process_creation/proc_creation_win_susp_hidden_dir_index_allocation/info.yml

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    CommandLine|contains: '::$index_allocation'

Indicators

These rows show field, operator, and value matches.

Potential Lateral Movement via Windows Remote Shell

#
Status
experimental
Severity
medium
Author
Liran Ravich
Source
github.com/SigmaHQ/sigma

Detects a child process spawned by 'winrshost.exe', which suggests remote command execution through Windows Remote Shell (WinRs) and may indicate potential lateral movement activity.

Known False Positives

  • Legitimate use of WinRM within the organization

MITRE ATT&CK Coverage

Telemetry Coverage

Rule Body

title: Potential Lateral Movement via Windows Remote Shell
id: 79df3f68-dccb-48e9-9171-b75cbc37c51d
status: experimental
description: |
    Detects a child process spawned by 'winrshost.exe', which suggests remote command execution through Windows Remote Shell (WinRs) and may indicate potential lateral movement activity.
references:
    - https://cardinalops.com/blog/living-off-winrm-abusing-complexity-in-remote-management/
    - https://www.ired.team/offensive-security/lateral-movement/winrs-for-lateral-movement
author: Liran Ravich
date: 2025-10-22
tags:
    - attack.lateral-movement
    - attack.t1021.006
logsource:
    category: process_creation
    product: windows
detection:
    selection:
        # Note: Example of command to simulate (winrm needs to be enabled): "c:\Windows\System32\winrs.exe" powershell
        ParentImage|endswith: '\winrshost.exe'
    filter_main_conhost:
        Image: 'C:\Windows\System32\conhost.exe'
    condition: selection and not 1 of filter_main_*
falsepositives:
    - Legitimate use of WinRM within the organization
level: medium
regression_tests_path: regression_data/rules/windows/process_creation/proc_creation_win_winrshost_command_execution/info.yml

Stages and Predicates

Stage 0: condition

selection and not 1 of filter_main_*

Stage 1: selection

selection:
    ParentImage|endswith: '\winrshost.exe'

Stage 2: not filter_main_conhost

filter_main_conhost:
    Image: 'C:\Windows\System32\conhost.exe'

Indicators

These rows show field, operator, and value matches.

Exclusions

The rule actively suppresses these predicates.

FieldKindExcluded valuesSearch
ImageeqC:\Windows\System32\conhost.exeexcludes:Image field:"Image" value:"C:\Windows\System32\conhost.exe"

Potential Persistence Via Microsoft Compatibility Appraiser

#
Status
test
Severity
medium
Author
Sreeman
Source
github.com/SigmaHQ/sigma

Detects manual execution of the "Microsoft Compatibility Appraiser" task via schtasks. In order to trigger persistence stored in the "\AppCompatFlags\TelemetryController" registry key.

MITRE ATT&CK Coverage

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 1: Process creation

Rule Body

title: Potential Persistence Via Microsoft Compatibility Appraiser
id: f548a603-c9f2-4c89-b511-b089f7e94549
related:
    - id: 73a883d0-0348-4be4-a8d8-51031c2564f8
      type: derived
status: test
description: |
    Detects manual execution of the "Microsoft Compatibility Appraiser" task via schtasks.
    In order to trigger persistence stored in the "\AppCompatFlags\TelemetryController" registry key.
references:
    - https://www.trustedsec.com/blog/abusing-windows-telemetry-for-persistence/
author: Sreeman
date: 2020-09-29
modified: 2023-02-10
tags:
    - attack.privilege-escalation
    - attack.execution
    - attack.persistence
    - attack.t1053.005
logsource:
    product: windows
    category: process_creation
detection:
    selection_img:
        - Image|endswith: '\schtasks.exe'
        - OriginalFileName: 'schtasks.exe'
    selection_cli:
        CommandLine|contains|all:
            - 'run '
            - '\Application Experience\Microsoft Compatibility Appraiser'
    condition: all of selection_*
falsepositives:
    - Unknown
level: medium

Stages and Predicates

Stage 0: condition

all of selection_*

Stage 1: selection_img

selection_img:
    - Image|endswith: '\schtasks.exe'
    - OriginalFileName: 'schtasks.exe'

Stage 2: selection_cli

selection_cli:
    CommandLine|contains|all:
        - 'run '
        - '\Application Experience\Microsoft Compatibility Appraiser'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • \Application Experience\Microsoft Compatibility Appraiser
  • run
field:"CommandLine" kind:match
Imageends_with
  • \schtasks.exe corpus 55 (sigma 55)
field:"Image" kind:ends_with value:"\schtasks.exe"
OriginalFileNameeq
  • schtasks.exe corpus 29 (sigma 18, elastic 7, splunk 4)
field:"OriginalFileName" kind:eq value:"schtasks.exe"

Potential SAP NetWeaver Webshell Creation - Linux

#
Status
experimental
Severity
medium
Author
Elastic (idea), Swachchhanda Shrawan Poudel (Nextron Systems)
Source
github.com/SigmaHQ/sigma

Detects the creation of suspicious files (jsp, java, class) in SAP NetWeaver directories, which may indicate exploitation attempts of vulnerabilities such as CVE-2025-31324.

Known False Positives

  • Legitimate creation of jsc or java files in these locations

MITRE ATT&CK Coverage

Telemetry Coverage

PlatformRecord / event type
LinuxEvent ID 11: File created

Rule Body

title: Potential SAP NetWeaver Webshell Creation - Linux
id: 5b91409c-cb18-4ab6-ac75-c5759f998409
status: experimental
description: |
    Detects the creation of suspicious files (jsp, java, class) in SAP NetWeaver directories,
    which may indicate exploitation attempts of vulnerabilities such as CVE-2025-31324.
references:
    - https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2025-31324
    - https://reliaquest.com/blog/threat-spotlight-reliaquest-uncovers-vulnerability-behind-sap-netweaver-compromise/
    - https://onapsis.com/blog/active-exploitation-of-sap-vulnerability-cve-2025-31324/
author: Elastic (idea), Swachchhanda Shrawan Poudel (Nextron Systems)
date: 2025-04-28
tags:
    - attack.execution
    - attack.initial-access
    - attack.t1190
    - attack.persistence
    - attack.t1059.003
    - cve.2025-31324
    - detection.emerging-threats
logsource:
    product: linux
    category: file_event
detection:
    selection_path:
        TargetFilename|contains:
            - '/j2ee/cluster/apps/sap.com/irj/servlet_jsp/irj/work/'
            - '/j2ee/cluster/apps/sap.com/irj/servlet_jsp/irj/root/'
    selection_ext:
        TargetFilename|endswith:
            - '.jsp'
            - '.java'
            - '.class'
    condition: all of selection_*
falsepositives:
    - Legitimate creation of jsc or java files in these locations
level: medium

Stages and Predicates

Stage 0: condition

all of selection_*

Stage 1: selection_path

selection_path:
    TargetFilename|contains:
        - '/j2ee/cluster/apps/sap.com/irj/servlet_jsp/irj/work/'
        - '/j2ee/cluster/apps/sap.com/irj/servlet_jsp/irj/root/'

Stage 2: selection_ext

selection_ext:
    TargetFilename|endswith:
        - '.jsp'
        - '.java'
        - '.class'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
TargetFilenameends_with
  • .class corpus 2 (sigma 2)
  • .java corpus 2 (sigma 2)
  • .jsp corpus 5 (sigma 4, splunk 1)
field:"TargetFilename" kind:ends_with
TargetFilenamematch
  • /j2ee/cluster/apps/sap.com/irj/servlet_jsp/irj/root/
  • /j2ee/cluster/apps/sap.com/irj/servlet_jsp/irj/work/
field:"TargetFilename" kind:match

Potential SpEL Injection In Spring Framework

#
Status
test
Severity
high
Author
Moti Harmats
Source
github.com/SigmaHQ/sigma

Detects potential SpEL Injection exploitation, which may lead to RCE.

Known False Positives

  • Application bugs

MITRE ATT&CK Coverage

TacticTechniques
Initial Access

Rule Body

title: Potential SpEL Injection In Spring Framework
id: e9edd087-89d8-48c9-b0b4-5b9bb10896b8
status: test
description: Detects potential SpEL Injection exploitation, which may lead to RCE.
references:
    - https://owasp.org/www-community/vulnerabilities/Expression_Language_Injection
    - https://www.wix.engineering/post/threat-and-vulnerability-hunting-with-application-server-error-logs
author: Moti Harmats
date: 2023-02-11
tags:
    - attack.initial-access
    - attack.t1190
logsource:
    category: application
    product: spring
    definition: 'Requirements: application error logs must be collected (with LOG_LEVEL=ERROR and above)'
detection:
    keywords:
        - 'org.springframework.expression.ExpressionException'
    condition: keywords
falsepositives:
    - Application bugs
level: high

Stages and Predicates

Stage 0: condition

keywords

Stage 1: keywords

keywords:
    - 'org.springframework.expression.ExpressionException'

Potential Suspicious Winget Package Installation

#
Status
test
Severity
high
Author
Nasreddine Bencherchali (Nextron Systems)
Source
github.com/SigmaHQ/sigma

Detects potential suspicious winget package installation from a suspicious source.

MITRE ATT&CK Coverage

TacticTechniques
PersistenceNo specific technique
StealthNo specific technique

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 15: FileCreateStreamHash

Rule Body

title: Potential Suspicious Winget Package Installation
id: a3f5c081-e75b-43a0-9f5b-51f26fe5dba2
status: test
description: Detects potential suspicious winget package installation from a suspicious source.
references:
    - https://github.com/nasbench/Misc-Research/tree/b9596e8109dcdb16ec353f316678927e507a5b8d/LOLBINs/Winget
author: Nasreddine Bencherchali (Nextron Systems)
date: 2023-04-18
tags:
    - attack.persistence
    - attack.stealth
logsource:
    product: windows
    category: create_stream_hash
detection:
    selection:
        Contents|startswith: '[ZoneTransfer]  ZoneId=3'
        Contents|contains:
            # Note: Add any untrusted sources that are custom to your env
            - '://1'
            - '://2'
            - '://3'
            - '://4'
            - '://5'
            - '://6'
            - '://7'
            - '://8'
            - '://9'
        TargetFilename|endswith: ':Zone.Identifier'
        TargetFilename|contains: '\AppData\Local\Temp\WinGet\'
    condition: selection
falsepositives:
    - Unknown
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    Contents|startswith: '[ZoneTransfer]  ZoneId=3'
    Contents|contains:
        - '://1'
        - '://2'
        - '://3'
        - '://4'
        - '://5'
        - '://6'
        - '://7'
        - '://8'
        - '://9'
    TargetFilename|endswith: ':Zone.Identifier'
    TargetFilename|contains: '\AppData\Local\Temp\WinGet\'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
Contentsmatch
  • ://1
  • ://2
  • ://3
  • ://4
  • ://5
  • ://6
  • ://7
  • ://8
  • ://9
field:"Contents" kind:match
Contentsstarts_with
  • [ZoneTransfer] ZoneId=3 corpus 2 (sigma 2)
field:"Contents" kind:starts_with value:"[ZoneTransfer] ZoneId=3"
TargetFilenameends_with
  • :Zone.Identifier corpus 6 (sigma 4, splunk 2)
field:"TargetFilename" kind:ends_with value:":Zone.Identifier"
TargetFilenamematch
  • \AppData\Local\Temp\WinGet\
field:"TargetFilename" kind:match value:"\AppData\Local\Temp\WinGet\"

Potentially Suspicious Long Filename Pattern - Linux

#
Status
experimental
Severity
low
Author
@kostastsale
Source
github.com/SigmaHQ/sigma

Detects the creation of files with unusually long filenames (100 or more characters), which may indicate obfuscation techniques used by malware such as VShell. This is a hunting rule to identify potential threats that use long filenames to evade detection. Keep in mind that on a legitimate system, such long filenames can and are common. Run this detection in the context of threat hunting rather than alerting. Adjust the threshold of filename length as needed based on your environment.

Known False Positives

  • Legitimate files with long filenames.

MITRE ATT&CK Coverage

Telemetry Coverage

PlatformRecord / event type
LinuxEvent ID 11: File created

Rule Body

title: Potentially Suspicious Long Filename Pattern - Linux
id: 11629c4d-0fe6-465b-be62-b39a1c442aad
status: experimental
description: |
    Detects the creation of files with unusually long filenames (100 or more characters), which may indicate obfuscation techniques used by malware such as VShell.
    This is a hunting rule to identify potential threats that use long filenames to evade detection. Keep in mind that on a legitimate system, such long filenames can and are common. Run this detection in the context of threat hunting rather than alerting.
    Adjust the threshold of filename length as needed based on your environment.
references:
    - https://www.trellix.com/blogs/research/the-silent-fileless-threat-of-vshell/
author: '@kostastsale'
date: 2025-11-22
tags:
    - attack.execution
    - attack.stealth
    - attack.t1059.004
    - attack.t1027
    - detection.threat-hunting
logsource:
    product: linux
    category: file_event
detection:
    selection:
        TargetFilename|re: '[^/]{100,}$'
    filter_optional_known_good:
        TargetFilename|startswith:
            - '/run/systemd/units/invocation:systemd-fsck@'
            - '/sys/firmware/'
            - '/var/log/journal/'
    condition: selection and not 1 of filter_optional_*
falsepositives:
    - Legitimate files with long filenames.
level: low

Stages and Predicates

Stage 0: condition

selection and not 1 of filter_optional_*

Stage 1: selection

selection:
    TargetFilename|re: '[^/]{100,}$'

Stage 2: not filter_optional_known_good

filter_optional_known_good:
    TargetFilename|startswith:
        - '/run/systemd/units/invocation:systemd-fsck@'
        - '/sys/firmware/'
        - '/var/log/journal/'

Indicators

These rows show field, operator, and value matches.

Exclusions

The rule actively suppresses these predicates.

FieldKindExcluded valuesSearch
TargetFilenamestarts_with/run/systemd/units/invocation:systemd-fsck@excludes:TargetFilename field:"TargetFilename" value:"/run/systemd/units/invocation:systemd-fsck@"
TargetFilenamestarts_with/sys/firmware/excludes:TargetFilename field:"TargetFilename" value:"/sys/firmware/"
TargetFilenamestarts_with/var/log/journal/excludes:TargetFilename field:"TargetFilename" value:"/var/log/journal/"

RBAC Permission Enumeration Attempt

#
Status
test
Severity
low
Author
Leo Tsaousis (@laripping)
Source
github.com/SigmaHQ/sigma

Detects identities attempting to enumerate their Kubernetes RBAC permissions. In the early stages of a breach, attackers will aim to list the permissions they have within the compromised environment. In a Kubernetes cluster, this can be achieved by interacting with the API server, and querying the SelfSubjectAccessReview API via e.g. a "kubectl auth can-i --list" command. This will enumerate the Role-Based Access Controls (RBAC) rules defining the compromised user's authorization.

MITRE ATT&CK Coverage

Telemetry Coverage

Rules Detecting the Same Action

These rules filter on the same operation.

Rule Body

title: RBAC Permission Enumeration Attempt
id: 84b777bd-c946-4d17-aa2e-c39f5a454325
status: test
description: |
    Detects identities attempting to enumerate their Kubernetes RBAC permissions.
    In the early stages of a breach, attackers will aim to list the permissions they have within the compromised environment.
    In a Kubernetes cluster, this can be achieved by interacting with the API server, and querying the SelfSubjectAccessReview API via e.g. a "kubectl auth can-i --list" command.
    This will enumerate the Role-Based Access Controls (RBAC) rules defining the compromised user's authorization.
references:
    - https://www.elastic.co/guide/en/security/current/kubernetes-suspicious-self-subject-review.html
author: Leo Tsaousis (@laripping)
date: 2024-03-26
tags:
    - attack.t1069.003
    - attack.t1087.004
    - attack.discovery
logsource:
    category: application
    product: kubernetes
    service: audit
detection:
    selection:
        verb: 'create'
        apiGroup: 'authorization.k8s.io'
        objectRef.resource: 'selfsubjectrulesreviews'
    condition: selection
falsepositives:
    - Unknown
level: low

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    verb: 'create'
    apiGroup: 'authorization.k8s.io'
    objectRef.resource: 'selfsubjectrulesreviews'

Indicators

These rows show field, operator, and value matches.

Rhadamanthys Stealer Module Launch Via Rundll32.EXE

#
Status
test
Severity
medium
Author
TropChaud
Source
github.com/SigmaHQ/sigma

Detects the use of Rundll32 to launch an NSIS module that serves as the main stealer capability of Rhadamanthys infostealer, as observed in reports and samples in early 2023

MITRE ATT&CK Coverage

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 1: Process creation

Rule Body

title: Rhadamanthys Stealer Module Launch Via Rundll32.EXE
id: 5cdbc2e8-86dd-43df-9a1a-200d4745fba5
status: test
description: Detects the use of Rundll32 to launch an NSIS module that serves as the main stealer capability of Rhadamanthys infostealer, as observed in reports and samples in early 2023
references:
    - https://elis531989.medium.com/dancing-with-shellcodes-analyzing-rhadamanthys-stealer-3c4986966a88
    - https://blog.cyble.com/2023/01/12/rhadamanthys-new-stealer-spreading-through-google-ads/
    - https://www.joesandbox.com/analysis/790122/0/html
    - https://twitter.com/anfam17/status/1607477672057208835
author: TropChaud
date: 2023-01-26
modified: 2023-02-05
tags:
    - attack.stealth
    - attack.t1218.011
    - detection.emerging-threats
logsource:
    category: process_creation
    product: windows
detection:
    selection_rundll32:
        - OriginalFileName: 'RUNDLL32.EXE'
        - Image|endswith: '\rundll32.exe'
    selection_dll:
        CommandLine|contains: 'nsis_uns'
    selection_export_function:
        CommandLine|contains: 'PrintUIEntry'
    condition: all of selection_*
falsepositives:
    - Unknown
level: medium

Stages and Predicates

Stage 0: condition

all of selection_*

Stage 1: selection_rundll32

selection_rundll32:
    - OriginalFileName: 'RUNDLL32.EXE'
    - Image|endswith: '\rundll32.exe'

Stage 2: selection_dll

selection_dll:
    CommandLine|contains: 'nsis_uns'

Stage 3: selection_export_function

selection_export_function:
    CommandLine|contains: 'PrintUIEntry'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • PrintUIEntry
  • nsis_uns
field:"CommandLine" kind:match
Imageends_with
  • \rundll32.exe corpus 94 (sigma 94)
field:"Image" kind:ends_with value:"\rundll32.exe"
OriginalFileNameeq
  • RUNDLL32.EXE corpus 72 (sigma 35, splunk 21, elastic 16)
field:"OriginalFileName" kind:eq value:"RUNDLL32.EXE"

SMB over QUIC Via Net.EXE

#
Status
test
Severity
medium
Author
frack113
Source
github.com/SigmaHQ/sigma

Detects the mounting of Windows SMB shares over QUIC, which can be an unexpected event in some enterprise environments.

Known False Positives

  • Administrative activity

MITRE ATT&CK Coverage

TacticTechniques
Lateral Movement

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 1: Process creation

Rule Body

title: SMB over QUIC Via Net.EXE
id: 2238d337-42fb-4971-9a68-63570f2aede4
related:
    - id: 6df07c3b-8456-4f8b-87bb-fe31ec964cae
      type: similar
status: test
description: Detects the mounting of Windows SMB shares over QUIC, which can be an unexpected event in some enterprise environments.
references:
    - https://github.com/redcanaryco/atomic-red-team/blob/74438b0237d141ee9c99747976447dc884cb1a39/atomics/T1570/T1570.md
    - https://www.trustedsec.com/blog/making-smb-accessible-with-ntlmquic/
author: frack113
date: 2023-07-21
tags:
    - attack.lateral-movement
    - attack.t1570
    - detection.threat-hunting
logsource:
    category: process_creation
    product: windows
detection:
    selection_img:
        - Image|endswith:
              - '\net.exe'
              - '\net1.exe'
        - OriginalFileName:
              - 'net.exe'
              - 'net1.exe'
    selection_cli:
        CommandLine|contains: '/TRANSPORT:QUIC'
    condition: all of selection_*
falsepositives:
    - Administrative activity
level: medium

Stages and Predicates

Stage 0: condition

all of selection_*

Stage 1: selection_img

selection_img:
    - Image|endswith:
          - '\net.exe'
          - '\net1.exe'
    - OriginalFileName:
          - 'net.exe'
          - 'net1.exe'

Stage 2: selection_cli

selection_cli:
    CommandLine|contains: '/TRANSPORT:QUIC'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • /TRANSPORT:QUIC
field:"CommandLine" kind:match value:"/TRANSPORT:QUIC"
Imageends_with
  • \net.exe corpus 49 (sigma 49)
  • \net1.exe corpus 47 (sigma 47)
field:"Image" kind:ends_with
OriginalFileNameeq
  • net.exe corpus 25 (sigma 19, elastic 4, splunk 2)
  • net1.exe corpus 39 (sigma 19, splunk 19, elastic 1)
field:"OriginalFileName" kind:eq

Startup/Logon Script Added to Group Policy Object

#
Status
test
Severity
medium
Author
Elastic, Josh Nickels, Marius Rothenbücher
Source
github.com/SigmaHQ/sigma

Detects the modification of Group Policy Objects (GPO) to add a startup/logon script to users or computer objects.

Known False Positives

  • Legitimate execution by system administrators.

MITRE ATT&CK Coverage

Telemetry Coverage

Rule Body

title: Startup/Logon Script Added to Group Policy Object
id: 123e4e6d-b123-48f8-b261-7214938acaf0
status: test
description: |
    Detects the modification of Group Policy Objects (GPO) to add a startup/logon script to users or computer objects.
references:
    - https://www.elastic.co/guide/en/security/current/startup-logon-script-added-to-group-policy-object.html
author: Elastic, Josh Nickels, Marius Rothenbücher
date: 2024-09-06
tags:
    - attack.persistence
    - attack.privilege-escalation
    - attack.defense-impairment
    - attack.t1484.001
    - attack.t1547
logsource:
    product: windows
    service: security
    definition: 'The advanced audit policy setting "Object Access > Audit Detailed File Share" must be configured for Success/Failure'
detection:
    selection_eventid:
        EventID:
            - 5136
            - 5145
    selection_attributes_main:
        AttributeLDAPDisplayName:
            - 'gPCMachineExtensionNames'
            - 'gPCUserExtensionNames'
        AttributeValue|contains: '42B5FAAE-6536-11D2-AE5A-0000F87571E3'
    selection_attributes_optional:
        AttributeValue|contains:
            - '40B6664F-4972-11D1-A7CA-0000F87571E3'
            - '40B66650-4972-11D1-A7CA-0000F87571E3'
    selection_share:
        ShareName|endswith: '\SYSVOL'
        RelativeTargetName|endswith:
            - '\scripts.ini'
            - '\psscripts.ini'
        AccessList|contains: '%%4417'
    condition: selection_eventid and (all of selection_attributes_* or selection_share)
falsepositives:
    - Legitimate execution by system administrators.
level: medium

Stages and Predicates

Stage 0: condition

selection_eventid and (all of selection_attributes_* or selection_share)

Stage 1: selection_eventid

selection_eventid:
    EventID:
        - 5136
        - 5145

Stage 2: selection_attributes_main

selection_attributes_main:
    AttributeLDAPDisplayName:
        - 'gPCMachineExtensionNames'
        - 'gPCUserExtensionNames'
    AttributeValue|contains: '42B5FAAE-6536-11D2-AE5A-0000F87571E3'

Stage 3: selection_attributes_optional

selection_attributes_optional:
    AttributeValue|contains:
        - '40B6664F-4972-11D1-A7CA-0000F87571E3'
        - '40B66650-4972-11D1-A7CA-0000F87571E3'

Stage 4: selection_share

selection_share:
    ShareName|endswith: '\SYSVOL'
    RelativeTargetName|endswith:
        - '\scripts.ini'
        - '\psscripts.ini'
    AccessList|contains: '%%4417'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
AccessListmatch
  • %%4417 corpus 11 (sigma 8, elastic 2, splunk 1)
field:"AccessList" kind:match value:"%%4417"
AttributeLDAPDisplayNameeq
  • gPCMachineExtensionNames corpus 7 (sigma 3, elastic 3, splunk 1)
  • gPCUserExtensionNames corpus 4 (sigma 2, elastic 2)
field:"AttributeLDAPDisplayName" kind:eq
AttributeValuematch
  • 40B6664F-4972-11D1-A7CA-0000F87571E3 corpus 2 (sigma 1, elastic 1)
  • 40B66650-4972-11D1-A7CA-0000F87571E3 corpus 2 (sigma 1, elastic 1)
  • 42B5FAAE-6536-11D2-AE5A-0000F87571E3 corpus 2 (sigma 1, elastic 1)
field:"AttributeValue" kind:match
RelativeTargetNameends_with
  • \psscripts.ini corpus 2 (sigma 1, elastic 1)
  • \scripts.ini corpus 2 (sigma 1, elastic 1)
field:"RelativeTargetName" kind:ends_with
ShareNameends_with
  • \SYSVOL corpus 2 (sigma 2)
field:"ShareName" kind:ends_with value:"\SYSVOL"

Suspicious FromBase64String Usage On Gzip Archive - Ps Script

#
Status
test
Severity
medium
Author
frack113
Source
github.com/SigmaHQ/sigma

Detects attempts of decoding a base64 Gzip archive in a PowerShell script. This technique is often used as a method to load malicious content into memory afterward.

Known False Positives

  • Legitimate administrative script

MITRE ATT&CK Coverage

TacticTechniques
Command & Control

Telemetry Coverage

Rule Body

title: Suspicious FromBase64String Usage On Gzip Archive - Ps Script
id: df69cb1d-b891-4cd9-90c7-d617d90100ce
related:
    - id: d75d6b6b-adb9-48f7-824b-ac2e786efe1f
      type: similar
status: test
description: Detects attempts of decoding a base64 Gzip archive in a PowerShell script. This technique is often used as a method to load malicious content into memory afterward.
references:
    - https://speakerdeck.com/heirhabarov/hunting-for-powershell-abuse?slide=43
author: frack113
date: 2022-12-23
tags:
    - attack.command-and-control
    - attack.t1132.001
logsource:
    product: windows
    category: ps_script
    definition: 'Requirements: Script Block Logging must be enabled'
detection:
    selection:
        ScriptBlockText|contains|all:
            - 'FromBase64String'
            - 'MemoryStream'
            - 'H4sI'
    condition: selection
falsepositives:
    - Legitimate administrative script
level: medium
regression_tests_path: regression_data/rules/windows/powershell/powershell_script/posh_ps_frombase64string_archive/info.yml

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    ScriptBlockText|contains|all:
        - 'FromBase64String'
        - 'MemoryStream'
        - 'H4sI'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
ScriptBlockTextmatch
  • FromBase64String corpus 4 (sigma 2, splunk 2)
  • H4sI
  • MemoryStream
field:"ScriptBlockText" kind:match

System Information Discovery Using Ioreg

#
Status
test
Severity
medium
Author
Joseliyo Sanchez, @Joseliyo_Jstnk
Source
github.com/SigmaHQ/sigma

Detects the use of "ioreg" which will show I/O Kit registry information. This process is used for system information discovery. It has been observed in-the-wild by calling this process directly or using bash and grep to look for specific strings.

Known False Positives

  • Legitimate administrative activities

MITRE ATT&CK Coverage

TacticTechniques
Discovery

Telemetry Coverage

Rule Body

title: System Information Discovery Using Ioreg
id: 2d5e7a8b-f484-4a24-945d-7f0efd52eab0
status: test
description: |
    Detects the use of "ioreg" which will show I/O Kit registry information.
    This process is used for system information discovery.
    It has been observed in-the-wild by calling this process directly or using bash and grep to look for specific strings.
references:
    - https://www.virustotal.com/gui/file/0373d78db6c3c0f6f6dcc409821bf89e1ad8c165d6f95c5c80ecdce2219627d7/behavior
    - https://www.virustotal.com/gui/file/4ffdc72d1ff1ee8228e31691020fc275afd1baee5a985403a71ca8c7bd36e2e4/behavior
    - https://www.virustotal.com/gui/file/5907d59ec1303cfb5c0a0f4aaca3efc0830707d86c732ba6b9e842b5730b95dc/behavior
    - https://www.trendmicro.com/en_ph/research/20/k/new-macos-backdoor-connected-to-oceanlotus-surfaces.html
author: Joseliyo Sanchez, @Joseliyo_Jstnk
date: 2023-12-20
modified: 2024-01-02
tags:
    - attack.discovery
    - attack.t1082
logsource:
    product: macos
    category: process_creation
detection:
    # Examples:
    #   /bin/bash /bin/sh -c ioreg -l | grep -e 'VirtualBox' -e 'Oracle' -e 'VMware' -e 'Parallels' | wc -l
    #   /usr/sbin/ioreg ioreg -rd1 -w0 -c AppleAHCIDiskDriver
    #   /bin/bash /bin/sh -c ioreg -l | grep -e 'USB Vendor Name'
    #   ioreg -rd1 -c IOPlatformExpertDevice | awk '/IOPlatformSerialNumber/ { split($0, line, \"\\\"\"); printf(\"%s\", line[4]); }
    selection_img:
        - Image|endswith: '/ioreg'
        - CommandLine|contains: 'ioreg'
    selection_cmd1:
        CommandLine|contains:
            - '-l'
            - '-c'
    selection_cmd2:
        CommandLine|contains:
            - 'AppleAHCIDiskDriver'
            - 'IOPlatformExpertDevice'
            - 'Oracle'
            - 'Parallels'
            - 'USB Vendor Name'
            - 'VirtualBox'
            - 'VMware'
    condition: all of selection_*
falsepositives:
    - Legitimate administrative activities
level: medium

Stages and Predicates

Stage 0: condition

all of selection_*

Stage 1: selection_img

selection_img:
    - Image|endswith: '/ioreg'
    - CommandLine|contains: 'ioreg'

Stage 2: selection_cmd1

selection_cmd1:
    CommandLine|contains:
        - '-l'
        - '-c'

Stage 3: selection_cmd2

selection_cmd2:
    CommandLine|contains:
        - 'AppleAHCIDiskDriver'
        - 'IOPlatformExpertDevice'
        - 'Oracle'
        - 'Parallels'
        - 'USB Vendor Name'
        - 'VirtualBox'
        - 'VMware'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • -c corpus 7 (sigma 6, splunk 1)
  • -l corpus 2 (sigma 1, splunk 1)
  • AppleAHCIDiskDriver
  • IOPlatformExpertDevice
  • Oracle
  • Parallels
  • USB Vendor Name
  • VMware
  • VirtualBox
  • ioreg
field:"CommandLine" kind:match
Imageends_with
  • /ioreg
field:"Image" kind:ends_with value:"/ioreg"

UAC Bypass Using WOW64 Logger DLL Hijack

#
Status
test
Severity
high
Author
Christian Burkard (Nextron Systems)
Source
github.com/SigmaHQ/sigma

Detects the pattern of UAC Bypass using a WoW64 logger DLL hijack (UACMe 30)

MITRE ATT&CK Coverage

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 10: ProcessAccess

Rule Body

title: UAC Bypass Using WOW64 Logger DLL Hijack
id: 4f6c43e2-f989-4ea5-bcd8-843b49a0317c
status: test
description: Detects the pattern of UAC Bypass using a WoW64 logger DLL hijack (UACMe 30)
references:
    - https://github.com/hfiref0x/UACME
author: Christian Burkard (Nextron Systems)
date: 2021-08-23
modified: 2022-10-09
tags:
    - attack.privilege-escalation
    - attack.t1548.002
logsource:
    category: process_access
    product: windows
detection:
    selection:
        SourceImage|contains: ':\Windows\SysWOW64\'
        GrantedAccess: '0x1fffff'
        CallTrace|startswith: 'UNKNOWN(0000000000000000)|UNKNOWN(0000000000000000)|'
    condition: selection
falsepositives:
    - Unknown
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    SourceImage|contains: ':\Windows\SysWOW64\'
    GrantedAccess: '0x1fffff'
    CallTrace|startswith: 'UNKNOWN(0000000000000000)|UNKNOWN(0000000000000000)|'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CallTracestarts_with
  • UNKNOWN(0000000000000000)|UNKNOWN(0000000000000000)|
field:"CallTrace" kind:starts_with value:"UNKNOWN(0000000000000000)|UNKNOWN(0000000000000000)|"
GrantedAccesseq
  • 0x1fffff corpus 9 (sigma 7, splunk 1, kusto 1)
field:"GrantedAccess" kind:eq value:"0x1fffff"
SourceImagematch
  • :\Windows\SysWOW64\
field:"SourceImage" kind:match value:":\Windows\SysWOW64\"

Uncommon GrantedAccess Flags On LSASS

#
Status
test
Severity
medium
Author
Florian Roth (Nextron Systems)
Source
github.com/SigmaHQ/sigma

Detects process access to LSASS memory with uncommon access flags 0x410 and 0x01410

Known False Positives

  • Legitimate software accessing LSASS process for legitimate reason

MITRE ATT&CK Coverage

TacticTechniques
Credential Access

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 10: ProcessAccess

Rule Body

title: Uncommon GrantedAccess Flags On LSASS
id: 678dfc63-fefb-47a5-a04c-26bcf8cc9f65
related:
    - id: 32d0d3e2-e58d-4d41-926b-18b520b2b32d
      type: obsolete
status: test
description: Detects process access to LSASS memory with uncommon access flags 0x410 and 0x01410
references:
    - https://docs.microsoft.com/en-us/windows/win32/procthread/process-security-and-access-rights
    - https://onedrive.live.com/view.aspx?resid=D026B4699190F1E6!2843&ithint=file%2cpptx&app=PowerPoint&authkey=!AMvCRTKB_V1J5ow
    - https://web.archive.org/web/20230208123920/https://cyberwardog.blogspot.com/2017/03/chronicles-of-threat-hunter-hunting-for_22.html
    - https://www.slideshare.net/heirhabarov/hunting-for-credentials-dumping-in-windows-environment
    - https://web.archive.org/web/20230420013146/http://security-research.dyndns.org/pub/slides/FIRST2017/FIRST-2017_Tom-Ueltschi_Sysmon_FINAL_notes.pdf
author: Florian Roth (Nextron Systems)
date: 2022-03-13
modified: 2023-11-30
tags:
    - attack.credential-access
    - attack.t1003.001
    - attack.s0002
    - detection.threat-hunting
logsource:
    category: process_access
    product: windows
detection:
    selection:
        TargetImage|endswith: '\lsass.exe'
        GrantedAccess|endswith: '10'
    # Absolute paths to programs that cause false positives
    filter1:
        SourceImage:
            - 'C:\Program Files\Common Files\McAfee\MMSSHost\MMSSHOST.exe'
            - 'C:\Program Files\Malwarebytes\Anti-Malware\MBAMService.exe'
            - 'C:\Program Files\Windows Defender\MsMpEng.exe'
            - 'C:\PROGRAMDATA\MALWAREBYTES\MBAMSERVICE\ctlrupdate\mbupdatr.exe'
            - 'C:\Windows\System32\lsass.exe'
            - 'C:\Windows\System32\msiexec.exe'
            - 'C:\WINDOWS\System32\perfmon.exe'
            - 'C:\WINDOWS\system32\taskhostw.exe'
            - 'C:\WINDOWS\system32\taskmgr.exe'
            - 'C:\WINDOWS\system32\wbem\wmiprvse.exe'
            - 'C:\Windows\SysWOW64\msiexec.exe'
            - 'C:\Windows\sysWOW64\wbem\wmiprvse.exe'
    # Windows Defender
    filter2:
        SourceImage|startswith: 'C:\ProgramData\Microsoft\Windows Defender\'
        SourceImage|endswith: '\MsMpEng.exe'
    # Microsoft Gaming Services
    filter3:
        SourceImage|startswith: 'C:\Program Files\WindowsApps\'
        SourceImage|endswith: '\GamingServices.exe'
    # Process Explorer
    filter4:
        SourceImage|endswith:
            - '\PROCEXP64.EXE'
            - '\PROCEXP.EXE'
    # VMware Tools
    filter5:
        SourceImage|startswith: 'C:\ProgramData\VMware\VMware Tools\'
        SourceImage|endswith: '\vmtoolsd.exe'
    # Antivirus and EDR agents
    filter6:
        SourceImage|startswith:
            - 'C:\Program Files\'
            - 'C:\Program Files (x86)\'
        SourceImage|contains: 'Antivirus'
    filter_nextron:
        # SourceImage|startswith: 'C:\Windows\Temp\asgard2-agent\'  # Can be a manual THOR installation
        SourceImage|endswith:
            - '\thor64.exe'
            - '\thor.exe'
            - '\aurora-agent-64.exe'
            - '\aurora-agent.exe'
    filter_ms_products:
        SourceImage|contains|all:
            - '\AppData\Local\Temp\'
            - '\vs_bootstrapper_'
        GrantedAccess: '0x1410'
    # Generic Filter for 0x1410 filter (caused by so many programs like DropBox updates etc.)
    filter_generic:
        SourceImage|startswith:
            - 'C:\Program Files\'
            - 'C:\Program Files (x86)\'
            - 'C:\WINDOWS\system32\'
    filter_wer:
        SourceCommandLine: 'C:\WINDOWS\system32\wermgr.exe -upload'
    filter_localappdata:
        SourceImage|contains|all:
            - 'C:\Users\'
            - '\AppData\Local\'
        SourceImage|endswith:
            - '\Microsoft VS Code\Code.exe'
            - '\software_reporter_tool.exe'
            - '\DropboxUpdate.exe'
            - '\MBAMInstallerService.exe'
            - '\WebEx\WebexHost.exe'
            - '\Programs\Microsoft VS Code\Code.exe'
            - '\JetBrains\Toolbox\bin\jetbrains-toolbox.exe'
    filter_xampp:
        SourceImage|endswith: '\xampp-control.exe'
        GrantedAccess: '0x410'
    filter_games:
        SourceImage|contains: '\SteamLibrary\steamapps\'
        GrantedAccess:
            - '0x410'
            - '0x10'
    condition: selection and not 1 of filter*
falsepositives:
    - Legitimate software accessing LSASS process for legitimate reason
level: medium

Stages and Predicates

Stage 0: condition

selection and not 1 of filter*

Stage 1: selection

selection:
    TargetImage|endswith: '\lsass.exe'
    GrantedAccess|endswith: '10'

Stage 2: not filter*

filter1:
    SourceImage:
        - 'C:\Program Files\Common Files\McAfee\MMSSHost\MMSSHOST.exe'
        - 'C:\Program Files\Malwarebytes\Anti-Malware\MBAMService.exe'
        - 'C:\Program Files\Windows Defender\MsMpEng.exe'
        - 'C:\PROGRAMDATA\MALWAREBYTES\MBAMSERVICE\ctlrupdate\mbupdatr.exe'
        - 'C:\Windows\System32\lsass.exe'
        - 'C:\Windows\System32\msiexec.exe'
        - 'C:\WINDOWS\System32\perfmon.exe'
        - 'C:\WINDOWS\system32\taskhostw.exe'
        - 'C:\WINDOWS\system32\taskmgr.exe'
        - 'C:\WINDOWS\system32\wbem\wmiprvse.exe'
        - 'C:\Windows\SysWOW64\msiexec.exe'
        - 'C:\Windows\sysWOW64\wbem\wmiprvse.exe'
filter2:
    SourceImage|startswith: 'C:\ProgramData\Microsoft\Windows Defender\'
    SourceImage|endswith: '\MsMpEng.exe'
filter3:
    SourceImage|startswith: 'C:\Program Files\WindowsApps\'
    SourceImage|endswith: '\GamingServices.exe'
filter4:
    SourceImage|endswith:
        - '\PROCEXP64.EXE'
        - '\PROCEXP.EXE'
filter5:
    SourceImage|startswith: 'C:\ProgramData\VMware\VMware Tools\'
    SourceImage|endswith: '\vmtoolsd.exe'
filter6:
    SourceImage|startswith:
        - 'C:\Program Files\'
        - 'C:\Program Files (x86)\'
    SourceImage|contains: 'Antivirus'
filter_nextron:
    SourceImage|endswith:
        - '\thor64.exe'
        - '\thor.exe'
        - '\aurora-agent-64.exe'
        - '\aurora-agent.exe'
filter_ms_products:
    SourceImage|contains|all:
        - '\AppData\Local\Temp\'
        - '\vs_bootstrapper_'
    GrantedAccess: '0x1410'
filter_generic:
    SourceImage|startswith:
        - 'C:\Program Files\'
        - 'C:\Program Files (x86)\'
        - 'C:\WINDOWS\system32\'
filter_wer:
    SourceCommandLine: 'C:\WINDOWS\system32\wermgr.exe -upload'
filter_localappdata:
    SourceImage|contains|all:
        - 'C:\Users\'
        - '\AppData\Local\'
    SourceImage|endswith:
        - '\Microsoft VS Code\Code.exe'
        - '\software_reporter_tool.exe'
        - '\DropboxUpdate.exe'
        - '\MBAMInstallerService.exe'
        - '\WebEx\WebexHost.exe'
        - '\Programs\Microsoft VS Code\Code.exe'
        - '\JetBrains\Toolbox\bin\jetbrains-toolbox.exe'
filter_xampp:
    SourceImage|endswith: '\xampp-control.exe'
    GrantedAccess: '0x410'
filter_games:
    SourceImage|contains: '\SteamLibrary\steamapps\'
    GrantedAccess:
        - '0x410'
        - '0x10'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
GrantedAccessends_with
  • 10 corpus 4 (sigma 4)
field:"GrantedAccess" kind:ends_with value:"10"
TargetImageends_with
  • \lsass.exe corpus 17 (sigma 16, splunk 1)
field:"TargetImage" kind:ends_with value:"\lsass.exe"

Exclusions

The rule actively suppresses these predicates.

FieldKindExcluded valuesSearch
GrantedAccesseq0x10excludes:GrantedAccess field:"GrantedAccess" value:"0x10"
GrantedAccesseq0x410excludes:GrantedAccess field:"GrantedAccess" value:"0x410"
SourceImagematch\SteamLibrary\steamapps\excludes:SourceImage field:"SourceImage" value:"\SteamLibrary\steamapps\"
SourceImageends_with\DropboxUpdate.exeexcludes:SourceImage field:"SourceImage" value:"\DropboxUpdate.exe"
SourceImageends_with\JetBrains\Toolbox\bin\jetbrains-toolbox.exeexcludes:SourceImage field:"SourceImage" value:"\JetBrains\Toolbox\bin\jetbrains-toolbox.exe"
SourceImageends_with\MBAMInstallerService.exeexcludes:SourceImage field:"SourceImage" value:"\MBAMInstallerService.exe"
SourceImageends_with\Microsoft VS Code\Code.exeexcludes:SourceImage field:"SourceImage" value:"\Microsoft VS Code\Code.exe"
SourceImageends_with\Programs\Microsoft VS Code\Code.exeexcludes:SourceImage field:"SourceImage" value:"\Programs\Microsoft VS Code\Code.exe"
SourceImageends_with\WebEx\WebexHost.exeexcludes:SourceImage field:"SourceImage" value:"\WebEx\WebexHost.exe"
SourceImageends_with\software_reporter_tool.exeexcludes:SourceImage field:"SourceImage" value:"\software_reporter_tool.exe"
SourceImagematchC:\Users\excludes:SourceImage field:"SourceImage" value:"C:\Users\"
SourceImagematch\AppData\Local\excludes:SourceImage field:"SourceImage" value:"\AppData\Local\"
SourceImagestarts_withC:\Program Files (x86)\excludes:SourceImage field:"SourceImage" value:"C:\Program Files (x86)\"
SourceImagestarts_withC:\Program Files\excludes:SourceImage field:"SourceImage" value:"C:\Program Files\"
SourceImagematchAntivirusexcludes:SourceImage field:"SourceImage" value:"Antivirus"
GrantedAccesseq0x1410excludes:GrantedAccess field:"GrantedAccess" value:"0x1410"
SourceImagematch\AppData\Local\Temp\excludes:SourceImage field:"SourceImage" value:"\AppData\Local\Temp\"
SourceImagematch\vs_bootstrapper_excludes:SourceImage field:"SourceImage" value:"\vs_bootstrapper_"
SourceImageends_with\xampp-control.exeexcludes:SourceImage field:"SourceImage" value:"\xampp-control.exe"
SourceImageends_with\GamingServices.exeexcludes:SourceImage field:"SourceImage" value:"\GamingServices.exe"
SourceImagestarts_withC:\Program Files\WindowsApps\excludes:SourceImage field:"SourceImage" value:"C:\Program Files\WindowsApps\"
SourceImageends_with\MsMpEng.exeexcludes:SourceImage field:"SourceImage" value:"\MsMpEng.exe"
SourceImagestarts_withC:\ProgramData\Microsoft\Windows Defender\excludes:SourceImage field:"SourceImage" value:"C:\ProgramData\Microsoft\Windows Defender\"
SourceImageends_with\vmtoolsd.exeexcludes:SourceImage field:"SourceImage" value:"\vmtoolsd.exe"
SourceImagestarts_withC:\ProgramData\VMware\VMware Tools\excludes:SourceImage field:"SourceImage" value:"C:\ProgramData\VMware\VMware Tools\"
SourceCommandLineeqC:\WINDOWS\system32\wermgr.exe -uploadexcludes:SourceCommandLine field:"SourceCommandLine" value:"C:\WINDOWS\system32\wermgr.exe -upload"
SourceImageends_with\PROCEXP.EXEexcludes:SourceImage field:"SourceImage" value:"\PROCEXP.EXE"
SourceImageends_with\PROCEXP64.EXEexcludes:SourceImage field:"SourceImage" value:"\PROCEXP64.EXE"
SourceImageends_with\aurora-agent-64.exeexcludes:SourceImage field:"SourceImage" value:"\aurora-agent-64.exe"
SourceImageends_with\aurora-agent.exeexcludes:SourceImage field:"SourceImage" value:"\aurora-agent.exe"
SourceImageends_with\thor.exeexcludes:SourceImage field:"SourceImage" value:"\thor.exe"
SourceImageends_with\thor64.exeexcludes:SourceImage field:"SourceImage" value:"\thor64.exe"
SourceImageeqC:\PROGRAMDATA\MALWAREBYTES\MBAMSERVICE\ctlrupdate\mbupdatr.exeexcludes:SourceImage field:"SourceImage" value:"C:\PROGRAMDATA\MALWAREBYTES\MBAMSERVICE\ctlrupdate\mbupdatr.exe"
SourceImageeqC:\Program Files\Common Files\McAfee\MMSSHost\MMSSHOST.exeexcludes:SourceImage field:"SourceImage" value:"C:\Program Files\Common Files\McAfee\MMSSHost\MMSSHOST.exe"
SourceImageeqC:\Program Files\Malwarebytes\Anti-Malware\MBAMService.exeexcludes:SourceImage field:"SourceImage" value:"C:\Program Files\Malwarebytes\Anti-Malware\MBAMService.exe"
SourceImageeqC:\Program Files\Windows Defender\MsMpEng.exeexcludes:SourceImage field:"SourceImage" value:"C:\Program Files\Windows Defender\MsMpEng.exe"
SourceImageeqC:\WINDOWS\System32\perfmon.exeexcludes:SourceImage field:"SourceImage" value:"C:\WINDOWS\System32\perfmon.exe"
SourceImageeqC:\WINDOWS\system32\taskhostw.exeexcludes:SourceImage field:"SourceImage" value:"C:\WINDOWS\system32\taskhostw.exe"
SourceImageeqC:\WINDOWS\system32\taskmgr.exeexcludes:SourceImage field:"SourceImage" value:"C:\WINDOWS\system32\taskmgr.exe"
SourceImageeqC:\WINDOWS\system32\wbem\wmiprvse.exeexcludes:SourceImage field:"SourceImage" value:"C:\WINDOWS\system32\wbem\wmiprvse.exe"
SourceImageeqC:\Windows\SysWOW64\msiexec.exeexcludes:SourceImage field:"SourceImage" value:"C:\Windows\SysWOW64\msiexec.exe"
SourceImageeqC:\Windows\System32\lsass.exeexcludes:SourceImage field:"SourceImage" value:"C:\Windows\System32\lsass.exe"
SourceImageeqC:\Windows\System32\msiexec.exeexcludes:SourceImage field:"SourceImage" value:"C:\Windows\System32\msiexec.exe"
SourceImageeqC:\Windows\sysWOW64\wbem\wmiprvse.exeexcludes:SourceImage field:"SourceImage" value:"C:\Windows\sysWOW64\wbem\wmiprvse.exe"
SourceImagestarts_withC:\WINDOWS\system32\excludes:SourceImage field:"SourceImage" value:"C:\WINDOWS\system32\"

Uninstall Crowdstrike Falcon Sensor

#
Status
test
Severity
high
Author
frack113
Source
github.com/SigmaHQ/sigma

Adversaries may disable security tools to avoid possible detection of their tools and activities by uninstalling Crowdstrike Falcon

Known False Positives

  • Administrator might leverage the same command line for debugging or other purposes. However this action must be always investigated

MITRE ATT&CK Coverage

TacticTechniques
Defense Impairment

Telemetry Coverage

Rule Body

title: Uninstall Crowdstrike Falcon Sensor
id: f0f7be61-9cf5-43be-9836-99d6ef448a18
status: test
description: Adversaries may disable security tools to avoid possible detection of their tools and activities by uninstalling Crowdstrike Falcon
references:
    - https://github.com/redcanaryco/atomic-red-team/blob/f339e7da7d05f6057fdfcdd3742bfcf365fee2a9/atomics/T1562.001/T1562.001.md
author: frack113
date: 2021-07-12
modified: 2023-03-09
tags:
    - attack.defense-impairment
    - attack.t1685
logsource:
    category: process_creation
    product: windows
detection:
    selection:
        CommandLine|contains|all:
            - '\WindowsSensor.exe'
            - ' /uninstall'
            - ' /quiet'
    condition: selection
falsepositives:
    - Administrator might leverage the same command line for debugging or other purposes. However this action must be always investigated
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    CommandLine|contains|all:
        - '\WindowsSensor.exe'
        - ' /uninstall'
        - ' /quiet'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • /quiet
  • /uninstall
  • \WindowsSensor.exe
field:"CommandLine" kind:match

WMI registration

#
Status
experimental
Severity
high
Author
mdecrevoisier
Source
github.com/mdecrevoisier/SIGMA-detection-rules

Detects scenarios where an attacker createsan instance of a WMI class using tools like WMImplant or PowerLurk.

Known False Positives

  • legitimate WMI class registration
  • monitoring products
  • Microsoft System Center or security products

MITRE ATT&CK Coverage

Telemetry Coverage

Rule Body

title: WMI registration
description: Detects scenarios where an attacker createsan instance of a WMI class using tools like WMImplant or PowerLurk.
references:
- https://github.com/mdecrevoisier/EVTX-to-MITRE-Attack/tree/master/TA0003-Persistence/T1546-Event%20Triggered%20Execution
- https://github.com/Sw4mpf0x/PowerLurk
- https://github.com/FortyNorthSecurity/WMImplant
- https://www.netspi.com/blog/technical/adversary-simulation/getting-started-wmi-weaponization-part-5/
- https://www.darkoperator.com/blog/2017/10/14/basics-of-tracking-wmi-activity
tags:
- attack.persistence
- attack.t1546.003
author: mdecrevoisier
status: experimental
logsource:
  product: windows
  category: wmi_event
detection:
  selection:
    EventID:
      - 19 # WmiEventFilter activity detected
      - 20 # WmiEventConsumer activity detected
      - 21 # WmiEventConsumerToFilter activity detected
  condition: selection
falsepositives:
- legitimate WMI class registration
- monitoring products
- Microsoft System Center or security products
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
  EventID:
    - 19
    - 20
    - 21

Wusa.EXE Executed By Parent Process Located In Suspicious Location

#
Status
test
Severity
high
Author
X__Junior (Nextron Systems)
Source
github.com/SigmaHQ/sigma

Detects execution of the "wusa.exe" (Windows Update Standalone Installer) utility by a parent process that is located in a suspicious location. Attackers could instantiate an instance of "wusa.exe" in order to bypass User Account Control (UAC). They can duplicate the access token from "wusa.exe" to gain elevated privileges.

MITRE ATT&CK Coverage

TacticTechniques
ExecutionNo specific technique

Telemetry Coverage

Rule Body

title: Wusa.EXE Executed By Parent Process Located In Suspicious Location
id: ef64fc9c-a45e-43cc-8fd8-7d75d73b4c99
status: test
description: |
    Detects execution of the "wusa.exe" (Windows Update Standalone Installer) utility by a parent process that is located in a suspicious location.
    Attackers could instantiate an instance of "wusa.exe" in order to bypass User Account Control (UAC). They can duplicate the access token from "wusa.exe" to gain elevated privileges.
references:
    - https://www.fortinet.com/blog/threat-research/konni-campaign-distributed-via-malicious-document
author: X__Junior (Nextron Systems)
date: 2023-11-26
modified: 2024-08-15
tags:
    - attack.execution
logsource:
    category: process_creation
    product: windows
detection:
    selection_img:
        Image|endswith: '\wusa.exe'
    selection_paths_1:
        ParentImage|contains:
            # Note: Add additional suspicious locations to increase coverage
            - ':\Perflogs\'
            - ':\Users\Public\'
            - ':\Windows\Temp\'
            - '\Appdata\Local\Temp\'
            - '\Temporary Internet'
    selection_paths_2:
        - ParentImage|contains|all:
              - ':\Users\'
              - '\Favorites\'
        - ParentImage|contains|all:
              - ':\Users\'
              - '\Favourites\'
        - ParentImage|contains|all:
              - ':\Users\'
              - '\Contacts\'
        - ParentImage|contains|all:
              - ':\Users\'
              - '\Pictures\'
    filter_main_msu:
        # Note: We exclude MSU extension files. A better approach is to baseline installation of updates in your env to avoid false negatives.
        CommandLine|contains: '.msu'
    condition: selection_img and 1 of selection_paths_* and not 1 of filter_main_*
falsepositives:
    - Unknown
level: high

Stages and Predicates

Stage 0: condition

selection_img and 1 of selection_paths_* and not 1 of filter_main_*

Stage 1: selection_img

selection_img:
    Image|endswith: '\wusa.exe'

Stage 2: selection_paths_1

selection_paths_1:
    ParentImage|contains:
        - ':\Perflogs\'
        - ':\Users\Public\'
        - ':\Windows\Temp\'
        - '\Appdata\Local\Temp\'
        - '\Temporary Internet'

Stage 3: selection_paths_2

selection_paths_2:
    - ParentImage|contains|all:
          - ':\Users\'
          - '\Favorites\'
    - ParentImage|contains|all:
          - ':\Users\'
          - '\Favourites\'
    - ParentImage|contains|all:
          - ':\Users\'
          - '\Contacts\'
    - ParentImage|contains|all:
          - ':\Users\'
          - '\Pictures\'

Stage 4: not filter_main_msu

filter_main_msu:
    CommandLine|contains: '.msu'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
Imageends_with
  • \wusa.exe corpus 4 (sigma 4)
field:"Image" kind:ends_with value:"\wusa.exe"
ParentImagematch
  • :\Perflogs\
  • :\Users\
  • :\Users\Public\ corpus 2 (sigma 2)
  • :\Windows\Temp\
  • \Appdata\Local\Temp\ corpus 2 (sigma 2)
  • \Contacts\
  • \Favorites\
  • \Favourites\
  • \Pictures\
  • \Temporary Internet corpus 2 (sigma 2)
field:"ParentImage" kind:match

Exclusions

The rule actively suppresses these predicates.

FieldKindExcluded valuesSearch
CommandLinematch.msuexcludes:CommandLine field:"CommandLine" value:".msu"

Back to all Sigma rules