Detection rules › Sigma

Sigma rules: 3e

RuleSeverity
Access To Windows Outlook Mail Files By Uncommon Applicationslow
Adwind RAT / JRAT File Artifacthigh
BitLocker feature configuration (Reg via command)high
Cisco Sniffingmedium
Curl.EXE Execution With Custom UserAgentmedium
Defrag Deactivation - Securitymedium
Diamond Sleet APT Scheduled Task Creation - Registryhigh
DLL Sideloading by VMware Xfer Utilityhigh
DNS TXT Answer with Possible Execution Stringshigh
DoT (DNS over TLS) activation (command)medium
Email Exifiltration Via Powershellhigh
Firewall rule any/any createdhigh
HackTool - PowerTool Executionhigh
Interactive privileged shell triggered by schedule task (deprecated)high
Kerberos Manipulationhigh
Local group membership changehigh
Microsoft 365 - Potential Ransomware Activitymedium
Mimikatz driver deployed via servicehigh
Network Connection Initiated By Eqnedt32.EXEhigh
New Network Route Addedmedium
OpenCanary - GIT Clone Requesthigh
OpenCanary - SSH New Connection Attempthigh
Password policy discovery via commandlinehigh
Potential Ursnif Malware Activity - Registryhigh
Potentially Suspicious Malware Callback Communication - Linuxhigh
PUA - Crassus Executionhigh
Remote Registry Reconhigh
Shell Execution via Nice - Linuxhigh
Suspicious Executable File Creationhigh
Suspicious Response File Execution Via Odbcconf.EXEhigh
Suspicious Velociraptor Child Processhigh
Tap Driver Installation - Securitylow
Usage Of Web Request Commands And Cmdlets - ScriptBlockmedium
User added to a group via commandlinehigh
Wannacry Killswitch Domainhigh
Windows Shell/Scripting Processes Spawning Suspicious Programshigh
WScript or CScript Dropper - Filehigh

Access To Windows Outlook Mail Files By Uncommon Applications

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

Detects file access requests to Windows Outlook Mail by uncommon processes. Could indicate potential attempt of credential stealing. Requires heavy baselining before usage

Known False Positives

  • Antivirus, Anti-Spyware, Anti-Malware Software
  • Backup software
  • Legitimate software installed on partitions other than "C:\"
  • Searching software such as "everything.exe"

MITRE ATT&CK Coverage

Rule Body

title: Access To Windows Outlook Mail Files By Uncommon Applications
id: fc3e237f-2fef-406c-b90d-b3ae7e02fa8f
status: test
description: |
    Detects file access requests to Windows Outlook Mail by uncommon processes.
    Could indicate potential attempt of credential stealing.
    Requires heavy baselining before usage
references:
    - https://darkdefender.medium.com/windows-10-mail-app-forensics-39025f5418d2
    - https://github.com/redcanaryco/atomic-red-team/blob/58496ee3306e6e42a7054d36a94e6eb561ee3081/atomics/T1070.008/T1070.008.md#atomic-test-4---copy-and-modify-mailbox-data-on-windows
author: frack113
date: 2024-05-10
modified: 2024-07-29
tags:
    - attack.stealth
    - attack.t1070.008
    - detection.threat-hunting
logsource:
    category: file_access
    product: windows
    definition: 'Requirements: Microsoft-Windows-Kernel-File ETW provider'
detection:
    selection_unistore:
        FileName|contains: '\AppData\Local\Comms\Unistore\data'
    selection_unistoredb:
        FileName|endswith: '\AppData\Local\Comms\UnistoreDB\store.vol'
    filter_main_system:
        Image: 'System'
    filter_main_generic:
        # This filter is added to avoid large amount of FP with 3rd party software. You should remove this in favour of specific filter per-application
        Image|startswith:
            - 'C:\Program Files (x86)\'
            - 'C:\Program Files\'
            - 'C:\Windows\system32\'
            - 'C:\Windows\SysWOW64\'
    filter_optional_defender:
        Image|startswith: 'C:\ProgramData\Microsoft\Windows Defender\'
        Image|endswith:
            - '\MpCopyAccelerator.exe'
            - '\MsMpEng.exe'
    filter_optional_thor:
        Image|endswith:
            - '\thor64.exe'
            - '\thor.exe'
    condition: 1 of selection_* and not 1 of filter_main_* and not 1 of filter_optional_*
falsepositives:
    - Antivirus, Anti-Spyware, Anti-Malware Software
    - Backup software
    - Legitimate software installed on partitions other than "C:\"
    - Searching software such as "everything.exe"
# Note: Increase after initial baseline
level: low

Stages and Predicates

Stage 0: condition

1 of selection_* and not 1 of filter_main_* and not 1 of filter_optional_*

Stage 1: selection_unistore

selection_unistore:
    FileName|contains: '\AppData\Local\Comms\Unistore\data'

Stage 2: selection_unistoredb

selection_unistoredb:
    FileName|endswith: '\AppData\Local\Comms\UnistoreDB\store.vol'

Stage 3: not filter_main_*

filter_main_system:
    Image: 'System'
filter_main_generic:
    Image|startswith:
        - 'C:\Program Files (x86)\'
        - 'C:\Program Files\'
        - 'C:\Windows\system32\'
        - 'C:\Windows\SysWOW64\'

Stage 4: not filter_optional_*

filter_optional_defender:
    Image|startswith: 'C:\ProgramData\Microsoft\Windows Defender\'
    Image|endswith:
        - '\MpCopyAccelerator.exe'
        - '\MsMpEng.exe'
filter_optional_thor:
    Image|endswith:
        - '\thor64.exe'
        - '\thor.exe'

Indicators

These rows show field, operator, and value matches.

Exclusions

The rule actively suppresses these predicates.

FieldKindExcluded valuesSearch
ImageeqSystemexcludes:Image field:"Image" value:"System"
Imagestarts_withC:\Program Files (x86)\excludes:Image field:"Image" value:"C:\Program Files (x86)\"
Imagestarts_withC:\Program Files\excludes:Image field:"Image" value:"C:\Program Files\"
Imagestarts_withC:\Windows\SysWOW64\excludes:Image field:"Image" value:"C:\Windows\SysWOW64\"
Imagestarts_withC:\Windows\system32\excludes:Image field:"Image" value:"C:\Windows\system32\"
Imageends_with\MpCopyAccelerator.exeexcludes:Image field:"Image" value:"\MpCopyAccelerator.exe"
Imageends_with\MsMpEng.exeexcludes:Image field:"Image" value:"\MsMpEng.exe"
Imagestarts_withC:\ProgramData\Microsoft\Windows Defender\excludes:Image field:"Image" value:"C:\ProgramData\Microsoft\Windows Defender\"
Imageends_with\thor.exeexcludes:Image field:"Image" value:"\thor.exe"
Imageends_with\thor64.exeexcludes:Image field:"Image" value:"\thor64.exe"

Adwind RAT / JRAT File Artifact

#
Status
test
Severity
high
Author
Florian Roth (Nextron Systems), Tom Ueltschi, Jonhnathan Ribeiro, oscd.community
Source
github.com/SigmaHQ/sigma

Detects javaw.exe in AppData folder as used by Adwind / JRAT

MITRE ATT&CK Coverage

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 11: FileCreate

Rule Body

title: Adwind RAT / JRAT File Artifact
id: 0bcfabcb-7929-47f4-93d6-b33fb67d34d1
related:
    - id: 1fac1481-2dbc-48b2-9096-753c49b4ec71
      type: derived
status: test
description: Detects javaw.exe in AppData folder as used by Adwind / JRAT
references:
    - https://www.hybrid-analysis.com/sample/ba86fa0d4b6af2db0656a88b1dd29f36fe362473ae8ad04255c4e52f214a541c?environmentId=100
    - https://www.first.org/resources/papers/conf2017/Advanced-Incident-Detection-and-Threat-Hunting-using-Sysmon-and-Splunk.pdf
author: Florian Roth (Nextron Systems), Tom Ueltschi, Jonhnathan Ribeiro, oscd.community
date: 2017-11-10
modified: 2022-12-02
tags:
    - attack.execution
    - attack.t1059.005
    - attack.t1059.007
logsource:
    category: file_event
    product: windows
detection:
    selection:
        - TargetFilename|contains|all:
              - '\AppData\Roaming\Oracle\bin\java'
              - '.exe'
        - TargetFilename|contains|all:
              - '\Retrive'
              - '.vbs'
    condition: selection
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    - TargetFilename|contains|all:
          - '\AppData\Roaming\Oracle\bin\java'
          - '.exe'
    - TargetFilename|contains|all:
          - '\Retrive'
          - '.vbs'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
TargetFilenamematch
  • .exe corpus 2 (sigma 2)
  • .vbs
  • \AppData\Roaming\Oracle\bin\java
  • \Retrive
field:"TargetFilename" kind:match

BitLocker feature configuration (Reg via command)

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

Detects scenarios where an attacker configures BitLocker for ransomware purposes.

Known False Positives

  • Initial BitLocker configuration via GPO

MITRE ATT&CK Coverage

TacticTechniques
Impact

Telemetry Coverage

Rule Body

title: BitLocker feature configuration (Reg via command)
description: Detects scenarios where an attacker configures BitLocker for ransomware purposes.
references:
- https://thedfirreport.com/2021/11/15/exchange-exploit-leads-to-domain-wide-ransomware/
- https://admx.help/?Category=MDOP&Policy=Microsoft.Policies.BitLockerManagement::BMSOSDEncryptionPolicy
- https://www.bleepingcomputer.com/news/microsoft/microsoft-iranian-hackers-encrypt-windows-systems-using-bitlocker/
tags:
- attack.impact
- attack.t1486
author: mdecrevoisier
status: experimental
logsource:
  product: windows
  category: process_creation
detection:
  selection:
    NewProcessName|endswith: \reg.exe
    CommandLine|contains|all: # Full command: "REG  ADD HKLM\SOFTWARE\Policies\Microsoft\FVE /v EnableBDEWithNoTPM /t REG_DWORD /d 1 /f"
      - REG ADD
      - '\SOFTWARE\Policies\Microsoft\FVE'
    CommandLine|contains:
      - UseTPM
      - UseTPMKey
      - UseTPMPIN
      - UseTPMKeyPIN
      - RecoveryKeyMessage
      - EnableBDEWithNoTPM
      - UseAdvancedStartup
      - RecoveryKeyMessageSource
  condition: selection
