mirror of
https://github.com/meineerde/redmine.git
synced 2025-12-20 15:31:12 +00:00
git-svn-id: http://svn.redmine.org/redmine/trunk@20005 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
9b1b10620b
commit
28dd747fc6
@ -138,11 +138,12 @@ default:
|
||||
# scm_stderr_log_file: /var/log/redmine_scm_stderr.log
|
||||
scm_stderr_log_file:
|
||||
|
||||
# Key used to encrypt sensitive data in the database (SCM and LDAP passwords).
|
||||
# Key used to encrypt sensitive data in the database (SCM passwords,
|
||||
# LDAP passwords, and TOTP (two-factor authentication) secret keys).
|
||||
# If you don't want to enable data encryption, just leave it blank.
|
||||
# WARNING: losing/changing this key will make encrypted data unreadable.
|
||||
#
|
||||
# If you want to encrypt existing passwords in your database:
|
||||
# If you want to encrypt existing data in your database:
|
||||
# * set the cipher key here in your configuration file
|
||||
# * encrypt data using 'rake db:encrypt RAILS_ENV=production'
|
||||
#
|
||||
@ -150,7 +151,7 @@ default:
|
||||
# * decrypt data using 'rake db:decrypt RAILS_ENV=production' first
|
||||
# * change the cipher key here in your configuration file
|
||||
# * encrypt data using 'rake db:encrypt RAILS_ENV=production'
|
||||
database_cipher_key:
|
||||
database_cipher_key: 'foo'
|
||||
|
||||
# Set this to false to disable plugins' assets mirroring on startup.
|
||||
# You can use `rake redmine:plugins:assets` to manually mirror assets
|
||||
|
||||
@ -20,7 +20,8 @@ namespace :db do
|
||||
desc 'Encrypts SCM and LDAP passwords in the database.'
|
||||
task :encrypt => :environment do
|
||||
unless (Repository.encrypt_all(:password) &&
|
||||
AuthSource.encrypt_all(:account_password))
|
||||
AuthSource.encrypt_all(:account_password) &&
|
||||
User.encrypt_all(:twofa_totp_key))
|
||||
raise "Some objects could not be saved after encryption, update was rolled back."
|
||||
end
|
||||
end
|
||||
@ -28,7 +29,8 @@ namespace :db do
|
||||
desc 'Decrypts SCM and LDAP passwords in the database.'
|
||||
task :decrypt => :environment do
|
||||
unless (Repository.decrypt_all(:password) &&
|
||||
AuthSource.decrypt_all(:account_password))
|
||||
AuthSource.decrypt_all(:account_password) &&
|
||||
User.decrypt_all(:twofa_totp_key))
|
||||
raise "Some objects could not be saved after decryption, update was rolled back."
|
||||
end
|
||||
end
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user