LG-10344 Opportunistically read multi-region KMS ciphertexts#9047
Merged
LG-10344 Opportunistically read multi-region KMS ciphertexts#9047
Conversation
We are in the midst of a migration to a new KMS key that support multi-region operations. This migration involves the following steps: 1. Start writing to new columns with the new key 2. Start reading from the new columns if they have a value and using the new key to decrypt them 3. Go through and convert old rows to the new key 4. Drop the old column This commit adds code and a feature flag to allow step 2. When then flag is enabled the IDP will try to use the multi-region column's ciphertext instead of the single-region ciphertext. Note that KMS does not require a key ID for decryption. It can determine that based on the KMS ciphertext it receives for decrypt. As a result the multi-region KMS client can be used to decrypt multi-region and single-region cihpertexts. [skip changelog]
Contributor
Author
|
I have this labelled WIP while I sort out tests |
Contributor
Author
|
I just got my tests updated. This should be ready for review |
soniaconnolly
approved these changes
Aug 22, 2023
Contributor
soniaconnolly
left a comment
There was a problem hiding this comment.
LGTM. Tested locally with read flag enabled create user and log in/out, IdV, and reset password and recover PII with personal key.
jmhooper
added a commit
that referenced
this pull request
Sep 11, 2023
The `aws_kms_multi_region_read_enabled` was in place to toggle the changes introduced in #9047. Those changes have been deployed, enabled, and have been running without issue for some time. This commit removes the tooling to toggle the feature since we will be using it going forward. [skip changelog]
jmhooper
added a commit
that referenced
this pull request
Sep 11, 2023
The `aws_kms_multi_region_read_enabled` was in place to toggle the changes introduced in #9047. Those changes have been deployed, enabled, and have been running without issue for some time. This commit removes the tooling to toggle the feature since we will be using it going forward. [skip changelog]
This was referenced Mar 5, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
We are in the midst of a migration to a new KMS key that support multi-region operations. This migration involves the following steps:
This commit adds code and a feature flag to allow step 2. When then flag is enabled the IDP will try to use the multi-region column's ciphertext instead of the single-region ciphertext.
Note that KMS does not require a key ID for decryption. It can determine that based on the KMS ciphertext it receives for decrypt. As a result the multi-region KMS client can be used to decrypt multi-region and single-region cihpertexts.