falsepositives:
- Initial BitLocker configuration via GPO
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
  NewProcessName|endswith: \reg.exe
  CommandLine|contains|all:
    - REG ADD
    - '\SOFTWARE\Policies\Microsoft\FVE'
  CommandLine|contains:
    - UseTPM
    - UseTPMKey
    - UseTPMPIN
    - UseTPMKeyPIN
    - RecoveryKeyMessage
    - EnableBDEWithNoTPM
    - UseAdvancedStartup
    - RecoveryKeyMessageSource

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • EnableBDEWithNoTPM corpus 2 (sigma 2)
  • REG ADD corpus 13 (sigma 13)
  • RecoveryKeyMessage corpus 2 (sigma 2)
  • RecoveryKeyMessageSource corpus 2 (sigma 2)
  • UseAdvancedStartup corpus 2 (sigma 2)
  • UseTPM corpus 2 (sigma 2)
  • UseTPMKey corpus 2 (sigma 2)
  • UseTPMKeyPIN corpus 2 (sigma 2)
  • UseTPMPIN corpus 2 (sigma 2)
  • \SOFTWARE\Policies\Microsoft\FVE corpus 2 (sigma 2)
field:"CommandLine" kind:match
NewProcessNameends_with
  • \reg.exe corpus 58 (sigma 58)
field:"Image" kind:ends_with value:"\reg.exe"

Cisco Sniffing

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

Show when a monitor or a span/rspan is setup or modified

Known False Positives

  • Admins may setup new or modify old spans, or use a monitor for troubleshooting

MITRE ATT&CK Coverage

TacticTechniques
Credential Access
Discovery

Rule Body

title: Cisco Sniffing
id: b9e1f193-d236-4451-aaae-2f3d2102120d
status: test
description: Show when a monitor or a span/rspan is setup or modified
author: Austin Clark
date: 2019-08-11
modified: 2023-01-04
tags:
    - attack.credential-access
    - attack.discovery
    - attack.t1040
logsource:
    product: cisco
    service: aaa
detection:
    keywords:
        - 'monitor capture point'
        - 'set span'
        - 'set rspan'
    condition: keywords
falsepositives:
    - Admins may setup new or modify old spans, or use a monitor for troubleshooting
level: medium

Stages and Predicates

Stage 0: condition

keywords

Stage 1: keywords

keywords:
    - 'monitor capture point'
    - 'set span'
    - 'set rspan'

Curl.EXE Execution With Custom UserAgent

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

Detects execution of curl.exe with custom useragent options

Known False Positives

  • Scripts created by developers and admins
  • Administrative activity

MITRE ATT&CK Coverage

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 1: Process creation

Rule Body

title: Curl.EXE Execution With Custom UserAgent
id: 3286d37a-00fd-41c2-a624-a672dcd34e60
status: test
description: Detects execution of curl.exe with custom useragent options
references:
    - https://curl.se/docs/manpage.html
    - https://github.com/redcanaryco/atomic-red-team/blob/f339e7da7d05f6057fdfcdd3742bfcf365fee2a9/atomics/T1071.001/T1071.001.md#atomic-test-2---malicious-user-agents---cmd
author: frack113
date: 2022-01-23
modified: 2023-02-21
tags:
    - attack.command-and-control
    - attack.t1071.001
    - detection.threat-hunting
logsource:
    category: process_creation
    product: windows
detection:
    selection_curl:
        - Image|endswith: '\curl.exe'
        - Product: 'The curl executable'
    selection_opt:
        CommandLine|contains:
            - ' -A '
            - ' --user-agent '
    condition: all of selection_*
falsepositives:
    - Scripts created by developers and admins
    - Administrative activity
level: medium
regression_tests_path: regression_data/rules-threat-hunting/windows/process_creation/proc_creation_win_curl_useragent/info.yml

Stages and Predicates

Stage 0: condition

all of selection_*

Stage 1: selection_curl

selection_curl:
    - Image|endswith: '\curl.exe'
    - Product: 'The curl executable'

Stage 2: selection_opt

selection_opt:
    CommandLine|contains:
        - ' -A '
        - ' --user-agent '

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • --user-agent corpus 2 (sigma 2)
  • -A corpus 5 (sigma 5)
field:"CommandLine" kind:match
Imageends_with
  • \curl.exe corpus 31 (sigma 31)
field:"Image" kind:ends_with value:"\curl.exe"
Producteq
  • The curl executable corpus 5 (sigma 5)
field:"Product" kind:eq value:"The curl executable"

Defrag Deactivation - Security

#
Status
test
Severity
medium
Author
Florian Roth (Nextron Systems), Bartlomiej Czyz (@bczyz1)
Source
github.com/SigmaHQ/sigma

Detects the deactivation and disabling of the Scheduled defragmentation task as seen by Slingshot APT group

MITRE ATT&CK Coverage

TacticTechniques
Execution
Persistence
Privilege Escalation

Telemetry Coverage

Rule Body

title: Defrag Deactivation - Security
id: c5a178bf-9cfb-4340-b584-e4df39b6a3e7
related:
    - id: 958d81aa-8566-4cea-a565-59ccd4df27b0
      type: derived
status: test
description: Detects the deactivation and disabling of the Scheduled defragmentation task as seen by Slingshot APT group
references:
    - https://securelist.com/apt-slingshot/84312/
author: Florian Roth (Nextron Systems), Bartlomiej Czyz (@bczyz1)
date: 2019-03-04
modified: 2022-11-27
tags:
    - attack.privilege-escalation
    - attack.execution
    - attack.persistence
    - attack.t1053
    - attack.s0111
    - detection.emerging-threats
logsource:
    product: windows
    service: security
    definition: 'Requirements: Audit Policy : Audit Other Object Access Events > Success'
detection:
    selection:
        EventID: 4701
        TaskName: '\Microsoft\Windows\Defrag\ScheduledDefrag'
    condition: selection
falsepositives:
    - Unknown
level: medium

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    EventID: 4701
    TaskName: '\Microsoft\Windows\Defrag\ScheduledDefrag'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
TaskNameeq
  • \Microsoft\Windows\Defrag\ScheduledDefrag
field:"TaskName" kind:eq value:"\Microsoft\Windows\Defrag\ScheduledDefrag"

Diamond Sleet APT Scheduled Task Creation - Registry

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

Detects registry event related to the creation of a scheduled task used by Diamond Sleet APT during exploitation of Team City CVE-2023-42793 vulnerability

MITRE ATT&CK Coverage

TacticTechniques
Defense Impairment

Telemetry Coverage

Rule Body

title: Diamond Sleet APT Scheduled Task Creation - Registry
id: 9f9f92ba-5300-43a4-b435-87d1ee571688
status: test
description: |
    Detects registry event related to the creation of a scheduled task used by Diamond Sleet APT during exploitation of Team City CVE-2023-42793 vulnerability
references:
    - https://www.microsoft.com/en-us/security/blog/2023/10/18/multiple-north-korean-threat-actors-exploiting-the-teamcity-cve-2023-42793-vulnerability/
author: Nasreddine Bencherchali (Nextron Systems)
date: 2023-10-24
tags:
    - attack.defense-impairment
    - attack.t1685
    - detection.emerging-threats
logsource:
    product: windows
    category: registry_event
detection:
    selection:
        TargetObject|contains|all:
            - '\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Schedule\TaskCache\Tree\'
            - 'Windows TeamCity Settings User Interface'
    condition: selection
falsepositives:
    - Unknown
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    TargetObject|contains|all:
        - '\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Schedule\TaskCache\Tree\'
        - 'Windows TeamCity Settings User Interface'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
TargetObjectmatch
  • Windows TeamCity Settings User Interface
  • \SOFTWARE\Microsoft\Windows NT\CurrentVersion\Schedule\TaskCache\Tree\ corpus 4 (sigma 4)
field:"TargetObject" kind:match

DLL Sideloading by VMware Xfer Utility

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

Detects execution of VMware Xfer utility (VMwareXferlogs.exe) from the non-default directory which may be an attempt to sideload arbitrary DLL

Known False Positives

  • Unlikely

MITRE ATT&CK Coverage

Telemetry Coverage

Rule Body

title: DLL Sideloading by VMware Xfer Utility
id: ebea773c-a8f1-42ad-a856-00cb221966e8
status: test
description: Detects execution of VMware Xfer utility (VMwareXferlogs.exe) from the non-default directory which may be an attempt to sideload arbitrary DLL
references:
    - https://www.sentinelone.com/labs/lockbit-ransomware-side-loads-cobalt-strike-beacon-with-legitimate-vmware-utility/
author: Nasreddine Bencherchali (Nextron Systems)
date: 2022-08-02
tags:
    - attack.privilege-escalation
    - attack.persistence
    - attack.execution
    - attack.stealth
    - attack.t1574.001
logsource:
    product: windows
    category: process_creation
detection:
    selection:
        Image|endswith: '\VMwareXferlogs.exe'
    filter: # VMware might be installed in another path so update the rule accordingly
        Image|startswith: 'C:\Program Files\VMware\'
    condition: selection and not filter
falsepositives:
    - Unlikely
level: high

Stages and Predicates

Stage 0: condition

selection and not filter

Stage 1: selection

selection:
    Image|endswith: '\VMwareXferlogs.exe'

Stage 2: not filter

filter:
    Image|startswith: 'C:\Program Files\VMware\'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
Imageends_with
  • \VMwareXferlogs.exe corpus 2 (sigma 2)
field:"Image" kind:ends_with value:"\VMwareXferlogs.exe"

Exclusions

The rule actively suppresses these predicates.

FieldKindExcluded valuesSearch
Imagestarts_withC:\Program Files\VMware\excludes:Image field:"Image" value:"C:\Program Files\VMware\"

DNS TXT Answer with Possible Execution Strings

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

Detects strings used in command execution in DNS TXT Answer

MITRE ATT&CK Coverage

TacticTechniques
Command & Control

Rule Body

title: DNS TXT Answer with Possible Execution Strings
id: 8ae51330-899c-4641-8125-e39f2e07da72
status: test
description: Detects strings used in command execution in DNS TXT Answer
references:
    - https://twitter.com/stvemillertime/status/1024707932447854592
    - https://github.com/samratashok/nishang/blob/414ee1104526d7057f9adaeee196d91ae447283e/Backdoors/DNS_TXT_Pwnage.ps1
author: Markus Neis
date: 2018-08-08
modified: 2021-11-27
tags:
    - attack.command-and-control
    - attack.t1071.004
logsource:
    category: dns
detection:
    selection:
        record_type: 'TXT'
        answer|contains:
            - 'IEX'
            - 'Invoke-Expression'
            - 'cmd.exe'
    condition: selection
falsepositives:
    - Unknown
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    record_type: 'TXT'
    answer|contains:
        - 'IEX'
        - 'Invoke-Expression'
        - 'cmd.exe'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
answermatch
  • IEX
  • Invoke-Expression
  • cmd.exe
field:"answer" kind:match
record_typeeq
  • TXT
field:"record_type" kind:eq value:"TXT"

DoT (DNS over TLS) activation (command)

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

Detects scenarios where an attacker attempts to enable DNS over TLS in order to evade detection for command and control purposes.

Known False Positives

  • Legitimate DoT activation by administrators

MITRE ATT&CK Coverage

TacticTechniques
Command & Control

Telemetry Coverage

Rule Body

