forked from tink-crypto/tink
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implement an option to specify the name used in the AWS KMS Encryptio…
…nContext. This provides a solution to the ciphertext incompatibility problem described in tink-crypto#568. In particular, the EncryptionContextName can now be set to "associatedData", which aligns with the Tink KMS extensions in other languages. It is made an option to avoid stranding old ciphertexts. To facilitate this new option, a new awsClient factory function, NewClientWithOptions(), is implemented which accepts functional options. Options are introduced to cover all of the capabilities of the existing factory functions, which are now deprecated. When using NewClientWithOptions() the default EncryptionContextName is AssociatedData. When using any of the deprecated factory functions, the default EncryptionContextName is LegacyAdditionalData. This provides balance between not breaking existing usages and encourages migration from the deprecated functions. PiperOrigin-RevId: 537147115
- Loading branch information
1 parent
483e80b
commit d820737
Showing
3 changed files
with
366 additions
and
40 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Oops, something went wrong.