Skip to content

Commit

Permalink
Merge pull request #1818 from alphagov/sengi/powerusers-only-change-o…
Browse files Browse the repository at this point in the history
…wn-keys

`poweruser` roles should only allow rotating the user's own keys.
  • Loading branch information
sengi authored Feb 13, 2024
2 parents 5c95aa6 + 0ad58c9 commit 55a3b49
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions terraform/projects/infra-security/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -260,9 +260,7 @@ data "aws_iam_policy_document" "allow-iam-key-rotation" {
"iam:ListAccessKeys",
"iam:UpdateAccessKey",
]

effect = "Allow"
resources = ["*"]
resources = ["arn:aws:iam::*:user/&{aws:username}"]
}
}

Expand Down

0 comments on commit 55a3b49

Please sign in to comment.