Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGrzegorz Bizon <grzesiek.bizon@gmail.com>2018-11-22 17:35:49 +0300
committerGrzegorz Bizon <grzesiek.bizon@gmail.com>2018-11-22 17:35:49 +0300
commit777b6713bb473d2e09c8340ab9a96373fdbaae50 (patch)
tree786e78f65c73daef684150844a9aa6054dfdb2d3 /lib/gitlab/crypto_helper.rb
parent8a235c0c05efec1c8ee14c7454982dc2b8ca9464 (diff)
Ensure that db encryption keys have proper bytesize
Diffstat (limited to 'lib/gitlab/crypto_helper.rb')
-rw-r--r--lib/gitlab/crypto_helper.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/gitlab/crypto_helper.rb b/lib/gitlab/crypto_helper.rb
index e85753c3a12..87a03d9c58f 100644
--- a/lib/gitlab/crypto_helper.rb
+++ b/lib/gitlab/crypto_helper.rb
@@ -6,8 +6,8 @@ module Gitlab
AES256_GCM_OPTIONS = {
algorithm: 'aes-256-gcm',
- key: Settings.attr_encrypted_db_key_base_truncated,
- iv: Settings.attr_encrypted_db_key_base_truncated[0..11]
+ key: Settings.attr_encrypted_db_key_base_32,
+ iv: Settings.attr_encrypted_db_key_base_12
}.freeze
def sha256(value)