feat: Adds CreateKey API to create a branch key#1645
Closed
sharmabikram wants to merge 11 commits intoshbikram/create-version-keyfrom
Closed
feat: Adds CreateKey API to create a branch key#1645sharmabikram wants to merge 11 commits intoshbikram/create-version-keyfrom
sharmabikram wants to merge 11 commits intoshbikram/create-version-keyfrom
Conversation
texastony
requested changes
Mar 16, 2026
| }) | ||
|
|
||
| describe('CreateKey + VersionKey lifecycle', () => { | ||
| it('Create, retrieve, version, retrieve new, retrieve old', async () => { |
Contributor
There was a problem hiding this comment.
Blocking: do this test with custom EC and assert that EC is preserved by version.
Contributor
Author
There was a problem hiding this comment.
Adding test in next revision. However, the EC will have a prefix "aws-crypto-ec:". This is due to fact that JS implementation of getActiveBranchKey never stripped this prefix as we do in our Dafny implementation.
texastony
reviewed
Mar 17, 2026
Comment on lines
+352
to
+353
| // NOTE: The Dafny implementation strips the `aws-crypto-ec:` prefix | ||
| // from keys before returning (see ExtractCustomEncryptionContext in Structure.dfy). |
Contributor
There was a problem hiding this comment.
Suggested change
| // NOTE: The Dafny implementation strips the `aws-crypto-ec:` prefix | |
| // from keys before returning (see ExtractCustomEncryptionContext in Structure.dfy). | |
| // NOTE: The Dafny implementation strips the `aws-crypto-ec:` prefix | |
| // from keys before returning (see ExtractCustomEncryptionContext in Structure.dfy). | |
| // This implementation DOES NOT strip the `aws-crypto-ec:` prefix; | |
| // the initial "read-only" implementation in JS made this choice and it is a breaking change | |
| // to address it now. |
texastony
approved these changes
Mar 17, 2026
Contributor
texastony
left a comment
There was a problem hiding this comment.
@sharmabikram José is back tomorrow and I would like to talk to him about the EC treatment.
I am approving this PR, but can we hold off on merging until we talk to @josecorella ?
… before creating the branch key material node object (#1650)
BREAKING CHANGE: The AWS Encryption SDK for JavaScript no longer supports Internet Explorer 11 (IE11). The msCrypto shim and related IE11 detection code have been removed from the web-crypto-backend module. Co-authored-by: Lucas McDonald <lucmcdon@amazon.com>
* feat: Adds VersionKey API to version the branch key * fix: removes console log which caused the lint failures --------- Co-authored-by: Bikram Sharma <shbikram@amazon.com>
…ersioning a branch key
…and JavaScript implementation
…ain internal prefix
2a7c741 to
08154ba
Compare
Contributor
Author
|
Will create a new branch and raise another PR. |
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.
Issue #, if available:
Description of changes:
This change adds createKey API which creates a branch key following the spec: https://github.com/awslabs/aws-encryption-sdk-specification/blob/6fd8f886f708afeb89bcfb2a618ca57bb2bd48cd/framework/branch-key-store.md#createkey
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
Check any applicable: