mirror of
https://github.com/coder/coder.git
synced 2025-07-03 16:13:58 +00:00
feat(coderd): connect dbcrypt package implementation (#9523)
See also: https://github.com/coder/coder/pull/9522 - Adds commands `server dbcrypt {rotate,decrypt,delete}` to re-encrypt, decrypt, or delete encrypted data, respectively. - Plumbs through dbcrypt in enterprise/coderd (including unit tests). - Adds documentation in admin/encryption.md. This enables dbcrypt by default, but the feature is soft-enforced on supplying external token encryption keys. Without specifying any keys, encryption/decryption is a no-op.
This commit is contained in:
@ -26,6 +26,7 @@ func TestDeploymentValues(t *testing.T) {
|
||||
cfg.OIDC.EmailField.Set("some_random_field_you_never_expected")
|
||||
cfg.PostgresURL.Set(hi)
|
||||
cfg.SCIMAPIKey.Set(hi)
|
||||
cfg.ExternalTokenEncryptionKeys.Set("the_random_key_we_never_expected,an_other_key_we_never_unexpected")
|
||||
|
||||
client := coderdtest.New(t, &coderdtest.Options{
|
||||
DeploymentValues: cfg,
|
||||
@ -44,6 +45,7 @@ func TestDeploymentValues(t *testing.T) {
|
||||
require.Empty(t, scrubbed.Values.OIDC.ClientSecret.Value())
|
||||
require.Empty(t, scrubbed.Values.PostgresURL.Value())
|
||||
require.Empty(t, scrubbed.Values.SCIMAPIKey.Value())
|
||||
require.Empty(t, scrubbed.Values.ExternalTokenEncryptionKeys.Value())
|
||||
}
|
||||
|
||||
func TestDeploymentStats(t *testing.T) {
|
||||
|
Reference in New Issue
Block a user