AWS - Roles (Assume Role)
Step 1: Create the Role
Sign in to the AWS Management Console.
Navigate to IAM > Roles.
Click Create role.
Select Another AWS account under "Trusted entity" and enter the Account ID of the trusted account.
Choose the permissions for the role (either attach policies directly or use a custom policy).
Provide a Role name and click Create role.
Step 2: Grant Permissions to Assume the Role
In the Account that will assume the role, go to IAM > Policies.
Create or select a policy that grants the
sts:AssumeRole
action on the role.Attach the policy to the IAM user or group that needs to assume the role.
Step 3: Assume the Role
In the trusted account, use the AWS CLI, SDK, or Console to assume the role
POC :
Last updated