Skip to content

Commit 94a70f0

Browse files
feat: Tighten KMS key policy (#42)
* feat: Tighten KMS key policy * fix: remove put key policy * other changes --------- Co-authored-by: Josh Stevens <[email protected]>
1 parent 6714ac0 commit 94a70f0

File tree

2 files changed

+19
-2
lines changed

2 files changed

+19
-2
lines changed

crates/core/src/wallet/aws_kms_wallet_manager.rs

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -221,11 +221,26 @@ impl AwsKmsWalletManager {
221221
"Sid": "AllowRootAccountAccess",
222222
"Effect": "Allow",
223223
"Principal": { "AWS": format!("arn:aws:iam::{}:root", account_id) },
224-
"Action": "kms:*",
224+
"Action": [
225+
"kms:DescribeKey",
226+
"kms:ListAliases",
227+
"kms:ListKeyPolicies",
228+
"kms:GetKeyPolicy",
229+
"kms:CreateAlias",
230+
"kms:DeleteAlias",
231+
"kms:ScheduleKeyDeletion",
232+
"kms:CancelKeyDeletion",
233+
"kms:EnableKey",
234+
"kms:DisableKey",
235+
"kms:EnableKeyRotation",
236+
"kms:DisableKeyRotation",
237+
"kms:RevokeGrant",
238+
"kms:RetireGrant"
239+
],
225240
"Resource": "*"
226241
},
227242
{
228-
"Sid": "AllowAdminPrincipalSelf",
243+
"Sid": "AllowRelayerFullControl",
229244
"Effect": "Allow",
230245
"Principal": { "AWS": admin_principal_arn },
231246
"Action": "kms:*",

documentation/rrelayer/docs/pages/changelog.mdx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@
66

77
### Features
88

9+
- feat: Tighten KMS key policy
10+
911
---
1012

1113
### Bug fixes

0 commit comments

Comments
 (0)