title: DoT (DNS over TLS) activation (command)
description: Detects scenarios where an attacker attempts to enable DNS over TLS in order to evade detection for command and control purposes.
references:
- https://techcommunity.microsoft.com/t5/networking-blog/dns-over-tls-available-to-windows-insiders/ba-p/3565859
- http://woshub.com/enable-dns-over-https-windows/
tags:
- attack.defense_evasion
- attack.command_and_control
- attack.t1071.004 
author: mdecrevoisier
status: stable
logsource:
  product: windows
  category: process_creation
detection:
  selection_baseline:
    EventID: 4688
    NewProcessName|endswith: '\netsh.exe' # Full path "C:\Windows\system32\netsh.exe"
    CommandLine|contains: add

  selection_enable: # full command: "netsh dns add global dot=yes"
    CommandLine|contains: 'dot=yes'

  selection_add_server: # full command: "netsh dns add encryption server=<resolver_ip> dothost=: autoupgrade=yes"
    CommandLine|contains: 'dothost='

  condition: selection_baseline and (selection_enable OR selection_add_server)
falsepositives:
- Legitimate DoT activation by administrators 
level: medium

Stages and Predicates

Stage 0: condition

selection_baseline and (selection_enable OR selection_add_server)

Stage 1: selection_baseline

selection_baseline:
  EventID: 4688
  NewProcessName|endswith: '\netsh.exe'
  CommandLine|contains: add

Stage 2: selection_enable

selection_enable:
  CommandLine|contains: 'dot=yes'

Stage 3: selection_add_server

selection_add_server:
  CommandLine|contains: 'dothost='

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • add corpus 30 (sigma 26, splunk 4)
  • dot=yes
  • dothost=
field:"CommandLine" kind:match
NewProcessNameends_with
  • \netsh.exe corpus 28 (sigma 28)
field:"Image" kind:ends_with value:"\netsh.exe"

Email Exifiltration Via Powershell

#
Status
test
Severity
high
Author
Nasreddine Bencherchali (Nextron Systems), Azure-Sentinel (idea)
Source
github.com/SigmaHQ/sigma

Detects email exfiltration via powershell cmdlets

MITRE ATT&CK Coverage

TacticTechniques
ExfiltrationNo specific technique

Telemetry Coverage

Rule Body

title: Email Exifiltration Via Powershell
id: 312d0384-401c-4b8b-abdf-685ffba9a332
status: test
description: Detects email exfiltration via powershell cmdlets
references:
    - https://www.microsoft.com/security/blog/2022/09/07/profiling-dev-0270-phosphorus-ransomware-operations/
    - https://github.com/Azure/Azure-Sentinel/blob/7e6aa438e254d468feec061618a7877aa528ee9f/Hunting%20Queries/Microsoft%20365%20Defender/Ransomware/DEV-0270/Email%20data%20exfiltration%20via%20PowerShell.yaml
author: Nasreddine Bencherchali (Nextron Systems),  Azure-Sentinel (idea)
date: 2022-09-09
tags:
    - attack.exfiltration
logsource:
    category: process_creation
    product: windows
detection:
    selection:
        Image|endswith:
            - '\powershell.exe'
            - '\pwsh.exe'
        CommandLine|contains|all:
            - 'Add-PSSnapin'
            - 'Get-Recipient'
            - '-ExpandProperty'
            - 'EmailAddresses'
            - 'SmtpAddress'
            - '-hidetableheaders'
    condition: selection
falsepositives:
    - Unknown
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    Image|endswith:
        - '\powershell.exe'
        - '\pwsh.exe'
    CommandLine|contains|all:
        - 'Add-PSSnapin'
        - 'Get-Recipient'
        - '-ExpandProperty'
        - 'EmailAddresses'
        - 'SmtpAddress'
        - '-hidetableheaders'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • -ExpandProperty
  • -hidetableheaders
  • Add-PSSnapin corpus 2 (sigma 2)
  • EmailAddresses
  • Get-Recipient
  • SmtpAddress
field:"CommandLine" kind:match
Imageends_with
  • \powershell.exe corpus 181 (sigma 180, splunk 1)
  • \pwsh.exe corpus 166 (sigma 166)
field:"Image" kind:ends_with

Firewall rule any/any created

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

Detects scenarios where a firewall rule any/any is added to allow any incoming or outgoing traffic.

Known False Positives

  • Firewall rule debugging

MITRE ATT&CK Coverage

Telemetry Coverage

Rule Body

title: Firewall rule any/any created
description: Detects scenarios where a firewall rule any/any is added to allow any incoming or outgoing traffic.
references:
- https://github.com/mdecrevoisier/EVTX-to-MITRE-Attack/tree/master/TA0005-Defense%20Evasion/T1562.004-Impair%20Defenses-Disable%20or%20Modify%20System%20Firewall
- https://kb.eventtracker.com/evtpass/evtPages/EventId_2004_Microsoft-Windows-WindowsFirewallwithAdvancedS_65673.asp
tags:
- attack.defense_evasion
- attack.t1562.004
author: mdecrevoisier
status: experimental
logsource:
  product: windows
  service: firewall-as
detection:
  selection_basic:
    EventID:
      - 2004  # new rule created
      - 2005  # existing rule modified
    Action: 3 # allow

  selection_any_port:
    LocalPorts: '*'
    RemotePorts: '*'

  selection_any_address:
    LocalAddresses: '*' 
    RemoteAddresses: '*'

  condition: selection_basic and (selection_any_port or selection_any_address)
falsepositives:
- Firewall rule debugging
level: high

Stages and Predicates

Stage 0: condition

selection_basic and (selection_any_port or selection_any_address)

Stage 1: selection_basic

selection_basic:
  EventID:
    - 2004
    - 2005
  Action: 3

Stage 2: selection_any_port

selection_any_port:
  LocalPorts: '*'
  RemotePorts: '*'

Stage 3: selection_any_address

selection_any_address:
  LocalAddresses: '*'
  RemoteAddresses: '*'

Indicators

These rows show field, operator, and value matches.

HackTool - PowerTool Execution

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

Detects the execution of the tool PowerTool which has the ability to kill a process, delete its process file, unload drivers, and delete the driver files

Known False Positives

  • Unlikely

MITRE ATT&CK Coverage

TacticTechniques
Defense Impairment

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 1: Process creation

Rule Body

title: HackTool - PowerTool Execution
id: a34f79a3-8e5f-4cc3-b765-de00695452c2
status: test
description: Detects the execution of the tool PowerTool which has the ability to kill a process, delete its process file, unload drivers, and delete the driver files
references:
    - https://thedfirreport.com/2022/11/28/emotet-strikes-again-lnk-file-leads-to-domain-wide-ransomware/
    - https://www.trendmicro.com/en_us/research/22/i/play-ransomware-s-attack-playbook-unmasks-it-as-another-hive-aff.html
    - https://twitter.com/gbti_sa/status/1249653895900602375?lang=en
    - https://www.softpedia.com/get/Antivirus/Removal-Tools/ithurricane-PowerTool.shtml
author: Nasreddine Bencherchali (Nextron Systems)
date: 2022-11-29
modified: 2023-02-04
tags:
    - attack.defense-impairment
    - attack.t1685
logsource:
    product: windows
    category: process_creation
detection:
    selection:
        - Image|endswith:
              - '\PowerTool.exe'
              - '\PowerTool64.exe'
        - OriginalFileName: 'PowerTool.exe'
    condition: selection
falsepositives:
    - Unlikely
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    - Image|endswith:
          - '\PowerTool.exe'
          - '\PowerTool64.exe'
    - OriginalFileName: 'PowerTool.exe'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
Imageends_with
  • \PowerTool.exe
  • \PowerTool64.exe
field:"Image" kind:ends_with
OriginalFileNameeq
  • PowerTool.exe
field:"OriginalFileName" kind:eq value:"PowerTool.exe"

Interactive privileged shell triggered by schedule task (deprecated)

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

Detects scenarios where an attacker abuse the at command to elevate privilages. Note that at command is deprecated since Windows 8 and replaced by schtask.

Known False Positives

  • None

MITRE ATT&CK Coverage

Telemetry Coverage

Rule Body

title: Interactive privileged shell triggered by schedule task (deprecated)
description: Detects scenarios where an attacker abuse the at command to elevate privilages. Note that at command is deprecated since Windows 8 and replaced by schtask.
references:
- https://github.com/mdecrevoisier/EVTX-to-MITRE-Attack/tree/master/TA0002-Execution/T1053.005-Scheduled%20Task
- https://docs.microsoft.com/en-us/troubleshoot/windows-client/system-management-components/use-at-command-to-schedule-tasks
- https://strontic.github.io/xcyclopedia/library/at.exe-5FD22B915C232378E567160D641CC9F2.html
- https://blog.menasec.net/2019/03/threat-hunting-25-scheduled-tasks-for.html
- https://blogs.jpcert.or.jp/en/2016/01/windows-commands-abused-by-attackers.html
- https://www.linkedin.com/pulse/lolbin-attacks-scheduled-tasks-t1503005-how-detect-them-v%C3%B6gele
tags:
- attack.execution
- attack.t1053.005
author: mdecrevoisier
status: experimental
logsource:
  product: windows
  category: process_creation
detection:
  selection:
    EventID: 4688
    NewProcessName|endswith: \cmd.exe
    CommandLine|contains|all:
      - at
      - interactive
      - cmd
  condition: selection
falsepositives:
- None
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
  EventID: 4688
  NewProcessName|endswith: \cmd.exe
  CommandLine|contains|all:
    - at
    - interactive
    - cmd

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • at
  • cmd corpus 8 (sigma 8)
  • interactive corpus 3 (sigma 3)
field:"CommandLine" kind:match
NewProcessNameends_with
  • \cmd.exe corpus 132 (sigma 130, splunk 2)
field:"Image" kind:ends_with value:"\cmd.exe"

Kerberos Manipulation

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

Detects failed Kerberos TGT issue operation. This can be a sign of manipulations of TGT messages by an attacker.

Known False Positives

  • Faulty legacy applications

MITRE ATT&CK Coverage

TacticTechniques
Credential Access

Telemetry Coverage

Rule Body

title: Kerberos Manipulation
id: f7644214-0eb0-4ace-9455-331ec4c09253
status: test
description: Detects failed Kerberos TGT issue operation. This can be a sign of manipulations of TGT messages by an attacker.
references:
    - https://learn.microsoft.com/en-us/previous-versions/windows/it-pro/windows-10/security/threat-protection/auditing/event-4771
author: Florian Roth (Nextron Systems)
date: 2017-02-10
modified: 2024-01-16
tags:
    - attack.credential-access
    - attack.t1212
logsource:
    product: windows
    service: security
detection:
    selection:
        EventID:
            - 675
            - 4768
            - 4769
            - 4771
        Status:
            - '0x9'
            - '0xA'
            - '0xB'
            - '0xF'
            - '0x10'
            - '0x11'
            - '0x13'
            - '0x14'
            - '0x1A'
            - '0x1F'
            - '0x21'
            - '0x22'
            - '0x23'
            - '0x24'
            - '0x26'
            - '0x27'
            - '0x28'
            - '0x29'
            - '0x2C'
            - '0x2D'
            - '0x2E'
            - '0x2F'
            - '0x31'
            - '0x32'
            - '0x3E'
            - '0x3F'
            - '0x40'
            - '0x41'
            - '0x43'
            - '0x44'
    condition: selection
falsepositives:
    - Faulty legacy applications
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    EventID:
        - 675
        - 4768
        - 4769
        - 4771
    Status:
        - '0x9'
        - '0xA'
        - '0xB'
        - '0xF'
        - '0x10'
        - '0x11'
        - '0x13'
        - '0x14'
        - '0x1A'
        - '0x1F'
        - '0x21'
        - '0x22'
        - '0x23'
        - '0x24'
        - '0x26'
        - '0x27'
        - '0x28'
        - '0x29'
        - '0x2C'
        - '0x2D'
        - '0x2E'
        - '0x2F'
        - '0x31'
        - '0x32'
        - '0x3E'
        - '0x3F'
        - '0x40'
        - '0x41'
        - '0x43'
        - '0x44'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
Statuseq
  • 0x10
  • 0x11
  • 0x13
  • 0x14
  • 0x1A
  • 0x1F
  • 0x21
  • 0x22
  • 0x23
  • 0x24
  • 0x26
  • 0x27
  • 0x28
  • 0x29
  • 0x2C
  • 0x2D
  • 0x2E
  • 0x2F
  • 0x31
  • 0x32
  • 0x3E
  • 0x3F
  • 0x40
  • 0x41
  • 0x43
  • 0x44
  • 0x9
  • 0xA
  • 0xB
  • 0xF
field:"Status" kind:eq

Local group membership change

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

Detects if a member is added to a local group via PowerShell.

Known False Positives

  • Pentest
  • Administrator activity
  • Splunk UF agent installation

MITRE ATT&CK Coverage

TacticTechniques
Persistence

Telemetry Coverage

Rule Body

title: Local group membership change
description: Detects if a member is added to a local group via PowerShell.
references:
- 
tags:
- attack.persistence
- attack.t1098 # account manipulation
author: mdecrevoisier
status: experimental
logsource:
  product: windows
  category:
    - ps_module
    - ps_classic_script
    - ps_script
detection: # Add-LocalGroupMember -Group "Administrators" -Member "Admin02",
  selection1_powershell_native:
    EventID: 800
    EventData|contains|all:
      - 'Add-LocalGroupMember'
      - '-Group'
      - '-Member'

  selection2_powershell_modern:
    EventID: 4103
      - 'Add-LocalGroupMember'
      - '-Group'
      - '-Member'
  
  selection3_powershell_block:
    EventID: 4104
    ScriptBlockText|contains|all:
      - 'Add-LocalGroupMember'
      - '-Group'
      - '-Member'

  condition: 1 of selection*
falsepositives:
- Pentest
- Administrator activity
- Splunk UF agent installation
level: high

Stages and Predicates

Stage 0: condition

1 of selection*

Stage 1: selection1_powershell_native

selection1_powershell_native:
  EventID: 800
  EventData|contains|all:
    - 'Add-LocalGroupMember'
    - '-Group'
    - '-Member'

Stage 2: selection2_powershell_modern

selection2_powershell_modern:
  EventID: 4103
    - 'Add-LocalGroupMember'
    - '-Group'
    - '-Member'

Stage 3: selection3_powershell_block

selection3_powershell_block:
  EventID: 4104
  ScriptBlockText|contains|all:
    - 'Add-LocalGroupMember'
    - '-Group'
    - '-Member'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
EventDatamatch
  • -Group
  • -Member
  • Add-LocalGroupMember
field:"EventData" kind:match
ScriptBlockTextmatch
  • -Group
  • -Member
  • Add-LocalGroupMember
field:"ScriptBlockText" kind:match

Microsoft 365 - Potential Ransomware Activity

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

Detects when a Microsoft Cloud App Security reported when a user uploads files to the cloud that might be infected with ransomware.

MITRE ATT&CK Coverage

TacticTechniques
Impact

Telemetry Coverage

Rule Body

title: Microsoft 365 - Potential Ransomware Activity
id: bd132164-884a-48f1-aa2d-c6d646b04c69
status: test
description: Detects when a Microsoft Cloud App Security reported when a user uploads files to the cloud that might be infected with ransomware.
references:
    - https://learn.microsoft.com/en-us/defender-cloud-apps/anomaly-detection-policy
    - https://learn.microsoft.com/en-us/defender-cloud-apps/policy-template-reference
author: austinsonger
date: 2021-08-19
modified: 2022-10-09
tags:
    - attack.impact
    - attack.t1486
logsource:
    service: threat_management
    product: m365
detection:
    selection:
        eventSource: SecurityComplianceCenter
        eventName: 'Potential ransomware activity'
        status: success
    condition: selection
falsepositives:
    - Unknown
level: medium

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    eventSource: SecurityComplianceCenter
    eventName: 'Potential ransomware activity'
    status: success

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
eventNameeq
  • Potential ransomware activity
field:"aws::eventName" kind:eq value:"Potential ransomware activity"
eventSourceeq
  • SecurityComplianceCenter corpus 14 (sigma 14)
field:"aws::eventSource" kind:eq value:"SecurityComplianceCenter"
statuseq
  • success corpus 21 (sigma 15, splunk 6)
field:"status" kind:eq value:"success"

Mimikatz driver deployed via service

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

Detects scenarios where an attacker installs the Mimikatz driver to bypass the LSA protected mode (RunAsPPL) and dump LSASS process content.

Known False Positives

  • None

MITRE ATT&CK Coverage

Telemetry Coverage

Rule Body

title: Mimikatz driver deployed via service
description: Detects scenarios where an attacker installs the Mimikatz driver to bypass the LSA protected mode (RunAsPPL) and dump LSASS process content.
references:
- https://github.com/mdecrevoisier/EVTX-to-MITRE-Attack/tree/master/TA0003-Persistence/T1543.003-Create%20or%20Modify%20System%20Process-Windows%20Service
- https://posts.specterops.io/mimidrv-in-depth-4d273d19e148?gi=a5033fbeb71d
- https://gorkemkaradeniz.medium.com/defeating-runasppl-utilizing-vulnerable-drivers-to-read-lsass-with-mimikatz-28f4b50b1de5
tags:
- attack.privilege_escalation
- attack.t1543.003
author: mdecrevoisier
status: experimental
logsource:
  product: windows
  service: 
    - system
    - security
detection:
  selection:
    EventID:
      - 4697 # SECURITY logs: new service
      - 7045 # SYSTEM logs: new service
    ServiceName|contains:
      - mimidrv
      - mimikatz
  condition: selection
falsepositives:
- None
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
  EventID:
    - 4697
    - 7045
  ServiceName|contains:
    - mimidrv
    - mimikatz

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
ServiceNamematch
  • mimidrv
  • mimikatz
field:"ServiceName" kind:match

Network Connection Initiated By Eqnedt32.EXE

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

Detects network connections from the Equation Editor process "eqnedt32.exe".

Known False Positives

  • Unlikely

MITRE ATT&CK Coverage

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 3: Network connection

Rule Body

title: Network Connection Initiated By Eqnedt32.EXE
id: a66bc059-c370-472c-a0d7-f8fd1bf9d583
status: test
description: Detects network connections from the Equation Editor process "eqnedt32.exe".
references:
    - https://twitter.com/forensicitguy/status/1513538712986079238
    - https://forensicitguy.github.io/xloader-formbook-velvetsweatshop-spreadsheet/
    - https://news.sophos.com/en-us/2019/07/18/a-new-equation-editor-exploit-goes-commercial-as-maldoc-attacks-using-it-spike/
author: Max Altgelt (Nextron Systems)
date: 2022-04-14
modified: 2024-05-31
tags:
    - attack.execution
    - attack.t1203
logsource:
    category: network_connection
    product: windows
detection:
    selection:
        Image|endswith: '\eqnedt32.exe'
    condition: selection
falsepositives:
    - Unlikely
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    Image|endswith: '\eqnedt32.exe'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
Imageends_with
  • \eqnedt32.exe corpus 6 (sigma 6)
field:"Image" kind:ends_with value:"\eqnedt32.exe"

New Network Route Added

#
Status
test
Severity
medium
Author
jamesc-grafana
Source
github.com/SigmaHQ/sigma

Detects the addition of a new network route to a route table in AWS.

Known False Positives

  • New VPC Creation requiring setup of a new route table
  • New subnets added requiring routing setup

MITRE ATT&CK Coverage

Telemetry Coverage

Rules Detecting the Same Action

These rules filter on the same operation.

Rule Body

title: New Network Route Added
id: c803b2ce-c4a2-4836-beae-b112010390b1
status: test
description: |
    Detects the addition of a new network route to a route table in AWS.
references:
    - https://www.gorillastack.com/blog/real-time-events/important-aws-cloudtrail-security-events-tracking/
author: jamesc-grafana
date: 2024-07-11
tags:
    - attack.defense-impairment
    - attack.t1686.001
logsource:
    product: aws
    service: cloudtrail
detection:
    selection:
        eventSource: 'ec2.amazonaws.com'
        eventName: 'CreateRoute'
    condition: selection
falsepositives:
    - New VPC Creation requiring setup of a new route table
    - New subnets added requiring routing setup
level: medium

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    eventSource: 'ec2.amazonaws.com'
    eventName: 'CreateRoute'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
eventNameeq
  • CreateRoute
field:"aws::eventName" kind:eq value:"CreateRoute"
eventSourceeq
  • ec2.amazonaws.com corpus 13 (sigma 10, panther 2, splunk 1)
field:"aws::eventSource" kind:eq value:"ec2.amazonaws.com"

OpenCanary - GIT Clone Request

#
Status
test
Severity
high
Author
Security Onion Solutions
Source
github.com/SigmaHQ/sigma

Detects instances where a GIT service on an OpenCanary node has had Git Clone request.

Known False Positives

  • Unlikely

MITRE ATT&CK Coverage

Rule Body

title: OpenCanary - GIT Clone Request
id: 4fe17521-aef3-4e6a-9d6b-4a7c8de155a8
status: test
description: Detects instances where a GIT service on an OpenCanary node has had Git Clone request.
references:
    - https://opencanary.readthedocs.io/en/latest/starting/configuration.html#services-configuration
    - https://github.com/thinkst/opencanary/blob/a0896adfcaf0328cfd5829fe10d2878c7445138e/opencanary/logger.py#L52
author: Security Onion Solutions
date: 2024-03-08
tags:
    - attack.collection
    - attack.t1213
logsource:
    category: application
    product: opencanary
detection:
    selection:
        logtype: 16001
    condition: selection
falsepositives:
    - Unlikely
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    logtype: 16001

Indicators

These rows show field, operator, and value matches.

OpenCanary - SSH New Connection Attempt

