feat(auth): make password encryption opt-in #6743

This commit is contained in:
CaIon
2026-08-29 20:54:07 +08:00
parent 8454082f93
commit 918427d8ab
9 changed files with 46 additions and 9 deletions
+5 -3
View File
@@ -318,9 +318,11 @@ func InitResources() error {
common.FatalLog("failed to initialize authorization: " + err.Error())
return err
}
if err = model.InitPasswordEncryption(); err != nil {
common.FatalLog("failed to initialize password encryption: " + err.Error())
return err
if common.PasswordLoginEncryptionEnabled {
if err = model.InitPasswordEncryption(); err != nil {
common.FatalLog("failed to initialize password encryption: " + err.Error())
return err
}
}
model.CheckSetup()