List permission boundaries aws

680 Views Asked by At

There are methods to list inline policies, user managed policies and aws managed policies etc

I couldn't find one to list the boundaries attached to a user.

I suppose there could be a way to add tags with users/boundaries to the policy and search for policies that have the certain tags.

There is no particular use case here, just wondering if I'd want to get the boundaries for that user, what would be a way to do it.

1

There are 1 best solutions below

0
On BEST ANSWER

At a time, you can attach only one permissions boundary to an IAM user. Basically, a permissions boundary is just a managed policy. To retrieve the permissions boundary attached to an IAM user, you can make use of the GetUser call. This will return you the ARN of the managed policy attached as a permissions boundary. To view the JSON of the policy, you would have to subsequently call GetPolicy to retrieve the policy version in use, and then call GetPolicyVersion.

Seems to be the only way to go about it via API/CLI.