VeriKQL by Kaushik Saha

T1199 Trusted Relationship

Initial Accesson attack.mitre.org

ATT&CK Enterprise 20.0 · 20.1 released, update in review

How MITRE detects it

DET0488 Detect abuse of Trusted Relationships (third-party and delegated admin access)

AN1344 Windows

Behavioral chain: (1) a login from a third-party account or untrusted source network establishes an interactive/remote session; (2) the session acquires elevated privileges or accesses sensitive resources atypical for that account; (3) subsequent lateral movement or data access occurs from the same session/device. Correlate Windows logon events, token elevation/privileged use, and resource access with third-party context.

MITRE log sourceIn Microsoft Sentinel
WinEventLog:SecurityEventCode=4624, 4648
  • Windows Security Events via AMA → SecurityEvent
    SecurityEvent | where EventID in (4624, 4648)
  • Security Events via Legacy Agent → SecurityEvent
    SecurityEvent | where EventID in (4624, 4648)
  • Windows Forwarded Events → WindowsEvent
    WindowsEvent | where Channel == "Security" | where EventID in (4624, 4648)

The same events land in SecurityEvent (Windows Security Events connectors) or WindowsEvent (Windows Event Forwarding); many built-in rules read SecurityEvent only.

WinEventLog:SecurityEventCode=4776, 4771, 4770
  • Windows Security Events via AMA → SecurityEvent
    SecurityEvent | where EventID in (4776, 4771, 4770)
  • Security Events via Legacy Agent → SecurityEvent
    SecurityEvent | where EventID in (4776, 4771, 4770)
  • Windows Forwarded Events → WindowsEvent
    WindowsEvent | where Channel == "Security" | where EventID in (4776, 4771, 4770)

The same events land in SecurityEvent (Windows Security Events connectors) or WindowsEvent (Windows Event Forwarding); many built-in rules read SecurityEvent only.

WinEventLog:SysmonEventCode=3, 22
  • Windows event logs (Azure Monitor Agent) → Event
    Event | where Source == "Microsoft-Windows-Sysmon" | where EventID in (3, 22)
  • Windows Forwarded Events → WindowsEvent
    WindowsEvent | where Provider == "Microsoft-Windows-Sysmon" | where EventID in (3, 22)

Sysmon has no dedicated Sentinel connector: it is collected as a Windows event log into Event or WindowsEvent.

WinEventLog:SecurityEventCode=4663, 4670, 4656
  • Windows Security Events via AMA → SecurityEvent
    SecurityEvent | where EventID in (4663, 4670, 4656)
  • Security Events via Legacy Agent → SecurityEvent
    SecurityEvent | where EventID in (4663, 4670, 4656)
  • Windows Forwarded Events → WindowsEvent
    WindowsEvent | where Channel == "Security" | where EventID in (4663, 4670, 4656)

The same events land in SecurityEvent (Windows Security Events connectors) or WindowsEvent (Windows Event Forwarding); many built-in rules read SecurityEvent only.

AN1345 Linux

Behavioral chain: (1) sshd or federated SSO logins from third-party networks or identities; (2) rapid sudo/su privilege elevation; (3) access to sensitive paths or east-west SSH. Correlate auth logs, process execution, and network flows.

MITRE log sourceIn Microsoft Sentinel
auditd:SYSCALLexecve,socket,connect,openatNot mapped to Sentinel yet.
linux:syslogAccepted publickey/password for * from * port * ssh2Not mapped to Sentinel yet.
NSM:Flowssh connections originating from third-party CIDRsNot mapped to Sentinel yet.

AN1346 macOS

Behavioral chain: (1) third-party interactive login or mobileconfig-based device enrollment; (2) privilege use or admin group change; (3) lateral movement mounts/ssh. Correlate unified logs and network telemetry.

MITRE log sourceIn Microsoft Sentinel
macos:unifiedlogloginwindow or sshd successful login eventsNot mapped to Sentinel yet.
macos:unifiedlogGroup membership change for admin or wheelNot mapped to Sentinel yet.
NSM:Flowssh/smb connections to internal resources from third-party devicesNot mapped to Sentinel yet.

AN1347 Identity Provider

Behavioral chain: (1) delegated admin or external identity establishes session (e.g., partner/reseller DAP, B2B guest, SAML/OAuth trust); (2) role elevation or app consent/permission grant; (3) downstream privileged actions in the tenant. Correlate IdP sign-in, admin/role assignment, and consent/admin-on-behalf events.