#
Status
test
Severity
high
Author
Security Onion Solutions
Source
github.com/SigmaHQ/sigma

Detects instances where an SSH service on an OpenCanary node has had a connection attempt.

Known False Positives

  • Unlikely

MITRE ATT&CK Coverage

Rule Body

title: OpenCanary - SSH New Connection Attempt
id: cd55f721-5623-4663-bd9b-5229cab5237d
status: test
description: Detects instances where an SSH service on an OpenCanary node has had a connection attempt.
references:
    - https://opencanary.readthedocs.io/en/latest/starting/configuration.html#services-configuration
    - https://github.com/thinkst/opencanary/blob/a0896adfcaf0328cfd5829fe10d2878c7445138e/opencanary/logger.py#L52
author: Security Onion Solutions
date: 2024-03-08
tags:
    - attack.privilege-escalation
    - attack.initial-access
    - attack.lateral-movement
    - attack.persistence
    - attack.stealth
    - attack.t1133
    - attack.t1021
    - attack.t1078
logsource:
    category: application
    product: opencanary
detection:
    selection:
        logtype: 4000
    condition: selection
falsepositives:
    - Unlikely
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    logtype: 4000

Indicators

These rows show field, operator, and value matches.

Password policy discovery via commandline

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

Detects scenarios where an attacker attempts to enumerate the password policy via commandline.

Known False Positives

  • Pentest

MITRE ATT&CK Coverage

TacticTechniques
Discovery

Telemetry Coverage

Rule Body

title: Password policy discovery via commandline
description: Detects scenarios where an attacker attempts to enumerate the password policy via commandline.
references:
- https://github.com/mdecrevoisier/EVTX-to-MITRE-Attack/tree/master/TA0007-Discovery/T1201-Password%20Policy%20Discovery
- https://blogs.jpcert.or.jp/en/2016/01/windows-commands-abused-by-attackers.html
- https://attack.mitre.org/software/S0039/
tags:
- attack.discovery
- attack.t1201
author: mdecrevoisier
logsource:
  product: windows
  category: process_creation
detection:
  selection: # Full command example: 'net accounts [/domain]'
    NewProcessName|endswith:
      - \net1.exe
      - \net.exe
    CommandLine|contains|all:
      - accounts
      - /do # refers to '/domain'
  condition: selection
falsepositives:
- Pentest
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
  NewProcessName|endswith:
    - \net1.exe
    - \net.exe
  CommandLine|contains|all:
    - accounts
    - /do

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • /do
  • accounts corpus 2 (sigma 1, splunk 1)
field:"CommandLine" kind:match
NewProcessNameends_with
  • \net.exe corpus 49 (sigma 49)
  • \net1.exe corpus 47 (sigma 47)
field:"Image" kind:ends_with

Potential Ursnif Malware Activity - Registry

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

Detects registry keys related to Ursnif malware.

MITRE ATT&CK Coverage

TacticTechniques
Persistence
Defense Impairment

Telemetry Coverage

Rule Body

title: Potential Ursnif Malware Activity - Registry
id: 21f17060-b282-4249-ade0-589ea3591558
status: test
description: Detects registry keys related to Ursnif malware.
references:
    - https://blog.yoroi.company/research/ursnif-long-live-the-steganography/
    - https://blog.trendmicro.com/trendlabs-security-intelligence/phishing-campaign-uses-hijacked-emails-to-deliver-ursnif-by-replying-to-ongoing-threads/
author: megan201296
date: 2019-02-13
modified: 2025-10-22
tags:
    - attack.persistence
    - attack.execution
    - attack.defense-impairment
    - attack.t1112
    - detection.emerging-threats
logsource:
    product: windows
    category: registry_add
detection:
    selection:
        TargetObject|endswith: '\Software\AppDataLow\Software\Microsoft\3A861D62-51E0-7C9D-AB0E-15700F2219A4'
    condition: selection
falsepositives:
    - Unknown
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    TargetObject|endswith: '\Software\AppDataLow\Software\Microsoft\3A861D62-51E0-7C9D-AB0E-15700F2219A4'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
TargetObjectends_with
  • \Software\AppDataLow\Software\Microsoft\3A861D62-51E0-7C9D-AB0E-15700F2219A4
field:"TargetObject" kind:ends_with value:"\Software\AppDataLow\Software\Microsoft\3A861D62-51E0-7C9D-AB0E-15700F2219A4"

Potentially Suspicious Malware Callback Communication - Linux

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

Detects programs that connect to known malware callback ports based on threat intelligence reports.

MITRE ATT&CK Coverage

TacticTechniques
Command & Control

Telemetry Coverage

PlatformRecord / event type
LinuxEvent ID 3: Network connection

Rule Body

title: Potentially Suspicious Malware Callback Communication - Linux
id: dbfc7c98-04ab-4ab7-aa94-c74d22aa7376
related:
    - id: 4b89abaa-99fe-4232-afdd-8f9aa4d20382
      type: derived
status: test
description: |
    Detects programs that connect to known malware callback ports based on threat intelligence reports.
references:
    - https://www.mandiant.com/resources/blog/triton-actor-ttp-profile-custom-attack-tools-detections
    - https://www.mandiant.com/resources/blog/ukraine-and-sandworm-team
    - https://www.elastic.co/guide/en/security/current/potential-non-standard-port-ssh-connection.html
    - https://thehackernews.com/2024/01/systembc-malwares-c2-server-analysis.html
    - https://www.cybereason.com/blog/sliver-c2-leveraged-by-many-threat-actors
author: hasselj
date: 2024-05-10
tags:
    - attack.persistence
    - attack.command-and-control
    - attack.t1571
logsource:
    category: network_connection
    product: linux
detection:
    selection:
        Initiated: 'true'
        DestinationPort:
            - 888
            - 999
            - 2200
            - 2222
            - 4000
            - 4444
            - 6789
            - 8531
            - 50501
            - 51820
    filter_main_local_ranges:
        DestinationIp|cidr:
            - '127.0.0.0/8'
            - '10.0.0.0/8'
            - '172.16.0.0/12'
            - '192.168.0.0/16'
            - '169.254.0.0/16'
            - '::1/128'         # IPv6 loopback
            - 'fe80::/10'       # IPv6 link-local addresses
            - 'fc00::/7'        # IPv6 private addresses
    condition: selection and not 1 of filter_main_*
falsepositives:
    - Unknown
level: high

Stages and Predicates

Stage 0: condition

selection and not 1 of filter_main_*

Stage 1: selection

selection:
    Initiated: 'true'
    DestinationPort:
        - 888
        - 999
        - 2200
        - 2222
        - 4000
        - 4444
        - 6789
        - 8531
        - 50501
        - 51820

Stage 2: not filter_main_local_ranges

filter_main_local_ranges:
    DestinationIp|cidr:
        - '127.0.0.0/8'
        - '10.0.0.0/8'
        - '172.16.0.0/12'
        - '192.168.0.0/16'
        - '169.254.0.0/16'
        - '::1/128'
        - 'fe80::/10'
        - 'fc00::/7'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
DestinationPorteq
  • 2200
  • 2222
  • 4000
  • 4444 corpus 2 (sigma 2)
  • 50501
  • 51820
  • 6789
  • 8531
  • 888
  • 999
field:"DestinationPort" kind:eq
Initiatedeq
  • true corpus 50 (sigma 50)
field:"Initiated" kind:eq value:"true"

Exclusions

The rule actively suppresses these predicates.

PUA - Crassus Execution

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

Detects Crassus, a Windows privilege escalation discovery tool, based on PE metadata characteristics.

Known False Positives

  • Unlikely

MITRE ATT&CK Coverage

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 1: Process creation

Rule Body

title: PUA - Crassus Execution
id: 2c32b543-1058-4808-91c6-5b31b8bed6c5
status: test
description: Detects Crassus, a Windows privilege escalation discovery tool, based on PE metadata characteristics.
references:
    - https://github.com/vu-ls/Crassus
author: pH-T (Nextron Systems)
date: 2023-04-17
tags:
    - attack.discovery
    - attack.reconnaissance
    - attack.t1590.001
logsource:
    category: process_creation
    product: windows
detection:
    selection:
        - Image|endswith: '\Crassus.exe'
        - OriginalFileName: 'Crassus.exe'
        - Description|contains: 'Crassus'
    condition: selection
falsepositives:
    - Unlikely
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    - Image|endswith: '\Crassus.exe'
    - OriginalFileName: 'Crassus.exe'
    - Description|contains: 'Crassus'

Indicators

These rows show field, operator, and value matches.

Remote Registry Recon

#
Status
test
Severity
high
Author
Sagie Dulce, Dekel Paz
Source
github.com/SigmaHQ/sigma

Detects remote RPC calls to collect information

Known False Positives

  • Remote administration of registry values

MITRE ATT&CK Coverage

TacticTechniques
DiscoveryNo specific technique

Telemetry Coverage

Rule Body

title: Remote Registry Recon
id: d8ffe17e-04be-4886-beb9-c1dd1944b9a8
status: test
description: Detects remote RPC calls to collect information
references:
    - https://learn.microsoft.com/en-us/openspecs/windows_protocols/ms-rrp/0fa3191d-bb79-490a-81bd-54c2601b7a78
    - https://github.com/jsecurity101/MSRPC-to-ATTACK/blob/ddd4608fe8684fcf2fcf9b48c5f0b3c28097f8a3/documents/MS-RRP.md
    - https://github.com/zeronetworks/rpcfirewall
    - https://zeronetworks.com/blog/stopping-lateral-movement-via-the-rpc-firewall/
author: Sagie Dulce, Dekel Paz
date: 2022-01-01
tags:
    - attack.discovery
logsource:
    product: rpc_firewall
    category: application
    definition: 'Requirements: install and apply the RPC Firewall to all processes with "audit:true action:block uuid:338cd001-2244-31f1-aaaa-900038001003"'
detection:
    selection:
        EventLog: RPCFW
        EventID: 3
        InterfaceUuid: 338cd001-2244-31f1-aaaa-900038001003
    filter:
        OpNum:
            - 6
            - 7
            - 8
            - 13
            - 18
            - 19
            - 21
            - 22
            - 23
            - 35
    condition: selection and not filter
falsepositives:
    - Remote administration of registry values
level: high

Stages and Predicates

Stage 0: condition

selection and not filter

Stage 1: selection

selection:
    EventLog: RPCFW
    EventID: 3
    InterfaceUuid: 338cd001-2244-31f1-aaaa-900038001003

Stage 2: not filter

filter:
    OpNum:
        - 6
        - 7
        - 8
        - 13
        - 18
        - 19
        - 21
        - 22
        - 23
        - 35

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
EventLogeq
  • RPCFW corpus 17 (sigma 17)
field:"EventLog" kind:eq value:"RPCFW"
InterfaceUuideq
  • 338cd001-2244-31f1-aaaa-900038001003 corpus 2 (sigma 2)
field:"InterfaceUuid" kind:eq value:"338cd001-2244-31f1-aaaa-900038001003"

Exclusions

The rule actively suppresses these predicates.

Shell Execution via Nice - Linux

#
Status
test
Severity
high
Author
Li Ling, Andy Parkidomo, Robert Rakowski, Blake Hartstein (Bloomberg L.P.)
Source
github.com/SigmaHQ/sigma

Detects the use of the "nice" utility to execute a shell. Such behavior may be associated with privilege escalation, unauthorized command execution, or to break out from restricted environments.

MITRE ATT&CK Coverage

TacticTechniques
Discovery

Telemetry Coverage

PlatformRecord / event type
LinuxEvent ID 1: Process Create

Rule Body

title: Shell Execution via Nice - Linux
id: 093d68c7-762a-42f4-9f46-95e79142571a
status: test
description: |
    Detects the use of the "nice" utility to execute a shell. Such behavior may be associated with privilege escalation, unauthorized command execution, or to break out from restricted environments.
references:
    - https://gtfobins.github.io/gtfobins/nice/#shell
    - https://www.elastic.co/guide/en/security/current/linux-restricted-shell-breakout-via-linux-binary-s.html
author: Li Ling, Andy Parkidomo, Robert Rakowski, Blake Hartstein (Bloomberg L.P.)
date: 2024-09-02
tags:
    - attack.discovery
    - attack.t1083
logsource:
    category: process_creation
    product: linux
detection:
    selection:
        Image|endswith: '/nice'
        CommandLine|endswith:
            - '/bin/bash'
            - '/bin/dash'
            - '/bin/fish'
            - '/bin/sh'
            - '/bin/zsh'
    condition: selection
falsepositives:
    - Unknown
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    Image|endswith: '/nice'
    CommandLine|endswith:
        - '/bin/bash'
        - '/bin/dash'
        - '/bin/fish'
        - '/bin/sh'
        - '/bin/zsh'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLineends_with
  • /bin/bash
  • /bin/dash
  • /bin/fish
  • /bin/sh
  • /bin/zsh
field:"CommandLine" kind:ends_with
Imageends_with
  • /nice
field:"Image" kind:ends_with value:"/nice"

Suspicious Executable File Creation

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

Detect creation of suspicious executable file names. Some strings look for suspicious file extensions, others look for filenames that exploit unquoted service paths.

MITRE ATT&CK Coverage

TacticTechniques
Stealth

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 11: FileCreate

Rule Body

title: Suspicious Executable File Creation
id: 74babdd6-a758-4549-9632-26535279e654
status: test
description: |
    Detect creation of suspicious executable file names.
    Some strings look for suspicious file extensions, others look for filenames that exploit unquoted service paths.
references:
    - https://medium.com/@SumitVerma101/windows-privilege-escalation-part-1-unquoted-service-path-c7a011a8d8ae
    - https://app.any.run/tasks/76c69e2d-01e8-49d9-9aea-fb7cc0c4d3ad/
author: frack113
date: 2022-09-05
modified: 2023-12-11
tags:
    - attack.stealth
    - attack.t1564
logsource:
    product: windows
    category: file_event
detection:
    selection:
        TargetFilename|endswith:
            - ':\$Recycle.Bin.exe'
            - ':\Documents and Settings.exe'
            - ':\MSOCache.exe'
            - ':\PerfLogs.exe'
            - ':\Recovery.exe'
            - '.bat.exe'
            - '.sys.exe'
    condition: selection
falsepositives:
    - Unknown
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    TargetFilename|endswith:
        - ':\$Recycle.Bin.exe'
        - ':\Documents and Settings.exe'
        - ':\MSOCache.exe'
        - ':\PerfLogs.exe'
        - ':\Recovery.exe'
        - '.bat.exe'
        - '.sys.exe'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
TargetFilenameends_with
  • .bat.exe
  • .sys.exe
  • :\$Recycle.Bin.exe
  • :\Documents and Settings.exe
  • :\MSOCache.exe
  • :\PerfLogs.exe
  • :\Recovery.exe
field:"TargetFilename" kind:ends_with

Suspicious Response File Execution Via Odbcconf.EXE

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

Detects execution of "odbcconf" with the "-f" flag in order to load a response file with a non-".rsp" extension.

Known False Positives

  • Unlikely

MITRE ATT&CK Coverage

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 1: Process creation

Rule Body

title: Suspicious Response File Execution Via Odbcconf.EXE
id: 2d32dd6f-3196-4093-b9eb-1ad8ab088ca5
related:
    - id: 5f03babb-12db-4eec-8c82-7b4cb5580868
      type: derived
    - id: 65d2be45-8600-4042-b4c0-577a1ff8a60e
      type: obsolete
status: test
description: Detects execution of "odbcconf" with the "-f" flag in order to load a response file with a non-".rsp" extension.
references:
    - https://learn.microsoft.com/en-us/sql/odbc/odbcconf-exe?view=sql-server-ver16
    - https://lolbas-project.github.io/lolbas/Binaries/Odbcconf/
    - https://www.trendmicro.com/en_us/research/17/h/backdoor-carrying-emails-set-sights-on-russian-speaking-businesses.html
author: Nasreddine Bencherchali (Nextron Systems)
date: 2023-05-22
modified: 2024-03-13
tags:
    - attack.stealth
    - attack.t1218.008
logsource:
    category: process_creation
    product: windows
detection:
    selection_img:
        - Image|endswith: '\odbcconf.exe'
        - OriginalFileName: 'odbcconf.exe'
    selection_cli:
        CommandLine|contains|windash: ' -f '
    filter_main_rsp_ext:
        CommandLine|contains: '.rsp'
    filter_main_runonce_odbc:
        # When odbcconf is run with the "/R" flag, it creates a "runonce" key to run at the next reboot
        ParentImage: 'C:\Windows\System32\runonce.exe'
        Image: 'C:\Windows\System32\odbcconf.exe'
        CommandLine|contains: '.exe /E /F "C:\WINDOWS\system32\odbcconf.tmp"'
    condition: all of selection_* and not 1 of filter_main_*
falsepositives:
    - Unlikely
level: high

Stages and Predicates

Stage 0: condition

all of selection_* and not 1 of filter_main_*

Stage 1: selection_img

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

Stage 2: selection_cli

selection_cli:
    CommandLine|contains|windash: ' -f '

Stage 3: not filter_main_*

filter_main_rsp_ext:
    CommandLine|contains: '.rsp'
filter_main_runonce_odbc:
    ParentImage: 'C:\Windows\System32\runonce.exe'
    Image: 'C:\Windows\System32\odbcconf.exe'
    CommandLine|contains: '.exe /E /F "C:\WINDOWS\system32\odbcconf.tmp"'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • -f corpus 7 (sigma 7)
  • /f corpus 5 (sigma 5)
  • –f corpus 4 (sigma 4)
  • —f corpus 4 (sigma 4)
  • ―f corpus 4 (sigma 4)
field:"CommandLine" kind:match
Imageends_with
  • \odbcconf.exe corpus 11 (sigma 11)
field:"Image" kind:ends_with value:"\odbcconf.exe"
OriginalFileNameeq
  • odbcconf.exe corpus 11 (sigma 9, elastic 2)
field:"OriginalFileName" kind:eq value:"odbcconf.exe"

Exclusions

The rule actively suppresses these predicates.

FieldKindExcluded valuesSearch
CommandLinematch.exe /E /F "C:\WINDOWS\system32\odbcconf.tmp"excludes:CommandLine
ImageeqC:\Windows\System32\odbcconf.exeexcludes:Image field:"Image" value:"C:\Windows\System32\odbcconf.exe"
ParentImageeqC:\Windows\System32\runonce.exeexcludes:ParentImage field:"ParentImage" value:"C:\Windows\System32\runonce.exe"
CommandLinematch.rspexcludes:CommandLine field:"CommandLine" value:".rsp"

Suspicious Velociraptor Child Process

#
Status
experimental
Severity
high
Author
Swachchhanda Shrawan Poudel (Nextron Systems)
Source
github.com/SigmaHQ/sigma

Detects the suspicious use of the Velociraptor DFIR tool to execute other tools or download additional payloads, as seen in a campaign where it was abused for remote access and to stage further attacks.

Known False Positives

  • Legitimate administrators or incident responders might use Velociraptor to execute scripts or tools. However, the combination of Velociraptor spawning these specific processes with these command lines is suspicious. Tuning may be required to exclude known administrative actions or specific scripts.

MITRE ATT&CK Coverage

TacticTechniques
Command & Control

Telemetry Coverage

Rule Body

title: Suspicious Velociraptor Child Process
id: 4bc90587-e6ca-4b41-be0b-ed4d04e4ed0c
status: experimental
description: Detects the suspicious use of the Velociraptor DFIR tool to execute other tools or download additional payloads, as seen in a campaign where it was abused for remote access and to stage further attacks.
references:
    - https://news.sophos.com/en-us/2025/08/26/velociraptor-incident-response-tool-abused-for-remote-access/
author: Swachchhanda Shrawan Poudel (Nextron Systems)
date: 2025-08-29
tags:
    - attack.command-and-control
    - attack.persistence
    - attack.t1219
logsource:
    category: process_creation
    product: windows
detection:
    selection_parent:
        ParentImage|endswith: '\Velociraptor.exe'
    selection_child_vscode_tunnel:
        CommandLine|contains|all:
            - 'code.exe'
            - 'tunnel'
            - '--accept-server-license-terms'
    selection_child_msiexec:
        CommandLine|contains|all:
            - 'msiexec'
            - '/i'
            - 'http'
    selection_child_powershell:
        Image|endswith:
            - '\powershell.exe'
            - '\powershell_ise.exe'
            - '\pwsh.exe'
        CommandLine|contains:
            - 'Invoke-WebRequest '
            - 'IWR '
            - '.DownloadFile'
            - '.DownloadString'
    # Add more child process patterns as needed
    condition: selection_parent and 1 of selection_child_*
falsepositives:
    - Legitimate administrators or incident responders might use Velociraptor to execute scripts or tools. However, the combination of Velociraptor spawning these specific processes with these command lines is suspicious. Tuning may be required to exclude known administrative actions or specific scripts.
level: high

Stages and Predicates

Stage 0: condition

selection_parent and 1 of selection_child_*

Stage 1: selection_parent

selection_parent:
    ParentImage|endswith: '\Velociraptor.exe'

Stage 2: selection_child_vscode_tunnel

selection_child_vscode_tunnel:
    CommandLine|contains|all:
        - 'code.exe'
        - 'tunnel'
        - '--accept-server-license-terms'

Stage 3: selection_child_msiexec

selection_child_msiexec:
    CommandLine|contains|all:
        - 'msiexec'
        - '/i'
        - 'http'

Stage 4: selection_child_powershell

