2 Answers
- Newest
- Most votes
- Most comments
3
try this one
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "VisualEditor0",
"Effect": "Allow",
"Action": [
"iam:RemoveUserFromGroup",
"iam:DeleteSigningCertificate",
"iam:DeleteUserPolicy",
"iam:ListUserPolicies",
"iam:ListGroupsForUser",
"iam:DeleteAccessKey",
"iam:DeleteSSHPublicKey",
"iam:DeleteServiceSpecificCredential",
"iam:DeleteLoginProfile",
"iam:GetUser",
"iam:ListAttachedUserPolicies",
"iam:ListUserTags",
"iam:DetachUserPolicy",
"iam:DeleteUser",
"iam:ListUsers",
"iam:DeleteVirtualMFADevice"
],
"Resource": "*"
}
]
}
0
The above policy should work.
To ensure comprehensive user deletion, it's imperative to account for all associated resources and credentials. This includes Attached Managed Policies, Inline Policies, Access Keys, Group Associations, Tags, Signing Certificates, and CodeCommit SSH Credentials. Please refer to the updated policy guidelines as detailed in the AWS documentation here - https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_delegate-permissions_examples.html#creds-policies-users
answered 4 months ago
Relevant content
- asked a year ago
- asked 8 months ago
- asked 5 months ago
- AWS OFFICIALUpdated 2 months ago
- AWS OFFICIALUpdated a year ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated 2 months ago
please accept the answer if it was helpful