MITRE log sourceIn Microsoft Sentinel
azure:signinlogsInteractiveUser, ServicePrincipalSignIn
  • Microsoft Entra ID → SigninLogs
    SigninLogs
  • Microsoft Entra ID → AADNonInteractiveUserSignInLogs
    AADNonInteractiveUserSignInLogs
  • Microsoft Entra ID → AADServicePrincipalSignInLogs
    AADServicePrincipalSignInLogs
  • Microsoft Entra ID → AADManagedIdentitySignInLogs
    AADManagedIdentitySignInLogs
azure:auditAdd delegated admin / Assign admin roles / Update application consent
  • Microsoft Entra ID → AuditLogs
    AuditLogs
m365:unifiedSet-PartnerOfRecord / CompanyAdministrator role assignments / New-DelegatedAdminRelationshipinterpreted
  • Microsoft 365 (formerly Office 365) → OfficeActivity
    OfficeActivity | where OfficeWorkload in ("Exchange", "SharePoint", "OneDrive", "MicrosoftTeams")
  • Microsoft Defender XDR → CloudAppEvents
    CloudAppEvents

The Office 365 connector brings the Exchange, SharePoint and Teams workloads of the unified audit log; Entra sign-ins in it are in SigninLogs; CloudAppEvents carries Microsoft 365 app activity.

AN1348 IaaS

Behavioral chain: (1) cross-account or third-party principal assumes a role into the tenant/subscription/project; (2) privileged API calls are made in short succession; (3) access originates from unfamiliar networks or geos. Correlate assume-role/federation events with sensitive API usage.

MITRE log sourceIn Microsoft Sentinel
AWS:CloudTrailAssumeRole,AssumeRoleWithSAML,AssumeRoleWithWebIdentityNot mapped to Sentinel yet.
AWS:CloudTrailCreateUser|AttachRolePolicy|CreateAccessKey|UpdateAssumeRolePolicy|CreateLoginProfileNot mapped to Sentinel yet.
gcp:auditgoogle.iam.credentials.generateAccessToken / serviceAccountTokenCreatorNot mapped to Sentinel yet.

AN1349 SaaS

Behavioral chain: (1) third-party app or admin connects via OAuth/marketplace install; (2) high-privilege scopes granted; (3) anomalous actions (mass read/exports, admin changes).

MITRE log sourceIn Microsoft Sentinel
saas:googleworkspaceOAuth2 authorization grants / Admin role assignmentsNot mapped to Sentinel yet.
saas:salesforceConnectedApp OAuth policy change / Login as userNot mapped to Sentinel yet.

AN1350 Office Suite

Behavioral chain: (1) delegated administration offers/relationships created or modified by partner tenants; (2) mailbox delegation/impersonation enabled; (3) follow-on access from partner IPs.

MITRE log sourceIn Microsoft Sentinel
m365:unifiedAdd-DelegatedAdmin, Set-PartnerOfRecord, Add-MailboxPermission, Set-OrganizationRelationshipinterpreted
  • Microsoft 365 (formerly Office 365) → OfficeActivity
    OfficeActivity | where OfficeWorkload in ("Exchange", "SharePoint", "OneDrive", "MicrosoftTeams")
  • Microsoft Defender XDR → CloudAppEvents
    CloudAppEvents

The Office 365 connector brings the Exchange, SharePoint and Teams workloads of the unified audit log; Entra sign-ins in it are in SigninLogs; CloudAppEvents carries Microsoft 365 app activity.

azure:signinlogsInteractiveUser, NonInteractiveUser
  • Microsoft Entra ID → SigninLogs
    SigninLogs
  • Microsoft Entra ID → AADNonInteractiveUserSignInLogs
    AADNonInteractiveUserSignInLogs
  • Microsoft Entra ID → AADServicePrincipalSignInLogs
    AADServicePrincipalSignInLogs
  • Microsoft Entra ID → AADManagedIdentitySignInLogs
    AADManagedIdentitySignInLogs

Content Hub rules tagged with it (6)

Rules tagged with this technique (or a sub-technique) in their metadata. Whether one fits your connectors is the coverage view (M2).

How the Content Hub rules for T1199 are built: their tables, filters, joins, schedules and windows.

In Sigma rules

1 SigmaHQ community rule name it or one of its sub-techniques in their tags.

Community rules, not Microsoft's, and not checked by VeriKQL (Sigma is not KQL). From SigmaHQ/sigma at f083329, under the Detection Rule License (DRL) 1.1; each rule is credited to its author.

Mitigations

MITRE ATT&CK® is a registered trademark of The MITRE Corporation. VeriKQL is not affiliated with or endorsed by MITRE. ATT&CK data © The MITRE Corporation, used under its terms of use.