Created
May 17, 2016 11:07
-
-
Save rob-murray/7a9329dab1fe173f68a0b98c707fe289 to your computer and use it in GitHub Desktop.
List AWS IAM user accounts - assuming you have AWS Command Line Interface installed
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# usage: list_aws_users.sh > list_aws_users.txt | |
# requirements: AWS Command Line Interface | |
# output: ACCESSKEYMETADATA ACCESS_KEY_ID last_used_at Active|Inactive access_key_name | |
# | |
for user in $(aws iam list-users --output text | awk '{print $NF}'); do | |
aws iam list-access-keys --user $user --output text | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment