Sub topic 11
Trusted access and delegated administrators
This chapter assumes you know the management account and member account roles, how OUs work, and how to call the AWS CLI from the management account.
The problem: the management account does too much
Many AWS services can work across an organization. Examples are AWS Config, GuardDuty, CloudTrail and IAM Identity Center. By default, you would run them from the management account. That account sits outside the reach of service control policies (SCPs) and holds the power to create and close accounts. Security teams should not need to sign in to it daily.
Two features solve this:
- Trusted access lets a specific AWS service see your organization's structure and act in its member accounts.
- A delegated administrator is a member account that you register so it can manage that service for the whole organization.
Trusted access
Trusted access is off for every service until you turn it on. When you enable it, the service creates a service-linked role in each member account. The service uses that role to do its work there, so no one has to share credentials.
You can enable it from the service's console, which is the recommended path for most services. You can also use Organizations directly:
aws organizations enable-aws-service-access \
--service-principal config.amazonaws.com
aws organizations list-aws-service-access-for-organizationDisabling trusted access removes the service's ability to operate across the organization. Some services stop working or lose data, so check that service's documentation first.
Registering a delegated administrator
Run these commands from the management account. The account ID below belongs to a dedicated security account:
aws organizations register-delegated-administrator \
--account-id 444455556666 \
--service-principal config.amazonaws.com
aws organizations list-delegated-administrators \
--service-principal config.amazonaws.comSome services, such as GuardDuty and Security Hub, have their own enable-organization-admin-account call instead. Both paths give the same result: the member account becomes the service's administrator.
What a delegated administrator can and cannot do
A delegated administrator gets the service's organization-wide features, such as viewing findings from every account or deploying a rule to all of them. It does not get control of the organization. It cannot create accounts, attach SCPs, or change the hierarchy.
Keep these points in mind:
- Permissions are per service. An account that administers GuardDuty does not automatically administer Config.
- Registration is a one-time act, but the account still needs IAM permissions for its own users to use the service.
- Most services do not allow the management account itself to be the delegated administrator.
- Use dedicated accounts, such as Security or Log Archive, as administrators. Do not choose a workload account.
- SCPs apply to the delegated administrator account, as they do to any member account. An SCP that blocks the service's actions will break the administration.
Common errors
- "Service not enabled for organization": trusted access was never enabled. Enable it first, then register.
- Registration rejected: the service does not support delegation through Organizations. Use the service's own API.
- Missing accounts in the service: new accounts may need the service's auto-enable setting turned on.
Exercise
A team wants to run organization-wide GuardDuty from a member account called "security". Which two things must the management account do, and why not simply run GuardDuty from the management account?
Show answer
It must enable trusted access for the service and register the security account as the delegated administrator, or use the service's own enable-organization-admin-account call. Running it from the management account would mean people use that highly privileged account day to day, and SCPs cannot restrict it.