AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.
Get-IAMAttachedRolePolicyList-RoleName <String>-PathPrefix <String>-Marker <String>-MaxItem <Int32>-Select <String>-NoAutoIteration <SwitchParameter>
MaxItems
and Marker
parameters. You can use the PathPrefix
parameter to limit the list of policies to only those matching the specified path prefix. If there are no policies attached to the specified role (or none that match the specified path prefix), the operation returns an empty list. Marker
element in the response that you received to indicate where the next call should start.Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Aliases | NextToken |
IsTruncated
response element is true
.If you do not include this parameter, the number of items defaults to 100. Note that IAM might return fewer results, even when there are more results available. In that case, the IsTruncated
response element returns true
, and Marker
contains a value to include in the subsequent call that tells the service where to continue from.Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Aliases | MaxItems |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
\u0021
) through the DEL character (\u007F
), including most punctuation characters, digits, and upper and lowercased letters. Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Required? | True |
Position? | 2 |
Accept pipeline input? | True (ByPropertyName) |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Aliases | AK |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByValue, ByPropertyName) |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByValue, ByPropertyName) |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Aliases | AWSProfilesLocation, ProfilesLocation |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Aliases | StoredCredentials, AWSProfileName |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Aliases | RegionToCall |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Aliases | SK, SecretAccessKey |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Aliases | ST |
Get-IAMAttachedRolePolicyList -RoleName "SecurityAuditRole"
PolicyArn PolicyName
--------- ----------
arn:aws:iam::aws:policy/SecurityAudit SecurityAudit
This command returns the names and ARNs of the managed policies attached to the IAM role namedSecurityAuditRole
in the AWS account. To see the list of inline policies that are embedded in the role, use theGet-IAMRolePolicyList
command.
AWS Tools for PowerShell: 2.x.y.z