Skip to content

Get inline policies that are embedded in the specified IAM group are return Empty (For Roles too) #338

Answered by ashishdhingra
Fanch44step asked this question in Q&A
Discussion options

You must be logged in to vote

@Fanch44step Good morning. Thanks for opening the issue. Get-IAMGroupPolicyList invokes the service API operation ListGroupPolicies which lists the names of the inline policies that are embedded in the specified IAM group. However, per details shared in the issue, you attached the IAM policy with specified ARN using Register-IAMGroupPolicy; in other words, you did not embed an inline policy.

To list attached policy, you should use Get-IAMAttachedGroupPolicyList CmdLet instead. I tested this at my end after created an IAM group named testgroup via AWS Console. The results are shown below:

PS> Get-IAMGroup -GroupName testgroup

Group                                 IsTruncated Marker Users
-…

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
1 reply
@Fanch44step
Comment options

Answer selected by ashishdhingra
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
2 participants
Converted from issue

This discussion was converted from issue #337 on January 11, 2024 17:09.