'Can IAM user be assumed from IAM Role within the same account?
We have an IAM user and an IAM Role in account A. The IAM user can access S3 bucket in account B but IAM role can't access it.
We want to access S3 bucket in account B with IAM role (We don't own account B hence don't want to bother the owner of account B)
Can we make IAM role to assume the IAM user within the same account A, and then access the S3 bucket in account B.
Solution 1:[1]
No, an IAM role cannot assume an IAM user. IAM users cannot be assumed. The only way to use the IAM user is to use the IAM user's credentials, either the API Key/Secret or the username/password via the console.
The best solution will be to have account B update the bucket policy to trust the account A root instead of a specific IAM user.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | cementblocks |
