Find IAM user by Access Key

Assuming the AWS command is installed and configured correctly

AWS_ACCESS_KEY=AKIAXXXXXXXXEXAMPLE

aws --output text iam list-users | awk '{print $NF}' | xargs -P10 -n1 aws --output text iam list-access-keys --user-name | grep ${AWS_ACCESS_KEY}

Comments

Popular posts from this blog

SSH Private Keys - RSA vs. OpenSSH

Google Wifi and Verizon FiOS