selection_child_powershell:
    Image|endswith:
        - '\powershell.exe'
        - '\powershell_ise.exe'
        - '\pwsh.exe'
    CommandLine|contains:
        - 'Invoke-WebRequest '
        - 'IWR '
        - '.DownloadFile'
        - '.DownloadString'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • --accept-server-license-terms corpus 3 (sigma 3)
  • .DownloadFile corpus 3 (sigma 2, elastic 1)
  • .DownloadString corpus 3 (sigma 2, elastic 1)
  • /i corpus 4 (sigma 4)
  • IWR corpus 11 (sigma 11)
  • Invoke-WebRequest corpus 4 (sigma 4)
  • code.exe
  • http corpus 45 (sigma 34, elastic 10, splunk 1)
  • msiexec corpus 5 (sigma 5)
  • tunnel corpus 6 (sigma 3, elastic 2, splunk 1)
field:"CommandLine" kind:match
Imageends_with
  • \powershell.exe corpus 181 (sigma 180, splunk 1)
  • \powershell_ise.exe corpus 41 (sigma 41)
  • \pwsh.exe corpus 166 (sigma 166)
field:"Image" kind:ends_with
ParentImageends_with
  • \Velociraptor.exe
field:"ParentImage" kind:ends_with value:"\Velociraptor.exe"

Tap Driver Installation - Security

#
Status
test
Severity
low
Author
Daniil Yugoslavskiy, Ian Davis, oscd.community
Source
github.com/SigmaHQ/sigma

Detects the installation of a well-known TAP driver service. This could be a sign of potential preparation for data exfiltration using tunnelling techniques.

Known False Positives

  • Legitimate OpenVPN TAP installation

MITRE ATT&CK Coverage

Telemetry Coverage

Rule Body

title: Tap Driver Installation - Security
id: 9c8afa4d-0022-48f0-9456-3712466f9701
related:
    - id: 8e4cf0e5-aa5d-4dc3-beff-dc26917744a9
      type: derived
status: test
description: |
    Detects the installation of a well-known TAP driver service. This could be a sign of potential preparation for data exfiltration using tunnelling techniques.
references:
    - https://community.openvpn.net/openvpn/wiki/ManagingWindowsTAPDrivers
author: Daniil Yugoslavskiy, Ian Davis, oscd.community
date: 2019-10-24
modified: 2022-11-29
tags:
    - attack.exfiltration
    - attack.t1048
logsource:
    product: windows
    service: security
    definition: 'Requirements: The System Security Extension audit subcategory need to be enabled to log the EID 4697'
detection:
    selection:
        EventID: 4697
        ServiceFileName|contains: 'tap0901'
    condition: selection
falsepositives:
    - Legitimate OpenVPN TAP installation
level: low

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    EventID: 4697
    ServiceFileName|contains: 'tap0901'

Indicators

These rows show field, operator, and value matches.

Usage Of Web Request Commands And Cmdlets - ScriptBlock

#
Status
test
Severity
medium
Author
James Pemberton / @4A616D6573
Source
github.com/SigmaHQ/sigma

Detects the use of various web request commands with commandline tools and Windows PowerShell cmdlets (including aliases) via PowerShell scriptblock logs

Known False Positives

  • Use of Get-Command and Get-Help modules to reference Invoke-WebRequest and Start-BitsTransfer.

MITRE ATT&CK Coverage

Telemetry Coverage

Rule Body

title: Usage Of Web Request Commands And Cmdlets - ScriptBlock
id: 1139d2e2-84b1-4226-b445-354492eba8ba
related:
    - id: 9fc51a3c-81b3-4fa7-b35f-7c02cf10fd2d
      type: derived
status: test
description: Detects the use of various web request commands with commandline tools and Windows PowerShell cmdlets (including aliases) via PowerShell scriptblock logs
references:
    - https://4sysops.com/archives/use-powershell-to-download-a-file-with-http-https-and-ftp/
    - https://blog.jourdant.me/post/3-ways-to-download-files-with-powershell
author: James Pemberton / @4A616D6573
date: 2019-10-24
modified: 2025-10-20
tags:
    - attack.execution
    - attack.t1059.001
logsource:
    product: windows
    category: ps_script
    definition: 'Requirements: Script Block Logging must be enabled'
detection:
    selection:
        ScriptBlockText|contains:
            - '[System.Net.WebRequest]::create'
            - 'curl '
            - 'Invoke-RestMethod'
            - 'Invoke-WebRequest'
            - ' irm ' # Space before and after to avoid false positives with 'irm' as a substring
            - 'iwr '
            # - 'Net.WebClient' # There are various other rules that cover this, so it is commented out
            - 'Resume-BitsTransfer'
            - 'Start-BitsTransfer'
            - 'wget '
            - 'WinHttp.WinHttpRequest'
    filter:
        Path|startswith: 'C:\Packages\Plugins\Microsoft.GuestConfiguration.ConfigurationforWindows\'
    condition: selection and not filter
falsepositives:
    - Use of Get-Command and Get-Help modules to reference Invoke-WebRequest and Start-BitsTransfer.
level: medium
regression_tests_path: regression_data/rules/windows/powershell/powershell_script/posh_ps_web_request_cmd_and_cmdlets/info.yml

Stages and Predicates

Stage 0: condition

selection and not filter

Stage 1: selection

selection:
    ScriptBlockText|contains:
        - '[System.Net.WebRequest]::create'
        - 'curl '
        - 'Invoke-RestMethod'
        - 'Invoke-WebRequest'
        - ' irm '
        - 'iwr '
        - 'Resume-BitsTransfer'
        - 'Start-BitsTransfer'
        - 'wget '
        - 'WinHttp.WinHttpRequest'

Stage 2: not filter

filter:
    Path|startswith: 'C:\Packages\Plugins\Microsoft.GuestConfiguration.ConfigurationforWindows\'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
ScriptBlockTextmatch
  • irm corpus 2 (sigma 2)
  • Invoke-RestMethod corpus 4 (sigma 3, splunk 1)
  • Invoke-WebRequest corpus 3 (sigma 3)
  • Resume-BitsTransfer
  • Start-BitsTransfer corpus 2 (sigma 2)
  • WinHttp.WinHttpRequest
  • [System.Net.WebRequest]::create
  • curl
  • iwr corpus 3 (sigma 3)
  • wget
field:"ScriptBlockText" kind:match

Exclusions

The rule actively suppresses these predicates.

FieldKindExcluded valuesSearch
Pathstarts_withC:\Packages\Plugins\Microsoft.GuestConfiguration.ConfigurationforWindows\excludes:Path field:"Path" value:"C:\Packages\Plugins\Microsoft.GuestConfiguration.ConfigurationforWindows\"

User added to a group via commandline

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

Detects scenarios where an attacker attempts to escalate privilege by adding a user to a group via commandline.

Known False Positives

  • Pentest
  • Administrator activity
  • Splunk UF agent installation

MITRE ATT&CK Coverage

TacticTechniques
Persistence

Telemetry Coverage

Rule Body

title: User added to a group via commandline
description: Detects scenarios where an attacker attempts to escalate privilege by adding a user to a group via commandline.
references:
- https://blogs.jpcert.or.jp/en/2016/01/windows-commands-abused-by-attackers.html
- https://attack.mitre.org/software/S0039/
tags:
- attack.persistence
- attack.t1098 # account manipulation
author: mdecrevoisier
logsource:
  product: windows
  category: process_creation
detection:
  selection: # Full command example: 'net localgroup "Remote Desktop Users" /Add DefaultAccount'
    NewProcessName|endswith:
      - \net1.exe
      - \net.exe
    CommandLine|contains:
      - group
      - localgroup
    CommandLine|contains: add
  condition: selection
falsepositives:
- Pentest
- Administrator activity
- Splunk UF agent installation
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
  NewProcessName|endswith:
    - \net1.exe
    - \net.exe
  CommandLine|contains:
    - group
    - localgroup
  CommandLine|contains: add

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLinematch
  • add corpus 30 (sigma 26, splunk 4)
field:"CommandLine" kind:match value:"add"
NewProcessNameends_with
  • \net.exe corpus 49 (sigma 49)
  • \net1.exe corpus 47 (sigma 47)
field:"Image" kind:ends_with

Wannacry Killswitch Domain

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

Detects wannacry killswitch domain dns queries

Known False Positives

  • Analyst testing

MITRE ATT&CK Coverage

Rule Body

title: Wannacry Killswitch Domain
id: 3eaf6218-3bed-4d8a-8707-274096f12a18
status: test
description: Detects wannacry killswitch domain dns queries
references:
    - https://www.mandiant.com/resources/blog/wannacry-ransomware-campaign
author: Mike Wade
date: 2020-09-16
modified: 2022-03-24
tags:
    - attack.command-and-control
    - attack.t1071.001
logsource:
    category: dns
detection:
    selection:
        query:
            - 'ifferfsodp9ifjaposdfjhgosurijfaewrwergwea.testing'
            - 'ifferfsodp9ifjaposdfjhgosurijfaewrwergwea.test'
            - 'ifferfsodp9ifjaposdfjhgosurijfaewrwergwea.com'
            - 'ayylmaotjhsstasdfasdfasdfasdfasdfasdfasdf.com'
            - 'iuqssfsodp9ifjaposdfjhgosurijfaewrwergwea.com'
    condition: selection
falsepositives:
    - Analyst testing
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    query:
        - 'ifferfsodp9ifjaposdfjhgosurijfaewrwergwea.testing'
        - 'ifferfsodp9ifjaposdfjhgosurijfaewrwergwea.test'
        - 'ifferfsodp9ifjaposdfjhgosurijfaewrwergwea.com'
        - 'ayylmaotjhsstasdfasdfasdfasdfasdfasdfasdf.com'
        - 'iuqssfsodp9ifjaposdfjhgosurijfaewrwergwea.com'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
queryeq
  • ayylmaotjhsstasdfasdfasdfasdfasdfasdfasdf.com
  • ifferfsodp9ifjaposdfjhgosurijfaewrwergwea.com
  • ifferfsodp9ifjaposdfjhgosurijfaewrwergwea.test
  • ifferfsodp9ifjaposdfjhgosurijfaewrwergwea.testing
  • iuqssfsodp9ifjaposdfjhgosurijfaewrwergwea.com
field:"query" kind:eq

Windows Shell/Scripting Processes Spawning Suspicious Programs

#
Status
test
Severity
high
Author
Florian Roth (Nextron Systems), Tim Shelton
Source
github.com/SigmaHQ/sigma

Detects suspicious child processes of a Windows shell and scripting processes such as wscript, rundll32, powershell, mshta...etc.

Known False Positives

  • Administrative scripts
  • Microsoft SCCM

MITRE ATT&CK Coverage

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 1: Process creation

Rule Body

title: Windows Shell/Scripting Processes Spawning Suspicious Programs
id: 3a6586ad-127a-4d3b-a677-1e6eacdf8fde
status: test
description: Detects suspicious child processes of a Windows shell and scripting processes such as wscript, rundll32, powershell, mshta...etc.
references:
    - https://mgreen27.github.io/posts/2018/04/02/DownloadCradle.html
