Skip to content

add validation of KMS key state in S3#7786

Merged
bentsku merged 1 commit intomasterfrom
fix/7782
Mar 8, 2023
Merged

add validation of KMS key state in S3#7786
bentsku merged 1 commit intomasterfrom
fix/7782

Conversation

@bentsku
Copy link
Contributor

@bentsku bentsku commented Mar 2, 2023

As reported in #7782, we did not check the state of the KMS key when validating it.
Note that we need to set S3_SKIP_KMS_KEY_VALIDATION to 0 if we want this validation to be active, as we don't validate the existence of the KMS key per default, and only in the new provider (PROVIDER_OVERRIDE_S3=asf).

This PR implements the validation of the state and a AWS validated snapshot test, as well as a fix for the key format when returned (keyArn instead of just the keyId).

fixes #7782

@bentsku bentsku requested a review from macnev2013 as a code owner March 2, 2023 18:31
@bentsku bentsku temporarily deployed to localstack-ext-tests March 2, 2023 18:31 — with GitHub Actions Inactive
@github-actions
Copy link

github-actions bot commented Mar 2, 2023

LocalStack integration with Pro

       3 files  ±0         3 suites  ±0   1h 30m 27s ⏱️ - 2m 45s
1 780 tests +1  1 400 ✔️ ±0  380 💤 +1  0 ±0 
2 506 runs  +1  1 776 ✔️ ±0  730 💤 +1  0 ±0 

Results for commit 34d1560. ± Comparison against base commit 83d7780.

♻️ This comment has been updated with latest results.

@coveralls
Copy link

coveralls commented Mar 2, 2023

Coverage Status

Coverage: 85.068% (-0.01%) from 85.078% when pulling 34d1560 on fix/7782 into 83d7780 on master.

@bentsku bentsku temporarily deployed to localstack-ext-tests March 3, 2023 09:31 — with GitHub Actions Inactive
@bentsku bentsku temporarily deployed to localstack-ext-tests March 4, 2023 13:18 — with GitHub Actions Inactive
Copy link
Contributor

@macnev2013 macnev2013 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just have a minor doubt else LGTM ✨

@bentsku bentsku temporarily deployed to localstack-ext-tests March 6, 2023 08:11 — with GitHub Actions Inactive
@bentsku bentsku merged commit 62c2c90 into master Mar 8, 2023
@bentsku bentsku deleted the fix/7782 branch March 8, 2023 11:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug: Localstack S3 Allows put-object and get-object on KMS encrypted objects after the KMS Key is Disabled

3 participants