Operator On The Wire
Join
← Back to Knowledge Base
BLUE TEAM / THREAT HUNT / ACTIVE DIRECTORY / COERCION

ShadowCoerce

This note documents detection patterns related to ShadowCoerce within Active Directory environments.


Direct Indicators

LogEvent IDMeaningForensic ValueNotes
Security4776NTLM authenticationCriticalMachine account authentication triggered via MS-FSRVP coercion.
Security4624Successful logonHighAuthentication event from coerced host after forced authentication.
Security4769Kerberos service ticket requestMediumService ticket activity following coerced authentication.
Security5140Network share accessedMediumSMB authentication events triggered by coercion attempt.
Sysmon3Network connectionCriticalOutbound SMB or HTTP connection from coerced host to attacker-controlled relay system.
Sysmon1Process creationMediumExecution of ShadowCoerce or related coercion tools.

Indirect Indicators

IndicatorWhat To Look ForForensic ValueNotes
Unexpected machine account authenticationComputer account authenticating to unknown hostCriticalTypical outcome of coercion attacks.
Domain controller outbound authenticationDC initiating SMB/HTTP authentication to external systemCriticalHighly suspicious behavior.
NTLM authentication followed by relay activityAuthentication immediately used against another serviceHighClassic NTLM relay chain.
Execution of coercion toolingProcesses associated with ShadowCoerce exploitationCriticalDirect evidence of attack execution.
Outbound authentication from serversServers authenticating to unknown machinesHighPossible forced authentication attempt.

Common Tools

ToolUsage
ShadowCoerceExploits MS-FSRVP protocol to force machine authentication.
ntlmrelayxRelays coerced NTLM authentication to other services.
CoercerFramework automating coercion attacks.
CrackMapExecUsed together with relay attacks.
ImpacketProvides relay and authentication abuse capabilities.

Relevant Artifacts

  • Domain controller Security logs (4624, 4776, 4769)
  • SMB authentication logs
  • Network traffic logs showing outbound authentication
  • Sysmon logs (1, 3)
  • EDR telemetry identifying coercion tools
  • Prefetch artifacts for ShadowCoerce execution
  • NTLM relay logs
  • Authentication logs on relay targets

MITRE ATT&CK References

  • T1187 Forced Authentication
  • T1557 Adversary-in-the-Middle
  • T1557.001 LLMNR/NBT-NS Poisoning and SMB Relay

Decision Tree

  1. Is the suspicious event present?
    • Identify machine account authentication events.
  2. What host generated the event?
    • Determine which system initiated authentication.
  3. Is the authentication expected?
    • Investigate whether the system normally authenticates to that destination.
  4. Pivot:
    • Source host → inspect execution of ShadowCoerce or coercion tooling.
    • Destination host → analyze relay attempts.
    • Network → inspect SMB/HTTP authentication flows.
  5. Confirm exploitation
    • Determine whether coerced authentication was relayed for privilege escalation.

Example Detection Templates

KQL

SecurityEvent
| where EventID == 4776
| where TargetUserName endswith "$"
DeviceNetworkEvents
| where RemotePort in (445,80,443)
| summarize count() by RemoteIP, InitiatingProcessAccountName, bin(TimeGenerated,5m)

EQL

any where event.code == "4776"

Sigma

title: Suspicious Machine Account Authentication via ShadowCoerce
id: shadowcoerce-detection
status: experimental
description: Detects machine account authentication possibly caused by ShadowCoerce coercion
logsource:
  product: windows
  service: security
detection:
  selection:
    EventID: 4776
  condition: selection
fields:
  - TargetUserName
  - Workstation
falsepositives:
  - Legitimate machine authentication
level: medium
tags:
  - attack.lateral_movement
  - attack.t1187

Mitigation & Hardening

Control AreaMitigationEffectivenessNotes
NTLM restrictionsDisable or restrict NTLM authenticationCriticalPrevents relay exploitation.
SMB signingRequire SMB signing across domainHighPrevents NTLM relay attacks.
Patch managementApply updates addressing FSRVP abuseHighReduces attack surface.
MonitoringAlert on machine account outbound authenticationHighDetects coercion attempts.
Network segmentationLimit SMB communication between serversMediumReduces relay opportunities.