author: Florian Roth (Nextron Systems), Tim Shelton
date: 2018-04-06
modified: 2023-05-23
tags:
    - attack.execution
    - attack.stealth
    - attack.t1059.005
    - attack.t1059.001
    - attack.t1218
logsource:
    category: process_creation
    product: windows
detection:
    selection:
        ParentImage|endswith:
            - '\mshta.exe'
            - '\powershell.exe'
            - '\pwsh.exe'
            # - '\cmd.exe'  # too many false positives
            - '\rundll32.exe'
            - '\cscript.exe'
            - '\wscript.exe'
            - '\wmiprvse.exe'
            - '\regsvr32.exe'
        Image|endswith:
            - '\schtasks.exe'
            - '\nslookup.exe'
            - '\certutil.exe'
            - '\bitsadmin.exe'
            - '\mshta.exe'
    filter_ccmcache:
        CurrentDirectory|contains: '\ccmcache\'
    filter_amazon:
        ParentCommandLine|contains:
            # FP - Amazon Workspaces
            - '\Program Files\Amazon\WorkSpacesConfig\Scripts\setup-scheduledtask.ps1'
            - '\Program Files\Amazon\WorkSpacesConfig\Scripts\set-selfhealing.ps1'
            - '\Program Files\Amazon\WorkSpacesConfig\Scripts\check-workspacehealth.ps1'
            - '\nessus_' # Tenable/Nessus VA Scanner
    filter_nessus:
        CommandLine|contains: '\nessus_' # Tenable/Nessus VA Scanner
    filter_sccm_install:
        ParentImage|endswith: '\mshta.exe'
        Image|endswith: '\mshta.exe'
        ParentCommandLine|contains|all:
            - 'C:\MEM_Configmgr_'
            - '\splash.hta'
            - '{1E460BD7-F1C3-4B2E-88BF-4E770A288AF5}'
        CommandLine|contains|all:
            - 'C:\MEM_Configmgr_'
            - '\SMSSETUP\BIN\'
            - '\autorun.hta'
            - '{1E460BD7-F1C3-4B2E-88BF-4E770A288AF5}'
    condition: selection and not 1 of filter_*
falsepositives:
    - Administrative scripts
    - Microsoft SCCM
level: high
regression_tests_path: regression_data/rules/windows/process_creation/proc_creation_win_susp_shell_spawn_susp_program/info.yml

Stages and Predicates

Stage 0: condition

selection and not 1 of filter_*

Stage 1: selection

selection:
    ParentImage|endswith:
        - '\mshta.exe'
        - '\powershell.exe'
        - '\pwsh.exe'
        - '\rundll32.exe'
        - '\cscript.exe'
        - '\wscript.exe'
        - '\wmiprvse.exe'
        - '\regsvr32.exe'
    Image|endswith:
        - '\schtasks.exe'
        - '\nslookup.exe'
        - '\certutil.exe'
        - '\bitsadmin.exe'
        - '\mshta.exe'

Stage 2: not filter_*

filter_ccmcache:
    CurrentDirectory|contains: '\ccmcache\'
filter_amazon:
    ParentCommandLine|contains:
        - '\Program Files\Amazon\WorkSpacesConfig\Scripts\setup-scheduledtask.ps1'
        - '\Program Files\Amazon\WorkSpacesConfig\Scripts\set-selfhealing.ps1'
        - '\Program Files\Amazon\WorkSpacesConfig\Scripts\check-workspacehealth.ps1'
        - '\nessus_'
filter_nessus:
    CommandLine|contains: '\nessus_'
filter_sccm_install:
    ParentImage|endswith: '\mshta.exe'
    Image|endswith: '\mshta.exe'
    ParentCommandLine|contains|all:
        - 'C:\MEM_Configmgr_'
        - '\splash.hta'
        - '{1E460BD7-F1C3-4B2E-88BF-4E770A288AF5}'
    CommandLine|contains|all:
        - 'C:\MEM_Configmgr_'
        - '\SMSSETUP\BIN\'
        - '\autorun.hta'
        - '{1E460BD7-F1C3-4B2E-88BF-4E770A288AF5}'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
Imageends_with
  • \bitsadmin.exe corpus 29 (sigma 29)
  • \certutil.exe corpus 43 (sigma 43)
  • \mshta.exe corpus 67 (sigma 66, splunk 1)
  • \nslookup.exe corpus 5 (sigma 5)
  • \schtasks.exe corpus 55 (sigma 55)
field:"Image" kind:ends_with
ParentImageends_with
  • \cscript.exe corpus 17 (sigma 17)
  • \mshta.exe corpus 13 (sigma 13)
  • \powershell.exe corpus 24 (sigma 24)
  • \pwsh.exe corpus 21 (sigma 21)
  • \regsvr32.exe corpus 11 (sigma 11)
  • \rundll32.exe corpus 15 (sigma 15)
  • \wmiprvse.exe corpus 8 (sigma 8)
  • \wscript.exe corpus 19 (sigma 19)
field:"ParentImage" kind:ends_with

Exclusions

The rule actively suppresses these predicates.

FieldKindExcluded valuesSearch
CommandLinematchC:\MEM_Configmgr_excludes:CommandLine field:"CommandLine" value:"C:\MEM_Configmgr_"
CommandLinematch\SMSSETUP\BIN\excludes:CommandLine field:"CommandLine" value:"\SMSSETUP\BIN\"
CommandLinematch\autorun.htaexcludes:CommandLine field:"CommandLine" value:"\autorun.hta"
CommandLinematch{1E460BD7-F1C3-4B2E-88BF-4E770A288AF5}excludes:CommandLine field:"CommandLine" value:"{1E460BD7-F1C3-4B2E-88BF-4E770A288AF5}"
Imageends_with\mshta.exeexcludes:Image field:"Image" value:"\mshta.exe"
ParentCommandLinematchC:\MEM_Configmgr_excludes:ParentCommandLine field:"ParentCommandLine" value:"C:\MEM_Configmgr_"
ParentCommandLinematch\splash.htaexcludes:ParentCommandLine field:"ParentCommandLine" value:"\splash.hta"
ParentCommandLinematch{1E460BD7-F1C3-4B2E-88BF-4E770A288AF5}excludes:ParentCommandLine field:"ParentCommandLine" value:"{1E460BD7-F1C3-4B2E-88BF-4E770A288AF5}"
ParentImageends_with\mshta.exeexcludes:ParentImage field:"ParentImage" value:"\mshta.exe"
CommandLinematch\nessus_excludes:CommandLine field:"CommandLine" value:"\nessus_"
CurrentDirectorymatch\ccmcache\excludes:CurrentDirectory field:"CurrentDirectory" value:"\ccmcache\"
ParentCommandLinematch\Program Files\Amazon\WorkSpacesConfig\Scripts\check-workspacehealth.ps1excludes:ParentCommandLine field:"ParentCommandLine" value:"\Program Files\Amazon\WorkSpacesConfig\Scripts\check-workspacehealth.ps1"
ParentCommandLinematch\Program Files\Amazon\WorkSpacesConfig\Scripts\set-selfhealing.ps1excludes:ParentCommandLine field:"ParentCommandLine" value:"\Program Files\Amazon\WorkSpacesConfig\Scripts\set-selfhealing.ps1"
ParentCommandLinematch\Program Files\Amazon\WorkSpacesConfig\Scripts\setup-scheduledtask.ps1excludes:ParentCommandLine field:"ParentCommandLine" value:"\Program Files\Amazon\WorkSpacesConfig\Scripts\setup-scheduledtask.ps1"
ParentCommandLinematch\nessus_excludes:ParentCommandLine field:"ParentCommandLine" value:"\nessus_"

WScript or CScript Dropper - File

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

Detects a file ending in jse, vbe, js, vba, vbs, wsf, wsh written by cscript.exe or wscript.exe

MITRE ATT&CK Coverage

Telemetry Coverage

ProviderRecord / event type
SysmonEvent ID 11: FileCreate

Rule Body

title: WScript or CScript Dropper - File
id: 002bdb95-0cf1-46a6-9e08-d38c128a6127
related:
    - id: cea72823-df4d-4567-950c-0b579eaf0846
      type: derived
status: test
description: Detects a file ending in jse, vbe, js, vba, vbs, wsf, wsh written by cscript.exe or wscript.exe
references:
    - WScript or CScript Dropper (cea72823-df4d-4567-950c-0b579eaf0846)
author: Tim Shelton
date: 2022-01-10
modified: 2026-02-17
tags:
    - attack.execution
    - attack.t1059.005
    - attack.t1059.007
logsource:
    category: file_event
    product: windows
detection:
    selection:
        Image|endswith:
            - '\wscript.exe'
            - '\cscript.exe'
        TargetFilename|contains:
            - ':\Perflogs\'
            - ':\ProgramData\'
            - ':\Temp\'
            - ':\Tmp\'
            - ':\Users\'
            - ':\Windows\Temp\'
            - '\AppData\Local\Temp'
            - '\AppData\Roaming\Temp'
            - '\Start Menu\Programs\Startup\'
            - '\Temporary Internet'
        TargetFilename|endswith:
            - '.js'
            - '.jse'
            - '.vba'
            - '.vbe'
            - '.vbs'
            - '.wsf'
            - '.wsh'
    condition: selection
falsepositives:
    - Unknown
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    Image|endswith:
        - '\wscript.exe'
        - '\cscript.exe'
    TargetFilename|contains:
        - ':\Perflogs\'
        - ':\ProgramData\'
        - ':\Temp\'
        - ':\Tmp\'
        - ':\Users\'
        - ':\Windows\Temp\'
        - '\AppData\Local\Temp'
        - '\AppData\Roaming\Temp'
        - '\Start Menu\Programs\Startup\'
        - '\Temporary Internet'
    TargetFilename|endswith:
        - '.js'
        - '.jse'
        - '.vba'
        - '.vbe'
        - '.vbs'
        - '.wsf'
        - '.wsh'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
Imageends_with
  • \cscript.exe corpus 72 (sigma 72)
  • \wscript.exe corpus 74 (sigma 74)
field:"Image" kind:ends_with
TargetFilenameends_with
  • .js corpus 10 (sigma 10)
  • .jse corpus 3 (sigma 3)
  • .vba corpus 3 (sigma 3)
  • .vbe corpus 16 (sigma 16)
  • .vbs corpus 18 (sigma 18)
  • .wsf corpus 7 (sigma 7)
  • .wsh corpus 3 (sigma 3)
field:"TargetFilename" kind:ends_with
TargetFilenamematch
  • :\Perflogs\
  • :\ProgramData\ corpus 4 (sigma 4)
  • :\Temp\ corpus 5 (sigma 5)
  • :\Tmp\
  • :\Users\ corpus 4 (sigma 4)
  • :\Windows\Temp\ corpus 2 (sigma 2)
  • \AppData\Local\Temp
  • \AppData\Roaming\Temp
  • \Start Menu\Programs\Startup\ corpus 5 (sigma 5)
  • \Temporary Internet
field:"TargetFilename" kind:match

Back to all Sigma rules