-
Notifications
You must be signed in to change notification settings - Fork 507
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
exp/services/recoverysigner: add encrypt and decrypt commands (#2746)
What This PR adds two sub-commands encrypt and decrypt to encryption-tink-keyset to encrypt a cleartext keyset private or to decrypt an encrypted keyset private. Why I was planning on adding a sub-command reencrypt. However, I realized there's no way for someone who started the recovery signer with a cleartext keyset private without configuring encryption-kms-key-uri to encrypt the keyset later on, so I decided to add two sub-commands: encrypt and decrypt. For someone who wants to make the system more secure by configuring the encryption-kms-key-uri at a later point in time, she can use the encrypt command to do so; for someone who wants to re-encrypt the keyset after rotating the KMS key, she can first use decrypt to get the cleartext keyset if no backup is available, then use encrypt to get a new encrypted keyset.
- Loading branch information
Showing
4 changed files
with
192 additions
and
25 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
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