Adversaries may modify the configuration settings of a domain or identity tenant to evade defenses and/or escalate privileges in centrally managed environments. Such services provide a centralized means of managing identity resources such as devices and accounts, and often include configuration settings that may apply between domains or tenants such as trust relationships, identity syncing, or identity federation.

Modifications to domain or tenant settings may include altering domain Group Policy Objects (GPOs) in Microsoft Active Directory (AD) or changing trust settings for domains, including federation trusts relationships between domains or tenants.

With sufficient permissions, adversaries can modify domain or tenant policy settings. Since configuration settings for these services apply to a large number of identity resources, there are a great number of potential attacks malicious outcomes that can stem from this abuse. Examples of such abuse include:  

* modifying GPOs to push a malicious [Scheduled Task](https://attack.mitre.org/techniques/T1053/005) to computers throughout the domain environment(Citation: ADSecurity GPO Persistence 2016)(Citation: Wald0 Guide to GPOs)(Citation: Harmj0y Abusing GPO Permissions)
* modifying domain trusts to include an adversary-controlled domain, allowing adversaries to  forge access tokens that will subsequently be accepted by victim domain resources(Citation: Microsoft - Customer Guidance on Recent Nation-State Cyber Attacks)
* changing configuration settings within the AD environment to implement a [Rogue Domain Controller](https://attack.mitre.org/techniques/T1207).
* adding new, adversary-controlled federated identity providers to identity tenants, allowing adversaries to authenticate as any user managed by the victim tenant (Citation: Okta Cross-Tenant Impersonation 2023)

Adversaries may temporarily modify domain or tenant policy, carry out a malicious action(s), and then revert the change to remove suspicious indicators.
Domain or Tenant Policy Modification
source_name: mitre-attack  url: https://attack.mitre.org/techniques/T1484  external_id: T1484     source_name: CISA SolarWinds Cloud Detection  description: CISA. (2021, January 8). Detecting Post-Compromise Threat Activity in Microsoft Cloud Environments. Retrieved January 8, 2021.  url: https://us-cert.cisa.gov/ncas/alerts/aa21-008a     source_name: ADSecurity GPO Persistence 2016  description: Metcalf, S. (2016, March 14). Sneaky Active Directory Persistence #17: Group Policy. Retrieved March 5, 2019.  url: https://adsecurity.org/?p=2716     source_name: Microsoft 365 Defender Solorigate  description: Microsoft 365 Defender Team. (2020, December 28). Using Microsoft 365 Defender to protect against Solorigate. Retrieved January 7, 2021.  url: https://www.microsoft.com/security/blog/2020/12/28/using-microsoft-365-defender-to-coordinate-protection-against-solorigate/     source_name: Microsoft - Azure Sentinel ADFSDomainTrustMods  description: Microsoft. (2020, December). Azure Sentinel Detections. Retrieved December 30, 2020.  url: https://github.com/Azure/Azure-Sentinel/blob/master/Detections/AuditLogs/ADFSDomainTrustMods.yaml     source_name: Microsoft - Update or Repair Federated domain  description: Microsoft. (2020, September 14). Update or repair the settings of a federated domain in Office 365, Azure, or Intune. Retrieved December 30, 2020.  url: https://docs.microsoft.com/en-us/office365/troubleshoot/active-directory/update-federated-domain-office-365     source_name: Microsoft - Customer Guidance on Recent Nation-State Cyber Attacks  description: MSRC. (2020, December 13). Customer Guidance on Recent Nation-State Cyber Attacks. Retrieved December 30, 2020.  url: https://msrc-blog.microsoft.com/2020/12/13/customer-guidance-on-recent-nation-state-cyber-attacks/     source_name: Okta Cross-Tenant Impersonation 2023  description: Okta Defensive Cyber Operations. (2023, August 31). Cross-Tenant Impersonation: Prevention and Detection. Retrieved February 15, 2024.  url: https://sec.okta.com/articles/2023/08/cross-tenant-impersonation-prevention-and-detection     source_name: Wald0 Guide to GPOs  description: Robbins, A. (2018, April 2). A Red Teamer’s Guide to GPOs and OUs. Retrieved March 5, 2019.  url: https://wald0.com/?p=179     source_name: Harmj0y Abusing GPO Permissions  description: Schroeder, W. (2016, March 17). Abusing GPO Permissions. Retrieved March 5, 2019.  url: http://www.harmj0y.net/blog/redteaming/abusing-gpo-permissions/     source_name: Sygnia Golden SAML  description: Sygnia. (2020, December). Detection and Hunting of Golden SAML Attack. Retrieved January 6, 2021.  url: https://www.sygnia.co/golden-saml-advisory     