server: Prevent passwords and secrets from being printed

This commit is contained in:
Valentin Tolmer
2021-11-11 10:36:42 +01:00
committed by nitnelave
parent 617a0f53fa
commit 9124339b96
8 changed files with 41 additions and 19 deletions
+3 -2
View File
@@ -20,10 +20,11 @@ mod domain;
mod infra;
async fn create_admin_user(handler: &SqlBackendHandler, config: &Configuration) -> Result<()> {
let pass_length = config.ldap_user_pass.unsecure().len();
assert!(
config.ldap_user_pass.len() >= 8,
pass_length >= 8,
"Minimum password length is 8 characters, got {} characters",
config.ldap_user_pass.len()
pass_length
);
handler
.create_user(CreateUserRequest {