Detection rules › Sigma
PSexec execution over SMB share
Detects scenarios where an attacker execute PSexec on a remote host via SMB
MITRE ATT&CK coverage
| Tactic | Techniques |
|---|---|
| Lateral Movement | T1021.002 Remote Services: SMB/Windows Admin Shares |
Event coverage
| Provider | Event | Title |
|---|---|---|
| Security-Auditing | Event ID 5145 | A network share object was checked to see whether client can be granted desired access. |
Rule body yaml
title: PSexec execution over SMB share
description: Detects scenarios where an attacker execute PSexec on a remote host via SMB
references:
- https://github.com/mdecrevoisier/EVTX-to-MITRE-Attack/tree/master/TA0008-Lateral%20Movement/T1021.002%20-SMB%20Windows%20Admin%20Shares
- https://attack.mitre.org/software/S0029/
- https://pentera.io/blog/135-is-the-new-145/
- https://nv2lt.github.io/windows/smb-psexec-smbexec-winexe-how-to/
- https://www.synacktiv.com/publications/traces-of-windows-remote-command-execution.html
tags:
- attack.lateral_movement
- attack.t1021.002
author: mdecrevoisier
status: experimental
logsource:
product: windows
service: security
detection:
selection:
EventID: 5145
ShareName:
- '\\*\ADMIN$'
- '\\*\IPC$'
RelativeTargetName|contains: PSEXESVC
filter:
SubjectUserName: '%admin_account%'
condition: selection and not filter
falsepositives:
- Administrator activity
level: medium
Stages and Predicates
Stage 0: condition
selection and not filterStage 1: selection
selection:
EventID: 5145
ShareName:
- '\\*\ADMIN$'
- '\\*\IPC$'
RelativeTargetName|contains: PSEXESVC
Stage 2: not filter
filter:
SubjectUserName: '%admin_account%'
Exclusions
Top-level NOT(...) conjuncts: predicates this rule actively suppresses.
| Field | Kind | Excluded values |
|---|---|---|
SubjectUserName | eq | %admin_account% |
Indicators
Each row is a field, operator, and value that the rule matches. The corpus column counts how many other rules in the catalog look for the same combination: high numbers point to widely-used, community-vetted indicators. Blank or 1 shows that the indicator is specific to this rule.
| Field | Kind | Values |
|---|---|---|
RelativeTargetName | match |
|
ShareName | wildcard |
|