Detection rules › Sigma
Sigma rules: 0j
Access To Browser Credential Files By Uncommon Applications - Security
#Detects file access requests to browser credential stores by uncommon processes. Could indicate potential attempt of credential stealing This rule requires heavy baselining before usage.
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Credential Access |
Telemetry Coverage
| Provider | Record / event type |
|---|---|
| Security-Auditing | Event ID 4663: An attempt was made to access an object. |
Rule Body
title: Access To Browser Credential Files By Uncommon Applications - Security
id: 4b60e527-ec73-4b47-8cb3-f02ad927ca65
related:
- id: 91cb43db-302a-47e3-b3c8-7ede481e27bf
type: similar
status: test
description: |
Detects file access requests to browser credential stores by uncommon processes. Could indicate potential attempt of credential stealing This rule requires heavy baselining before usage.
references:
- https://ipurple.team/2024/09/10/browser-stored-credentials/
author: Daniel Koifman (@Koifsec), Nasreddine Bencherchali
date: 2024-10-21
tags:
- attack.credential-access
- attack.t1555.003
- detection.threat-hunting
logsource:
product: windows
service: security
definition: 'Requirements: Audit File System subcategory must be enabled. Additionally, each listed ObjectName must have "List folder/read data" auditing enabled.'
detection:
selection_eid:
EventID: 4663
ObjectType: 'File'
# Note: This AccessMask requires enhancements. As this access can be combined with other requests. It should include all possible outcomes where READ access and similar are part of it.
AccessMask: '0x1'
selection_browser_chromium:
ObjectName|contains:
- '\User Data\Default\Login Data'
- '\User Data\Local State'
- '\User Data\Default\Network\Cookies'
selection_browser_firefox:
FileName|endswith:
- '\cookies.sqlite'
- '\places.sqlite'
- 'release\key3.db' # Firefox
- 'release\key4.db' # Firefox
- 'release\logins.json' # Firefox
filter_main_system:
ProcessName: 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
ProcessName|startswith:
- 'C:\Program Files (x86)\'
- 'C:\Program Files\'
- 'C:\Windows\system32\'
- 'C:\Windows\SysWOW64\'
filter_optional_defender:
ProcessName|startswith: 'C:\ProgramData\Microsoft\Windows Defender\'
ProcessName|endswith:
- '\MpCopyAccelerator.exe'
- '\MsMpEng.exe'
condition: selection_eid and 1 of selection_browser_* and not 1 of filter_main_* and not 1 of filter_optional_*
falsepositives:
- Unknown
level: low
Stages and Predicates
Stage 0: condition
selection_eid and 1 of selection_browser_* and not 1 of filter_main_* and not 1 of filter_optional_*Stage 1: selection_eid
selection_eid:
EventID: 4663
ObjectType: 'File'
AccessMask: '0x1'
Stage 2: selection_browser_chromium
selection_browser_chromium:
ObjectName|contains:
- '\User Data\Default\Login Data'
- '\User Data\Local State'
- '\User Data\Default\Network\Cookies'
Stage 3: selection_browser_firefox
selection_browser_firefox:
FileName|endswith:
- '\cookies.sqlite'
- '\places.sqlite'
- 'release\key3.db'
- 'release\key4.db'
- 'release\logins.json'
Stage 4: not filter_main_*
filter_main_system:
ProcessName: System
filter_main_generic:
ProcessName|startswith:
- 'C:\Program Files (x86)\'
- 'C:\Program Files\'
- 'C:\Windows\system32\'
- 'C:\Windows\SysWOW64\'
Stage 5: not filter_optional_defender
filter_optional_defender:
ProcessName|startswith: 'C:\ProgramData\Microsoft\Windows Defender\'
ProcessName|endswith:
- '\MpCopyAccelerator.exe'
- '\MsMpEng.exe'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
AccessMask | eq |
| field:"AccessMask" kind:eq value:"0x1" |
FileName | ends_with |
| field:"file_name" kind:ends_with |
ObjectName | match |
| field:"ObjectName" kind:match |
ObjectType | eq |
| field:"ObjectType" kind:eq value:"File" |
Exclusions
The rule actively suppresses these predicates.
| Field | Kind | Excluded values | Search |
|---|---|---|---|
ProcessName | eq | System | excludes:ProcessName field:"ProcessName" value:"System" |
ProcessName | starts_with | C:\Program Files (x86)\ | excludes:ProcessName field:"ProcessName" value:"C:\Program Files (x86)\" |
ProcessName | starts_with | C:\Program Files\ | excludes:ProcessName field:"ProcessName" value:"C:\Program Files\" |
ProcessName | starts_with | C:\Windows\SysWOW64\ | excludes:ProcessName field:"ProcessName" value:"C:\Windows\SysWOW64\" |
ProcessName | starts_with | C:\Windows\system32\ | excludes:ProcessName field:"ProcessName" value:"C:\Windows\system32\" |
ProcessName | ends_with | \MpCopyAccelerator.exe | excludes:ProcessName field:"ProcessName" value:"\MpCopyAccelerator.exe" |
ProcessName | ends_with | \MsMpEng.exe | excludes:ProcessName field:"ProcessName" value:"\MsMpEng.exe" |
ProcessName | starts_with | C:\ProgramData\Microsoft\Windows Defender\ | excludes:ProcessName field:"ProcessName" value:"C:\ProgramData\Microsoft\Windows Defender\" |
Add or Remove Computer from DC
#Detects the creation or removal of a computer. Can be used to detect attacks such as DCShadow via the creation of a new SPN.
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Defense Impairment |
Telemetry Coverage
Rule Body
title: Add or Remove Computer from DC
id: 20d96d95-5a20-4cf1-a483-f3bda8a7c037
status: test
description: Detects the creation or removal of a computer. Can be used to detect attacks such as DCShadow via the creation of a new SPN.
references:
- https://github.com/Yamato-Security/EnableWindowsLogSettings/blob/7f6d755d45ac7cc9fc35b0cbf498e6aa4ef19def/ConfiguringSecurityLogAuditPolicies.md
- https://learn.microsoft.com/en-us/previous-versions/windows/it-pro/windows-10/security/threat-protection/auditing/event-4741
- https://learn.microsoft.com/en-us/previous-versions/windows/it-pro/windows-10/security/threat-protection/auditing/event-4743
author: frack113
date: 2022-10-14
tags:
- attack.defense-impairment
- attack.t1207
logsource:
service: security
product: windows
detection:
selection:
EventID:
- 4741
- 4743
condition: selection
falsepositives:
- Unknown
level: low
Stages and Predicates
Stage 0: condition
selectionStage 1: selection
selection:
EventID:
- 4741
- 4743
Azure DNS Zone Modified or Deleted
#Identifies when DNS zone is modified or deleted.
Known False Positives
- DNS zone modified and deleted may be performed by a system administrator. Verify whether the user identity, user agent, and/or hostname should be making changes in your environment.
- DNS zone modification from unfamiliar users should be investigated. If known behavior is causing false positives, it can be exempted from the rule.
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Impact |
Rule Body
title: Azure DNS Zone Modified or Deleted
id: af6925b0-8826-47f1-9324-337507a0babd
status: test
description: Identifies when DNS zone is modified or deleted.
references:
- https://learn.microsoft.com/en-us/azure/role-based-access-control/resource-provider-operations#microsoftkubernetes
author: Austin Songer @austinsonger
date: 2021-08-08
modified: 2022-08-23
tags:
- attack.impact
- attack.t1565.001
logsource:
product: azure
service: activitylogs
detection:
selection:
operationName|startswith: 'MICROSOFT.NETWORK/DNSZONES'
operationName|endswith:
- '/WRITE'
- '/DELETE'
condition: selection
falsepositives:
- DNS zone modified and deleted may be performed by a system administrator. Verify whether the user identity, user agent, and/or hostname should be making changes in your environment.
- DNS zone modification from unfamiliar users should be investigated. If known behavior is causing false positives, it can be exempted from the rule.
level: medium
Stages and Predicates
Stage 0: condition
selectionStage 1: selection
selection:
operationName|startswith: 'MICROSOFT.NETWORK/DNSZONES'
operationName|endswith:
- '/WRITE'
- '/DELETE'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
operationName | ends_with |
| field:"operationName" kind:ends_with |
operationName | starts_with |
| field:"operationName" kind:starts_with value:"MICROSOFT.NETWORK/DNSZONES" |
Azure Kubernetes RoleBinding/ClusterRoleBinding Modified and Deleted
#Detects the creation or patching of potential malicious RoleBinding/ClusterRoleBinding.
Known False Positives
- RoleBinding/ClusterRoleBinding being modified and deleted may be performed by a system administrator. Verify whether the user identity, user agent, and/or hostname should be making changes in your environment.
- RoleBinding/ClusterRoleBinding modification from unfamiliar users should be investigated. If known behavior is causing false positives, it can be exempted from the rule.
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Impact |
Rule Body
title: Azure Kubernetes RoleBinding/ClusterRoleBinding Modified and Deleted
id: 25cb259b-bbdc-4b87-98b7-90d7c72f8743
status: test
description: Detects the creation or patching of potential malicious RoleBinding/ClusterRoleBinding.
references:
- https://learn.microsoft.com/en-us/azure/role-based-access-control/resource-provider-operations#microsoftkubernetes
- https://www.microsoft.com/security/blog/2021/03/23/secure-containerized-environments-with-updated-threat-matrix-for-kubernetes/
- https://www.microsoft.com/security/blog/2020/04/02/attack-matrix-kubernetes/
- https://medium.com/mitre-engenuity/att-ck-for-containers-now-available-4c2359654bf1
author: Austin Songer @austinsonger
date: 2021-08-07
modified: 2022-08-23
tags:
- attack.impact
- attack.credential-access
- attack.t1485
- attack.t1496
- attack.t1489
logsource:
product: azure
service: activitylogs
detection:
selection:
operationName:
- MICROSOFT.KUBERNETES/CONNECTEDCLUSTERS/RBAC.AUTHORIZATION.K8S.IO/CLUSTERROLEBINDINGS/WRITE
- MICROSOFT.KUBERNETES/CONNECTEDCLUSTERS/RBAC.AUTHORIZATION.K8S.IO/CLUSTERROLEBINDINGS/DELETE
- MICROSOFT.KUBERNETES/CONNECTEDCLUSTERS/RBAC.AUTHORIZATION.K8S.IO/ROLEBINDINGS/WRITE
- MICROSOFT.KUBERNETES/CONNECTEDCLUSTERS/RBAC.AUTHORIZATION.K8S.IO/ROLEBINDINGS/DELETE
condition: selection
falsepositives:
- RoleBinding/ClusterRoleBinding being modified and deleted may be performed by a system administrator. Verify whether the user identity, user agent, and/or hostname should be making changes in your environment.
- RoleBinding/ClusterRoleBinding modification from unfamiliar users should be investigated. If known behavior is causing false positives, it can be exempted from the rule.
level: medium
Stages and Predicates
Stage 0: condition
selectionStage 1: selection
selection:
operationName:
- MICROSOFT.KUBERNETES/CONNECTEDCLUSTERS/RBAC.AUTHORIZATION.K8S.IO/CLUSTERROLEBINDINGS/WRITE
- MICROSOFT.KUBERNETES/CONNECTEDCLUSTERS/RBAC.AUTHORIZATION.K8S.IO/CLUSTERROLEBINDINGS/DELETE
- MICROSOFT.KUBERNETES/CONNECTEDCLUSTERS/RBAC.AUTHORIZATION.K8S.IO/ROLEBINDINGS/WRITE
- MICROSOFT.KUBERNETES/CONNECTEDCLUSTERS/RBAC.AUTHORIZATION.K8S.IO/ROLEBINDINGS/DELETE
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
operationName | eq |
| field:"operationName" kind:eq |
Cisco Crypto Commands
#Show when private keys are being exported from the device, or when new certificates are installed
Known False Positives
- Not commonly run by administrators. Also whitelist your known good certificates
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Defense Impairment | |
| Credential Access |
Rule Body
title: Cisco Crypto Commands
id: 1f978c6a-4415-47fb-aca5-736a44d7ca3d
status: test
description: Show when private keys are being exported from the device, or when new certificates are installed
references:
- https://www.cisco.com/c/en/us/td/docs/ios-xml/ios/security/a1/sec-a1-cr-book/sec-a1-cr-book_chapter_0111.html
author: Austin Clark
date: 2019-08-12
modified: 2023-01-04
tags:
- attack.credential-access
- attack.defense-impairment
- attack.t1553.004
- attack.t1552.004
logsource:
product: cisco
service: aaa
detection:
keywords:
- 'crypto pki export'
- 'crypto pki import'
- 'crypto pki trustpoint'
condition: keywords
falsepositives:
- Not commonly run by administrators. Also whitelist your known good certificates
level: high
Stages and Predicates
Stage 0: condition
keywordsStage 1: keywords
keywords:
- 'crypto pki export'
- 'crypto pki import'
- 'crypto pki trustpoint'
Cobalt Strike DNS Beaconing
#Detects suspicious DNS queries known from Cobalt Strike beacons
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Command & Control |
Rule Body
title: Cobalt Strike DNS Beaconing
id: 2975af79-28c4-4d2f-a951-9095f229df29
status: test
description: Detects suspicious DNS queries known from Cobalt Strike beacons
references:
- https://www.icebrg.io/blog/footprints-of-fin7-tracking-actor-patterns
- https://www.sekoia.io/en/hunting-and-detecting-cobalt-strike/
author: Florian Roth (Nextron Systems)
date: 2018-05-10
modified: 2022-10-09
tags:
- attack.command-and-control
- attack.t1071.004
logsource:
category: dns
detection:
selection1:
query|startswith:
- 'aaa.stage.'
- 'post.1'
selection2:
query|contains: '.stage.123456.'
condition: 1 of selection*
falsepositives:
- Unknown
level: critical
Stages and Predicates
Stage 0: condition
1 of selection*Stage 1: selection1
selection1:
query|startswith:
- 'aaa.stage.'
- 'post.1'
Stage 2: selection2
selection2:
query|contains: '.stage.123456.'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
query | match |
| field:"query" kind:match value:".stage.123456." |
query | starts_with |
| field:"query" kind:starts_with |
DEWMODE Webshell Access
#Detects access to DEWMODE webshell as described in FIREEYE report
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Persistence |
Rule Body
title: DEWMODE Webshell Access
id: fdf96c90-42d5-4406-8a9c-14a2c9a016b5
status: test
description: Detects access to DEWMODE webshell as described in FIREEYE report
references:
- https://www.mandiant.com/resources/blog/accellion-fta-exploited-for-data-theft-and-extortion
author: Florian Roth (Nextron Systems)
date: 2021-02-22
modified: 2023-01-02
tags:
- attack.persistence
- attack.t1505.003
- detection.emerging-threats
logsource:
category: webserver
detection:
selection1:
cs-uri-query|contains|all:
- '?dwn='
- '&fn='
- '.html?'
selection2:
cs-uri-query|contains|all:
- '&dwn='
- '?fn='
- '.html?'
condition: 1 of selection*
falsepositives:
- Unknown
level: high
Stages and Predicates
Stage 0: condition
1 of selection*Stage 1: selection1
selection1:
cs-uri-query|contains|all:
- '?dwn='
- '&fn='
- '.html?'
Stage 2: selection2
selection2:
cs-uri-query|contains|all:
- '&dwn='
- '?fn='
- '.html?'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
cs-uri-query | match |
| field:"cs-uri-query" kind:match |
ESXi Syslog Configuration Change Via ESXCLI
#Detects changes to the ESXi syslog configuration via "esxcli"
Known False Positives
- Legitimate administrative activities
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Execution | |
| Defense Impairment |
Telemetry Coverage
| Platform | Record / event type |
|---|---|
| Linux | Event ID 1: Process Create |
Rule Body
title: ESXi Syslog Configuration Change Via ESXCLI
id: 38eb1dbb-011f-40b1-a126-cf03a0210563
status: test
description: Detects changes to the ESXi syslog configuration via "esxcli"
references:
- https://support.solarwinds.com/SuccessCenter/s/article/Configure-ESXi-Syslog-to-LEM?language=en_US
- https://developer.broadcom.com/xapis/esxcli-command-reference/7.0.0/namespace/esxcli_system.html
author: Cedric Maurugeon
date: 2023-09-04
tags:
- attack.execution
- attack.defense-impairment
- attack.t1685
- attack.t1690
- attack.t1059.012
logsource:
category: process_creation
product: linux
detection:
selection:
Image|endswith: '/esxcli'
CommandLine|contains|all:
- 'system'
- 'syslog'
- 'config'
CommandLine|contains: ' set'
condition: selection
falsepositives:
- Legitimate administrative activities
level: medium
Stages and Predicates
Stage 0: condition
selectionStage 1: selection
selection:
Image|endswith: '/esxcli'
CommandLine|contains|all:
- 'system'
- 'syslog'
- 'config'
CommandLine|contains: ' set'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
CommandLine | match |
| field:"CommandLine" kind:match |
Image | ends_with |
| field:"Image" kind:ends_with value:"/esxcli" |
Goofy Guineapig Backdoor Potential C2 Communication
#Detects potential C2 communication related to Goofy Guineapig backdoor
Known False Positives
- Unlikely
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Command & Control | No specific technique |
Rule Body
title: Goofy Guineapig Backdoor Potential C2 Communication
id: 4f573bb6-701a-4b8d-91db-87ae106e9a61
status: test
description: Detects potential C2 communication related to Goofy Guineapig backdoor
references:
- https://www.ncsc.gov.uk/static-assets/documents/malware-analysis-reports/goofy-guineapig/NCSC-MAR-Goofy-Guineapig.pdf
author: Nasreddine Bencherchali (Nextron Systems)
date: 2023-05-14
tags:
- attack.command-and-control
- detection.emerging-threats
logsource:
category: proxy
detection:
selection:
c-useragent: 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.71 Safari/537.36'
cs-host: 'static.tcplog.com'
condition: selection
falsepositives:
- Unlikely
level: high
Stages and Predicates
Stage 0: condition
selectionStage 1: selection
selection:
c-useragent: 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.71 Safari/537.36'
cs-host: 'static.tcplog.com'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
c-useragent | eq |
| field:"c-useragent" kind:eq value:"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.71 Safari/537.36" |
cs-host | eq |
| field:"cs-host" kind:eq value:"static.tcplog.com" |
HackTool - HandleKatz LSASS Dumper Execution
#Detects the use of HandleKatz, a tool that demonstrates the usage of cloned handles to Lsass in order to create an obfuscated memory dump of the same
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Credential Access |
Telemetry Coverage
| Provider | Record / event type |
|---|---|
| Sysmon | Event ID 1: Process creation |
Rule Body
title: HackTool - HandleKatz LSASS Dumper Execution
id: ca621ba5-54ab-4035-9942-d378e6fcde3c
status: test
description: Detects the use of HandleKatz, a tool that demonstrates the usage of cloned handles to Lsass in order to create an obfuscated memory dump of the same
references:
- https://github.com/codewhitesec/HandleKatz
author: Florian Roth (Nextron Systems)
date: 2022-08-18
modified: 2024-11-23
tags:
- attack.credential-access
- attack.t1003.001
logsource:
category: process_creation
product: windows
detection:
selection_loader_img:
Image|endswith: '\loader.exe'
CommandLine|contains: '--pid:'
selection_loader_imphash:
Hashes|contains:
- 'IMPHASH=38D9E015591BBFD4929E0D0F47FA0055'
- 'IMPHASH=0E2216679CA6E1094D63322E3412D650'
selection_flags:
CommandLine|contains|all:
- '--pid:'
- '--outfile:'
CommandLine|contains:
- '.dmp'
- 'lsass'
- '.obf'
- 'dump'
condition: 1 of selection_*
falsepositives:
- Unknown
level: high
Stages and Predicates
Stage 0: condition
1 of selection_*Stage 1: selection_loader_img
selection_loader_img:
Image|endswith: '\loader.exe'
CommandLine|contains: '--pid:'
Stage 2: selection_loader_imphash
selection_loader_imphash:
Hashes|contains:
- 'IMPHASH=38D9E015591BBFD4929E0D0F47FA0055'
- 'IMPHASH=0E2216679CA6E1094D63322E3412D650'
Stage 3: selection_flags
selection_flags:
CommandLine|contains|all:
- '--pid:'
- '--outfile:'
CommandLine|contains:
- '.dmp'
- 'lsass'
- '.obf'
- 'dump'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
CommandLine | match |
| field:"CommandLine" kind:match |
Hashes | match |
| field:"Hashes" kind:match |
Image | ends_with |
| field:"Image" kind:ends_with value:"\loader.exe" |
HackTool - SharpDPAPI Execution
#Detects the execution of the SharpDPAPI tool based on CommandLine flags and PE metadata. SharpDPAPI is a C# port of some DPAPI functionality from the Mimikatz project.
MITRE ATT&CK Coverage
Telemetry Coverage
| Provider | Record / event type |
|---|---|
| Sysmon | Event ID 1: Process creation |
Rule Body
title: HackTool - SharpDPAPI Execution
id: c7d33b50-f690-4b51-8cfb-0fb912a31e57
status: test
description: |
Detects the execution of the SharpDPAPI tool based on CommandLine flags and PE metadata.
SharpDPAPI is a C# port of some DPAPI functionality from the Mimikatz project.
references:
- https://github.com/GhostPack/SharpDPAPI
author: Nasreddine Bencherchali (Nextron Systems)
date: 2024-06-26
tags:
- attack.privilege-escalation
- attack.stealth
- attack.t1134.001
- attack.t1134.003
logsource:
product: windows
category: process_creation
detection:
selection_img:
- Image|endswith: '\SharpDPAPI.exe'
- OriginalFileName: 'SharpDPAPI.exe'
selection_other_cli:
CommandLine|contains:
- ' backupkey '
- ' blob '
- ' certificates '
- ' credentials '
- ' keepass '
- ' masterkeys '
- ' rdg '
- ' vaults '
selection_other_options_guid:
CommandLine|contains|all:
- ' {'
- '}:'
selection_other_options_flags:
CommandLine|contains:
- ' /file:'
- ' /machine'
- ' /mkfile:'
- ' /password:'
- ' /pvk:'
- ' /server:'
- ' /target:'
- ' /unprotect'
condition: selection_img or (selection_other_cli and 1 of selection_other_options_*)
falsepositives:
- Unknown
level: high
Stages and Predicates
Stage 0: condition
selection_img or (selection_other_cli and 1 of selection_other_options_*)Stage 1: selection_img
selection_img:
- Image|endswith: '\SharpDPAPI.exe'
- OriginalFileName: 'SharpDPAPI.exe'
Stage 2: selection_other_cli
selection_other_cli:
CommandLine|contains:
- ' backupkey '
- ' blob '
- ' certificates '
- ' credentials '
- ' keepass '
- ' masterkeys '
- ' rdg '
- ' vaults '
Stage 3: selection_other_options_guid
selection_other_options_guid:
CommandLine|contains|all:
- ' {'
- '}:'
Stage 4: selection_other_options_flags
selection_other_options_flags:
CommandLine|contains:
- ' /file:'
- ' /machine'
- ' /mkfile:'
- ' /password:'
- ' /pvk:'
- ' /server:'
- ' /target:'
- ' /unprotect'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
CommandLine | match |
| field:"CommandLine" kind:match |
Image | ends_with |
| field:"Image" kind:ends_with value:"\SharpDPAPI.exe" |
OriginalFileName | eq |
| field:"OriginalFileName" kind:eq value:"SharpDPAPI.exe" |
Kubernetes Secrets Enumeration
#Detects enumeration of Kubernetes secrets.
Known False Positives
- The Kubernetes dashboard occasionally accesses the kubernetes-dashboard-key-holder secret
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Credential Access |
Telemetry Coverage
| Platform | Record / event type |
|---|---|
| Kubernetes | list-secrets: list secrets |
Rules Detecting the Same Action
These rules filter on the same operation.
- Azure AKS Secret get or list with Suspicious User Agent (Elastic)
- Direct Interactive Kubernetes API Request by Unusual Utilities (Elastic)
- GKE Secret Access from Node or Denied Service Account (Elastic)
- GKE Secret Access via Unusual User Agent (Elastic)
- GKE Secret get or list with Suspicious User Agent (Elastic)
- GKE Secrets List from Unusual Source AS Organization (Elastic)
- Kubernetes All Secrets Dumped Across Namespaces (Panther)
- Kubernetes Secret Access via Unusual User Agent (Elastic)
Rule Body
title: Kubernetes Secrets Enumeration
id: eeb3e9e1-b685-44e4-9232-6bb701f925b5
related:
- id: 7ee0b4aa-d8d4-4088-b661-20efdf41a04c
type: derived
status: test
description: Detects enumeration of Kubernetes secrets.
references:
- https://microsoft.github.io/Threat-Matrix-for-Kubernetes/techniques/List%20K8S%20secrets/
author: Leo Tsaousis (@laripping)
date: 2024-03-26
tags:
- attack.t1552.007
- attack.credential-access
logsource:
category: application
product: kubernetes
service: audit
detection:
selection:
verb: 'list'
objectRef.resource: 'secrets'
condition: selection
falsepositives:
- The Kubernetes dashboard occasionally accesses the kubernetes-dashboard-key-holder secret
level: low
Stages and Predicates
Stage 0: condition
selectionStage 1: selection
selection:
verb: 'list'
objectRef.resource: 'secrets'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
objectRef.resource | eq |
| field:"objectRef.resource" kind:eq value:"secrets" |
verb | eq |
| field:"verb" kind:eq value:"list" |
Linux Webshell Indicators
#Detects suspicious sub processes of web server processes
Known False Positives
- Web applications that invoke Linux command line tools
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Persistence |
Telemetry Coverage
| Platform | Record / event type |
|---|---|
| Linux | Event ID 1: Process Create |
Rule Body
title: Linux Webshell Indicators
id: 818f7b24-0fba-4c49-a073-8b755573b9c7
status: test
description: Detects suspicious sub processes of web server processes
references:
- https://www.acunetix.com/blog/articles/web-shells-101-using-php-introduction-web-shells-part-2/
- https://media.defense.gov/2020/Jun/09/2002313081/-1/-1/0/CSI-DETECT-AND-PREVENT-WEB-SHELL-MALWARE-20200422.PDF
author: Florian Roth (Nextron Systems), Nasreddine Bencherchali (Nextron Systems)
date: 2021-10-15
modified: 2026-08-19
tags:
- attack.persistence
- attack.t1505.003
logsource:
product: linux
category: process_creation
detection:
selection_parent_general:
ParentImage|endswith:
- '/httpd'
- '/lighttpd'
- '/nginx'
- '/apache2'
- '/node'
- '/caddy'
selection_parent_tomcat:
ParentCommandLine|contains|all:
- '/bin/java'
- 'tomcat'
selection_parent_websphere: # ? just guessing
ParentCommandLine|contains|all:
- '/bin/java'
- 'websphere'
selection_child_processes:
Image|endswith:
- '/whoami'
- '/ifconfig'
- '/ip'
- '/bin/uname'
- '/bin/cat'
- '/bin/crontab'
- '/hostname'
- '/iptables'
- '/netstat'
- '/pwd'
- '/route'
filter_optional_ip_neigh:
ParentImage|endswith: '/node'
CommandLine|contains: 'ip neigh show'
condition: 1 of selection_parent_* and selection_child_processes and not 1 of filter_optional_*
falsepositives:
- Web applications that invoke Linux command line tools
level: high
Stages and Predicates
Stage 0: condition
1 of selection_parent_* and selection_child_processes and not 1 of filter_optional_*Stage 1: selection_parent_general
selection_parent_general:
ParentImage|endswith:
- '/httpd'
- '/lighttpd'
- '/nginx'
- '/apache2'
- '/node'
- '/caddy'
Stage 2: selection_parent_tomcat
selection_parent_tomcat:
ParentCommandLine|contains|all:
- '/bin/java'
- 'tomcat'
Stage 3: selection_parent_websphere
selection_parent_websphere:
ParentCommandLine|contains|all:
- '/bin/java'
- 'websphere'
Stage 4: selection_child_processes
selection_child_processes:
Image|endswith:
- '/whoami'
- '/ifconfig'
- '/ip'
- '/bin/uname'
- '/bin/cat'
- '/bin/crontab'
- '/hostname'
- '/iptables'
- '/netstat'
- '/pwd'
- '/route'
Stage 5: not filter_optional_ip_neigh
filter_optional_ip_neigh:
ParentImage|endswith: '/node'
CommandLine|contains: 'ip neigh show'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
Image | ends_with |
| field:"Image" kind:ends_with |
ParentCommandLine | match |
| field:"ParentCommandLine" kind:match |
ParentImage | ends_with |
| field:"ParentImage" kind:ends_with |
Exclusions
The rule actively suppresses these predicates.
| Field | Kind | Excluded values | Search |
|---|---|---|---|
CommandLine | match | ip neigh show | excludes:CommandLine field:"CommandLine" value:"ip neigh show" |
ParentImage | ends_with | /node | excludes:ParentImage field:"ParentImage" value:"/node" |
Narrator's Feedback-Hub Persistence
#Detects abusing Windows 10 Narrator's Feedback-Hub
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Persistence | |
| Privilege Escalation |
Telemetry Coverage
Rule Body
title: Narrator's Feedback-Hub Persistence
id: f663a6d9-9d1b-49b8-b2b1-0637914d199a
status: test
description: Detects abusing Windows 10 Narrator's Feedback-Hub
references:
- https://giuliocomi.blogspot.com/2019/10/abusing-windows-10-narrators-feedback.html
author: Dmitriy Lifanov, oscd.community
date: 2019-10-25
modified: 2022-03-26
tags:
- attack.privilege-escalation
- attack.persistence
- attack.t1547.001
logsource:
category: registry_event
product: windows
detection:
selection1:
EventType: DeleteValue
TargetObject|endswith: '\AppXypsaf9f1qserqevf0sws76dx4k9a5206\Shell\open\command\DelegateExecute'
selection2:
TargetObject|endswith: '\AppXypsaf9f1qserqevf0sws76dx4k9a5206\Shell\open\command\(Default)'
# Add the payload in the (Default)
condition: 1 of selection*
falsepositives:
- Unknown
level: high
Stages and Predicates
Stage 0: condition
1 of selection*Stage 1: selection1
selection1:
EventType: DeleteValue
TargetObject|endswith: '\AppXypsaf9f1qserqevf0sws76dx4k9a5206\Shell\open\command\DelegateExecute'
Stage 2: selection2
selection2:
TargetObject|endswith: '\AppXypsaf9f1qserqevf0sws76dx4k9a5206\Shell\open\command\(Default)'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
EventType | eq |
| field:"EventType" kind:eq value:"DeleteValue" |
TargetObject | ends_with |
| field:"TargetObject" kind:ends_with |
Non-Standard Nsswitch.Conf Creation - Potential CVE-2025-32463 Exploitation
#Detects the creation of nsswitch.conf files in non-standard directories, which may indicate exploitation of CVE-2025-32463. This vulnerability requires an attacker to create a nsswitch.conf in a directory that will be used during sudo chroot operations. When sudo executes, it loads malicious shared libraries from user-controlled locations within the chroot environment, potentially leading to arbitrary code execution and privilege escalation.
Known False Positives
- Backup locations
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Privilege Escalation |
Telemetry Coverage
| Platform | Record / event type |
|---|---|
| Linux | Event ID 11: File created |
Rule Body
title: Non-Standard Nsswitch.Conf Creation - Potential CVE-2025-32463 Exploitation
id: 10ac0730-c24e-4f4c-81f8-b13a1ac95a1d
status: experimental
description: |
Detects the creation of nsswitch.conf files in non-standard directories, which may indicate exploitation of CVE-2025-32463.
This vulnerability requires an attacker to create a nsswitch.conf in a directory that will be used during sudo chroot operations.
When sudo executes, it loads malicious shared libraries from user-controlled locations within the chroot environment,
potentially leading to arbitrary code execution and privilege escalation.
references:
- https://github.com/kh4sh3i/CVE-2025-32463/blob/81bb430f84fa2089224733c3ed4bfa434c197ad4/exploit.sh
author: Swachchhanda Shrawn Poudel (Nextron Systems)
date: 2025-10-02
modified: 2026-03-31
tags:
- attack.privilege-escalation
- attack.t1068
- cve.2025-32463
- detection.emerging-threats
logsource:
category: file_event
product: linux
detection:
selection:
TargetFilename|endswith: '/etc/nsswitch.conf'
filter_main_legitimate_path:
TargetFilename:
- '/etc/nsswitch.conf'
- '/usr/share/factory/etc/nsswitch.conf'
condition: selection and not 1 of filter_main_*
falsepositives:
- Backup locations
level: high
Stages and Predicates
Stage 0: condition
selection and not 1 of filter_main_*Stage 1: selection
selection:
TargetFilename|endswith: '/etc/nsswitch.conf'
Stage 2: not filter_main_legitimate_path
filter_main_legitimate_path:
TargetFilename:
- '/etc/nsswitch.conf'
- '/usr/share/factory/etc/nsswitch.conf'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
TargetFilename | ends_with |
| field:"TargetFilename" kind:ends_with value:"/etc/nsswitch.conf" |
Exclusions
The rule actively suppresses these predicates.
| Field | Kind | Excluded values | Search |
|---|---|---|---|
TargetFilename | eq | /etc/nsswitch.conf | excludes:TargetFilename field:"TargetFilename" value:"/etc/nsswitch.conf" |
TargetFilename | eq | /usr/share/factory/etc/nsswitch.conf | excludes:TargetFilename field:"TargetFilename" value:"/usr/share/factory/etc/nsswitch.conf" |
Potential Malicious Usage of CloudTrail System Manager
#Detect when System Manager successfully executes commands against an instance.
Known False Positives
- There are legitimate uses of SSM to send commands to EC2 instances
- Legitimate users may have to use SSM to perform actions against machines in the Cloud to update or maintain them
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Initial Access |
Telemetry Coverage
Rules Detecting the Same Action
These rules filter on the same operation.
Rule Body
title: Potential Malicious Usage of CloudTrail System Manager
id: 38e7f511-3f74-41d4-836e-f57dfa18eead
status: test
description: |
Detect when System Manager successfully executes commands against an instance.
references:
- https://github.com/elastic/detection-rules/blob/v8.6.0/rules/integrations/aws/initial_access_via_system_manager.toml
author: jamesc-grafana
date: 2024-07-11
modified: 2025-12-08
tags:
- attack.privilege-escalation
- attack.initial-access
- attack.t1566
- attack.t1566.002
logsource:
product: aws
service: cloudtrail
detection:
selection_event:
eventName: 'SendCommand'
eventSource: 'ssm.amazonaws.com'
selection_status_success:
errorCode: 'Success'
selection_status_null:
errorCode: null
condition: selection_event and 1 of selection_status_*
falsepositives:
- There are legitimate uses of SSM to send commands to EC2 instances
- Legitimate users may have to use SSM to perform actions against machines in the Cloud to update or maintain them
level: high
Stages and Predicates
Stage 0: condition
selection_event and 1 of selection_status_*Stage 1: selection_event
selection_event:
eventName: 'SendCommand'
eventSource: 'ssm.amazonaws.com'
Stage 2: selection_status_success
selection_status_success:
errorCode: 'Success'
Stage 3: selection_status_null
selection_status_null:
errorCode: null
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
errorCode | eq |
| field:"aws::errorCode" kind:eq value:"Success" |
errorCode | is_null | field:"aws::errorCode" kind:is_null | |
eventName | eq |
| field:"aws::eventName" kind:eq value:"SendCommand" |
eventSource | eq |
| field:"aws::eventSource" kind:eq value:"ssm.amazonaws.com" |
Potential Persistence Via PowerShell User Profile Using Add-Content
#Detects calls to "Add-Content" cmdlet in order to modify the content of the user profile and potentially adding suspicious commands for persistence
Known False Positives
- Legitimate administration and tuning scripts that aim to add functionality to a user PowerShell session
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Persistence | |
| Privilege Escalation |
Telemetry Coverage
| Provider | Record / event type |
|---|---|
| PowerShell | Event ID 4104: Creating Scriptblock text (MessageNumber of MessageTotal). |
Rule Body
title: Potential Persistence Via PowerShell User Profile Using Add-Content
id: 05b3e303-faf0-4f4a-9b30-46cc13e69152
status: test
description: Detects calls to "Add-Content" cmdlet in order to modify the content of the user profile and potentially adding suspicious commands for persistence
references:
- https://github.com/redcanaryco/atomic-red-team/blob/f339e7da7d05f6057fdfcdd3742bfcf365fee2a9/atomics/T1546.013/T1546.013.md
author: frack113, Nasreddine Bencherchali (Nextron Systems)
date: 2021-08-18
modified: 2023-05-04
tags:
- attack.persistence
- attack.privilege-escalation
- attack.t1546.013
logsource:
product: windows
category: ps_script
definition: 'Requirements: Script Block Logging must be enabled'
detection:
selection_add:
ScriptBlockText|contains: 'Add-Content $profile'
selection_options:
ScriptBlockText|contains:
# Note: You can add more suspicious values
- '-Value "IEX '
- '-Value "Invoke-Expression'
- '-Value "Invoke-WebRequest'
- '-Value "Start-Process'
- "-Value 'IEX "
- "-Value 'Invoke-Expression"
- "-Value 'Invoke-WebRequest"
- "-Value 'Start-Process"
condition: all of selection_*
falsepositives:
- Legitimate administration and tuning scripts that aim to add functionality to a user PowerShell session
level: medium
Stages and Predicates
Stage 0: condition
all of selection_*Stage 1: selection_add
selection_add:
ScriptBlockText|contains: 'Add-Content $profile'
Stage 2: selection_options
selection_options:
ScriptBlockText|contains:
- '-Value "IEX '
- '-Value "Invoke-Expression'
- '-Value "Invoke-WebRequest'
- '-Value "Start-Process'
- "-Value 'IEX "
- "-Value 'Invoke-Expression"
- "-Value 'Invoke-WebRequest"
- "-Value 'Start-Process"
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
ScriptBlockText | match |
| field:"ScriptBlockText" kind:match |
Potential Provlaunch.EXE Binary Proxy Execution Abuse
#Detects child processes of "provlaunch.exe" which might indicate potential abuse to proxy execution.
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Stealth |
Telemetry Coverage
| Provider | Record / event type |
|---|---|
| Sysmon | Event ID 1: Process creation |
| Security-Auditing | Event ID 4688: A new process has been created. |
Rule Body
title: Potential Provlaunch.EXE Binary Proxy Execution Abuse
id: 7f5d1c9a-3e83-48df-95a7-2b98aae6c13c
related:
- id: f9999590-1f94-4a34-a91e-951e47bedefd # CLI Abuse
type: similar
- id: 2a4b3e61-9d22-4e4a-b60f-6e8f0cde6f25 # CLI Registry
type: similar
- id: 7021255e-5db3-4946-a8b9-0ba7a4644a69 # Registry
type: similar
status: test
description: Detects child processes of "provlaunch.exe" which might indicate potential abuse to proxy execution.
references:
- https://lolbas-project.github.io/lolbas/Binaries/Provlaunch/
- https://twitter.com/0gtweet/status/1674399582162153472
author: Nasreddine Bencherchali (Nextron Systems), Swachchhanda Shrawan Poudel
date: 2023-08-08
tags:
- attack.stealth
- attack.t1218
logsource:
category: process_creation
product: windows
detection:
selection:
ParentImage|endswith: '\provlaunch.exe'
filter_main_covered_children:
# Note: this filter is here to avoid duplicate alerting by f9999590-1f94-4a34-a91e-951e47bedefd
- Image|endswith:
- '\calc.exe'
- '\cmd.exe'
- '\cscript.exe'
- '\mshta.exe'
- '\notepad.exe'
- '\powershell.exe'
- '\pwsh.exe'
- '\regsvr32.exe'
- '\rundll32.exe'
- '\wscript.exe'
- Image|contains:
- ':\PerfLogs\'
- ':\Temp\'
- ':\Users\Public\'
- '\AppData\Temp\'
- '\Windows\System32\Tasks\'
- '\Windows\Tasks\'
- '\Windows\Temp\'
condition: selection and not 1 of filter_main_*
falsepositives:
- Unknown
level: medium
Stages and Predicates
Stage 0: condition
selection and not 1 of filter_main_*Stage 1: selection
selection:
ParentImage|endswith: '\provlaunch.exe'
Stage 2: not filter_main_covered_children
filter_main_covered_children:
- Image|endswith:
- '\calc.exe'
- '\cmd.exe'
- '\cscript.exe'
- '\mshta.exe'
- '\notepad.exe'
- '\powershell.exe'
- '\pwsh.exe'
- '\regsvr32.exe'
- '\rundll32.exe'
- '\wscript.exe'
- Image|contains:
- ':\PerfLogs\'
- ':\Temp\'
- ':\Users\Public\'
- '\AppData\Temp\'
- '\Windows\System32\Tasks\'
- '\Windows\Tasks\'
- '\Windows\Temp\'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
ParentImage | ends_with |
| field:"ParentImage" kind:ends_with value:"\provlaunch.exe" |
Exclusions
The rule actively suppresses these predicates.
Sensitive File Dump Via Wbadmin.EXE
#Detects the dump of highly sensitive files such as "NTDS.DIT" and "SECURITY" hive. Attackers can leverage the "wbadmin" utility in order to dump sensitive files that might contain credential or sensitive information.
Known False Positives
- Legitimate backup operation by authorized administrators. Matches must be investigated and allowed on a case by case basis.
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Credential Access |
Telemetry Coverage
| Provider | Record / event type |
|---|---|
| Sysmon | Event ID 1: Process creation |
Rule Body
title: Sensitive File Dump Via Wbadmin.EXE
id: 8b93a509-1cb8-42e1-97aa-ee24224cdc15
status: test
description: |
Detects the dump of highly sensitive files such as "NTDS.DIT" and "SECURITY" hive.
Attackers can leverage the "wbadmin" utility in order to dump sensitive files that might contain credential or sensitive information.
references:
- https://github.com/LOLBAS-Project/LOLBAS/blob/2cc01b01132b5c304027a658c698ae09dd6a92bf/yml/OSBinaries/Wbadmin.yml
- https://lolbas-project.github.io/lolbas/Binaries/Wbadmin/
- https://learn.microsoft.com/en-us/windows-server/administration/windows-commands/wbadmin-start-recovery
- https://learn.microsoft.com/en-us/windows-server/administration/windows-commands/wbadmin-start-backup
author: Nasreddine Bencherchali (Nextron Systems), frack113
date: 2024-05-10
tags:
- attack.credential-access
- attack.t1003.003
logsource:
category: process_creation
product: windows
detection:
selection_img:
- Image|endswith: '\wbadmin.exe'
- OriginalFileName: 'WBADMIN.EXE'
selection_backup:
CommandLine|contains:
- 'start'
- 'backup'
selection_path:
CommandLine|contains:
- '\config\SAM'
- '\config\SECURITY'
- '\config\SYSTEM'
- '\Windows\NTDS\NTDS.dit'
condition: all of selection_*
falsepositives:
- Legitimate backup operation by authorized administrators. Matches must be investigated and allowed on a case by case basis.
level: high
Stages and Predicates
Stage 0: condition
all of selection_*Stage 1: selection_img
selection_img:
- Image|endswith: '\wbadmin.exe'
- OriginalFileName: 'WBADMIN.EXE'
Stage 2: selection_backup
selection_backup:
CommandLine|contains:
- 'start'
- 'backup'
Stage 3: selection_path
selection_path:
CommandLine|contains:
- '\config\SAM'
- '\config\SECURITY'
- '\config\SYSTEM'
- '\Windows\NTDS\NTDS.dit'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
CommandLine | match |
| field:"CommandLine" kind:match |
Image | ends_with |
| field:"Image" kind:ends_with value:"\wbadmin.exe" |
OriginalFileName | eq |
| field:"OriginalFileName" kind:eq value:"WBADMIN.EXE" |
Shai-Hulud Malicious Bun Execution - Linux
#Detects the execution of bun_environment.js via the Bun runtime, a behavior associated with the Shai-Hulud "Second Coming" NPM supply chain attack. The malware uses a setup_bun.js script to install the Bun runtime if not present, and then executes the malicious bun_environment.js payload.
Known False Positives
- Legitimate but uncommon use of files named `bun_environment.js` could trigger this rule.
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Initial Access | |
| Execution |
Telemetry Coverage
| Platform | Record / event type |
|---|---|
| Linux | Event ID 1: Process Create |
Rule Body
title: Shai-Hulud Malicious Bun Execution - Linux
id: eb827bbd-670a-4d58-8446-c464d8ac2323
related:
- id: 5299fadf-f228-4526-8274-251db1960be9
type: similar
status: experimental
description: |
Detects the execution of `bun_environment.js` via the Bun runtime, a behavior associated with the Shai-Hulud "Second Coming" NPM supply chain attack.
The malware uses a `setup_bun.js` script to install the Bun runtime if not present, and then executes the malicious `bun_environment.js` payload.
references:
- https://www.aikido.dev/blog/shai-hulud-strikes-again-hitting-zapier-ensdomains
- https://www.wiz.io/blog/shai-hulud-2-0-ongoing-supply-chain-attack
- https://github.com/asyncapi/cli/blob/2efa4dff59bc3d3cecdf897ccf178f99b115d63d/setup_bun.js
author: Swachchhanda Shrawan Poudel (Nextron Systems)
date: 2025-11-25
tags:
- attack.t1195.002
- attack.t1203
- attack.execution
- attack.initial-access
- detection.emerging-threats
logsource:
category: process_creation
product: linux
detection:
selection_parent:
ParentImage|endswith: '/node'
selection_child_bun:
Image|endswith: '/bun'
CommandLine|contains:
- 'bun_environment.js'
- 'https://github.com/actions/runner/releases/download/v2.330.0'
selection_child_setup_curl:
CommandLine|contains|all:
- 'curl '
- '-fsSL'
- 'https://bun.sh/install'
- 'bash'
selection_child_path_reload:
CommandLine|contains|all:
- 'bash -c "source '
- '&& echo'
condition: selection_parent and 1 of selection_child_*
falsepositives:
- Legitimate but uncommon use of files named `bun_environment.js` could trigger this rule.
level: high
Stages and Predicates
Stage 0: condition
selection_parent and 1 of selection_child_*Stage 1: selection_parent
selection_parent:
ParentImage|endswith: '/node'
Stage 2: selection_child_bun
selection_child_bun:
Image|endswith: '/bun'
CommandLine|contains:
- 'bun_environment.js'
- 'https://github.com/actions/runner/releases/download/v2.330.0'
Stage 3: selection_child_setup_curl
selection_child_setup_curl:
CommandLine|contains|all:
- 'curl '
- '-fsSL'
- 'https://bun.sh/install'
- 'bash'
Stage 4: selection_child_path_reload
selection_child_path_reload:
CommandLine|contains|all:
- 'bash -c "source '
- '&& echo'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
CommandLine | match |
| field:"CommandLine" kind:match |
Image | ends_with |
| field:"Image" kind:ends_with value:"/bun" |
ParentImage | ends_with |
| field:"ParentImage" kind:ends_with value:"/node" |
SQL Server Dedicated Admin Connection (DAC) mode activated (native)
#Detects scenarios where an attacker enabled the DAC mode in order to bypass access controls, logon triggers, perform brute force attacks or run unauthorized queries.
Known False Positives
- Admin attempting to debug or recover a SQL Server
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Persistence |
Telemetry Coverage
| Provider | Record / event type |
|---|---|
| MSSQLSERVER | Event ID 15457 |
Rule Body
title: SQL Server Dedicated Admin Connection (DAC) mode activated (native)
description: Detects scenarios where an attacker enabled the DAC mode in order to bypass access controls, logon triggers, perform brute force attacks or run unauthorized queries.
references:
- https://josephpierini.blogspot.com/2012/07/microsoft-sql-dedicated-admin.html
- https://www.sqlshack.com/sql-server-dedicated-admin-connection-dac-how-to-enable-connect-and-use/
- https://www.mssqltips.com/sqlservertip/1801/enable-sql-server-dedicated-administrator-connection/
- https://docs.microsoft.com/en-us/sql/relational-databases/errors-events/database-engine-events-and-errors?view=sql-server-ver16
tags:
- attack.persistence
- attack.t1505.001
author: mdecrevoisier
status: experimental
logsource:
product: mssql
service: application
detection:
selection:
EventID: 15457
EventData|contains: '<Data>remote admin connections</Data><Data>0</Data><Data>1</Data>' # 0 is for previous status and 1 for new status
condition: selection
falsepositives:
- Admin attempting to debug or recover a SQL Server
level: high
Stages and Predicates
Stage 0: condition
selectionStage 1: selection
selection:
EventID: 15457
EventData|contains: '<Data>remote admin connections</Data><Data>0</Data><Data>1</Data>'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
EventData | match |
| field:"EventData" kind:match value:"<Data>remote admin connections</Data><Data>0</Data><Data>1</Data>" |
Suspicious IIS Module Registration
#Detects a suspicious IIS module registration as described in Microsoft threat report on IIS backdoors
Known False Positives
- Administrative activity
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Persistence |
Telemetry Coverage
| Provider | Record / event type |
|---|---|
| Sysmon | Event ID 1: Process creation |
| Security-Auditing | Event ID 4688: A new process has been created. |
Rule Body
title: Suspicious IIS Module Registration
id: 043c4b8b-3a54-4780-9682-081cb6b8185c
status: test
description: Detects a suspicious IIS module registration as described in Microsoft threat report on IIS backdoors
references:
- https://www.microsoft.com/security/blog/2022/07/26/malicious-iis-extensions-quietly-open-persistent-backdoors-into-servers/
author: Florian Roth (Nextron Systems), Microsoft (idea)
date: 2022-08-04
modified: 2023-01-23
tags:
- attack.persistence
- attack.t1505.004
logsource:
category: process_creation
product: windows
detection:
selection_parent:
ParentImage|endswith: '\w3wp.exe'
selection_cli_1:
CommandLine|contains: 'appcmd.exe add module'
selection_cli_2:
CommandLine|contains: ' system.enterpriseservices.internal.publish'
Image|endswith: '\powershell.exe'
selection_cli_3:
CommandLine|contains|all:
- 'gacutil'
- ' /I'
condition: selection_parent and 1 of selection_cli_*
falsepositives:
- Administrative activity
level: high
Stages and Predicates
Stage 0: condition
selection_parent and 1 of selection_cli_*Stage 1: selection_parent
selection_parent:
ParentImage|endswith: '\w3wp.exe'
Stage 2: selection_cli_1
selection_cli_1:
CommandLine|contains: 'appcmd.exe add module'
Stage 3: selection_cli_2
selection_cli_2:
CommandLine|contains: ' system.enterpriseservices.internal.publish'
Image|endswith: '\powershell.exe'
Stage 4: selection_cli_3
selection_cli_3:
CommandLine|contains|all:
- 'gacutil'
- ' /I'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
CommandLine | match |
| field:"CommandLine" kind:match |
Image | ends_with |
| field:"Image" kind:ends_with value:"\powershell.exe" |
ParentImage | ends_with |
| field:"ParentImage" kind:ends_with value:"\w3wp.exe" |
Sysmon File Executable Creation Detected
#Detects Portable Executable (PE) files creation events logged by Sysmon in paths monitored by the used Sysmon configuration. This is a high-value detection for catching unauthorized or suspicious executable drops. Alert volume and scope depend entirely on which paths or files are monitored in the Sysmon config. A high noise level or hits from known-legitimate software are a strong signal that the Sysmon configuration is too permissive, not that the detection itself is wrong and probably needs to be tuned to a more restrictive set of paths or files.
Known False Positives
- Legitimate software writing executables to monitored paths - if this occurs, narrow the Sysmon configuration to more sensitive paths rather than suppressing this rule
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Defense Impairment | No specific technique |
Telemetry Coverage
| Provider | Record / event type |
|---|---|
| Sysmon | Event ID 29: FileExecutableDetected |
Rule Body
title: Sysmon File Executable Creation Detected
id: 693a44e9-7f26-4cb6-b787-214867672d3a
status: test
description: |
Detects Portable Executable (PE) files creation events logged by Sysmon in paths monitored by the used Sysmon configuration.
This is a high-value detection for catching unauthorized or suspicious executable drops.
Alert volume and scope depend entirely on which paths or files are monitored in the Sysmon config.
A high noise level or hits from known-legitimate software are a strong signal that the Sysmon configuration is too permissive, not that the detection itself is wrong and probably needs to be tuned to a more restrictive set of paths or files.
references:
- https://learn.microsoft.com/en-us/sysinternals/downloads/sysmon
- https://medium.com/@olafhartong/sysmon-15-0-file-executable-detected-40fd64349f36
author: frack113
date: 2023-07-20
tags:
- attack.defense-impairment
logsource:
product: windows
service: sysmon
detection:
selection:
EventID: 29 # this is fine, we want to match any FileExecutableDetected event
condition: selection
falsepositives:
- Legitimate software writing executables to monitored paths - if this occurs, narrow the Sysmon configuration to more sensitive paths rather than suppressing this rule
level: medium
regression_tests_path: regression_data/rules/windows/sysmon/sysmon_file_executable_detected/info.yml
Stages and Predicates
Stage 0: condition
selectionStage 1: selection
selection:
EventID: 29
UAC Bypass Using Event Viewer RecentViews
#Detects the pattern of UAC Bypass using Event Viewer RecentViews
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Privilege Escalation | No specific technique |
| Stealth | No specific technique |
Telemetry Coverage
| Provider | Record / event type |
|---|---|
| Sysmon | Event ID 1: Process creation |
| Security-Auditing | Event ID 4688: A new process has been created. |
Rule Body
title: UAC Bypass Using Event Viewer RecentViews
id: 30fc8de7-d833-40c4-96b6-28319fbc4f6c
related:
- id: 63e4f530-65dc-49cc-8f80-ccfa95c69d43
type: similar
status: test
description: Detects the pattern of UAC Bypass using Event Viewer RecentViews
references:
- https://twitter.com/orange_8361/status/1518970259868626944
- https://lolbas-project.github.io/lolbas/Binaries/Eventvwr/#execute
author: Nasreddine Bencherchali (Nextron Systems)
date: 2022-11-22
tags:
- attack.privilege-escalation
- attack.stealth
logsource:
category: process_creation
product: windows
detection:
selection_path:
# Example: ysoserial.exe -o raw -f BinaryFormatter - g DataSet -c calc > RecentViews & copy RecentViews %LOCALAPPDATA%\Microsoft\EventV~1\RecentViews & eventvwr.exe
CommandLine|contains:
- '\Event Viewer\RecentViews'
- '\EventV~1\RecentViews'
selection_redirect:
CommandLine|contains: '>'
condition: all of selection_*
falsepositives:
- Unknown
level: high
Stages and Predicates
Stage 0: condition
all of selection_*Stage 1: selection_path
selection_path:
CommandLine|contains:
- '\Event Viewer\RecentViews'
- '\EventV~1\RecentViews'
Stage 2: selection_redirect
selection_redirect:
CommandLine|contains: '>'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
CommandLine | match |
| field:"CommandLine" kind:match |
Uncommon Child Process Of Setres.EXE
#Detects uncommon child process of Setres.EXE. Setres.EXE is a Windows server only process and tool that can be used to set the screen resolution. It can potentially be abused in order to launch any arbitrary file with a name containing the word "choice" from the current execution path.
Known False Positives
- Unlikely
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Stealth |
Telemetry Coverage
| Provider | Record / event type |
|---|---|
| Sysmon | Event ID 1: Process creation |
| Security-Auditing | Event ID 4688: A new process has been created. |
Rule Body
title: Uncommon Child Process Of Setres.EXE
id: 835e75bf-4bfd-47a4-b8a6-b766cac8bcb7
status: test
description: |
Detects uncommon child process of Setres.EXE.
Setres.EXE is a Windows server only process and tool that can be used to set the screen resolution.
It can potentially be abused in order to launch any arbitrary file with a name containing the word "choice" from the current execution path.
references:
- https://lolbas-project.github.io/lolbas/Binaries/Setres/
- https://twitter.com/0gtweet/status/1583356502340870144
- https://strontic.github.io/xcyclopedia/library/setres.exe-0E30E4C09637D7A128A37B59A3BC4D09.html
- https://docs.microsoft.com/en-us/previous-versions/windows/it-pro/windows-server-2012-r2-and-2012/cc731033(v=ws.11)
author: '@gott_cyber, Nasreddine Bencherchali (Nextron Systems)'
date: 2022-12-11
modified: 2024-06-26
tags:
- attack.stealth
- attack.t1218
- attack.t1202
logsource:
category: process_creation
product: windows
detection:
selection:
ParentImage|endswith: '\setres.exe'
Image|contains: '\choice'
filter_main_legit_location:
Image|endswith:
- 'C:\Windows\System32\choice.exe'
- 'C:\Windows\SysWOW64\choice.exe'
condition: selection and not 1 of filter_main_*
falsepositives:
- Unlikely
level: high
Stages and Predicates
Stage 0: condition
selection and not 1 of filter_main_*Stage 1: selection
selection:
ParentImage|endswith: '\setres.exe'
Image|contains: '\choice'
Stage 2: not filter_main_legit_location
filter_main_legit_location:
Image|endswith:
- 'C:\Windows\System32\choice.exe'
- 'C:\Windows\SysWOW64\choice.exe'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
Image | match |
| field:"Image" kind:match value:"\choice" |
ParentImage | ends_with |
| field:"ParentImage" kind:ends_with value:"\setres.exe" |
Exclusions
The rule actively suppresses these predicates.
| Field | Kind | Excluded values | Search |
|---|---|---|---|
Image | ends_with | C:\Windows\SysWOW64\choice.exe | excludes:Image field:"Image" value:"C:\Windows\SysWOW64\choice.exe" |
Image | ends_with | C:\Windows\System32\choice.exe | excludes:Image field:"Image" value:"C:\Windows\System32\choice.exe" |
VMGuestLib DLL Sideload
#Detects DLL sideloading of VMGuestLib.dll by the WmiApSrv service.
Known False Positives
- FP could occur if the legitimate version of vmGuestLib already exists on the system
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Execution | |
| Stealth |
Telemetry Coverage
| Provider | Record / event type |
|---|---|
| Sysmon | Event ID 7: Image loaded |
Rule Body
title: VMGuestLib DLL Sideload
id: 70e8e9b4-6a93-4cb7-8cde-da69502e7aff
status: test
description: Detects DLL sideloading of VMGuestLib.dll by the WmiApSrv service.
references:
- https://decoded.avast.io/martinchlumecky/png-steganography/
author: Nasreddine Bencherchali (Nextron Systems)
date: 2022-12-01
tags:
- attack.persistence
- attack.privilege-escalation
- attack.execution
- attack.stealth
- attack.t1574.001
logsource:
category: image_load
product: windows
detection:
selection:
ImageLoaded|contains|all:
- '\VMware\VMware Tools\vmStatsProvider\win32'
- '\vmGuestLib.dll'
Image|endswith: '\Windows\System32\wbem\WmiApSrv.exe'
filter:
Signed: 'true'
condition: selection and not filter
falsepositives:
- FP could occur if the legitimate version of vmGuestLib already exists on the system
level: medium
Stages and Predicates
Stage 0: condition
selection and not filterStage 1: selection
selection:
ImageLoaded|contains|all:
- '\VMware\VMware Tools\vmStatsProvider\win32'
- '\vmGuestLib.dll'
Image|endswith: '\Windows\System32\wbem\WmiApSrv.exe'
Stage 2: not filter
filter:
Signed: 'true'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
Image | ends_with |
| field:"Image" kind:ends_with value:"\Windows\System32\wbem\WmiApSrv.exe" |
ImageLoaded | match |
| field:"ImageLoaded" kind:match |
Exclusions
The rule actively suppresses these predicates.
| Field | Kind | Excluded values | Search |
|---|---|---|---|
Signed | eq | true | excludes:Signed field:"Signed" value:"true" |
Wget Creating Files in Tmp Directory
#Detects the use of wget to download content in a temporary directory such as "/tmp" or "/var/tmp"
Known False Positives
- Legitimate downloads of files in the tmp folder.
MITRE ATT&CK Coverage
| Tactic | Techniques |
|---|---|
| Command & Control |
Telemetry Coverage
| Platform | Record / event type |
|---|---|
| Linux | Event ID 11: File created |
Rule Body
title: Wget Creating Files in Tmp Directory
id: 35a05c60-9012-49b6-a11f-6bab741c9f74
status: test
description: Detects the use of wget to download content in a temporary directory such as "/tmp" or "/var/tmp"
references:
- https://blogs.jpcert.or.jp/en/2023/05/gobrat.html
- https://jstnk9.github.io/jstnk9/research/GobRAT-Malware/
- 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.command-and-control
- attack.t1105
logsource:
product: linux
category: file_event
detection:
selection:
Image|endswith: '/wget'
TargetFilename|startswith:
- '/tmp/'
- '/var/tmp/'
condition: selection
falsepositives:
- Legitimate downloads of files in the tmp folder.
level: medium
Stages and Predicates
Stage 0: condition
selectionStage 1: selection
selection:
Image|endswith: '/wget'
TargetFilename|startswith:
- '/tmp/'
- '/var/tmp/'
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
Image | ends_with |
| field:"Image" kind:ends_with value:"/wget" |
TargetFilename | starts_with |
| field:"TargetFilename" kind:starts_with |