Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions packages/@aws-cdk/aws-s3-notifications/test/queue.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ test('if the queue is encrypted with a custom kms key, the key resource policy i
},
{
Action: [
'kms:Decrypt',
'kms:Encrypt',
'kms:ReEncrypt*',
'kms:GenerateDataKey*',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -292,6 +292,7 @@
},
{
"Action": [
"kms:Decrypt",
"kms:Encrypt",
"kms:ReEncrypt*",
"kms:GenerateDataKey*"
Expand Down
5 changes: 2 additions & 3 deletions packages/@aws-cdk/aws-sqs/lib/queue-base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -194,9 +194,9 @@ export abstract class QueueBase extends Resource implements IQueue {
'sqs:GetQueueUrl');

if (this.encryptionMasterKey) {
this.encryptionMasterKey.grantEncrypt(grantee);
// kms:Decrypt necessary to execute grantsendMessages to an SSE enabled SQS queue
this.encryptionMasterKey.grantEncryptDecrypt(grantee);
}

return ret;
}

Expand Down Expand Up @@ -234,7 +234,6 @@ export abstract class QueueBase extends Resource implements IQueue {
});
}
}

/**
* Reference to a queue
*/
Expand Down
1 change: 1 addition & 0 deletions packages/@aws-cdk/aws-sqs/test/test.sqs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -272,6 +272,7 @@ export = {
},
{
'Action': [
'kms:Decrypt',
'kms:Encrypt',
'kms:ReEncrypt*',
'kms:GenerateDataKey*',
Expand Down