SMTP-Credentials und E_Mail-Adressen verschlüsselt abgelegt

This commit is contained in:
concierge committed 2026-11-16 15:43:51 +01:00
1 parent 781aa20253
commit 66659d9a23
32 files changed
+3276 -132

No files matched your search

+9
View File
@@ -247,6 +247,15 @@ func (s *Store) CreateUser(ctx context.Context, username, displayName, password
return nil, err
}
user.TenantIDs = tenantIDs
// Editors need keys for SMTP and all contacts, readers for their own
// e-mail address. Administrators deliberately receive no key material.
// The keypair is protected by the initial password; the first login
// replaces that protection with the account holder's own password.
if role == RoleEditor || role == RoleReader {
if _, err := s.createUserKeys(ctx, user.ID, password); err != nil {
return nil, err
}
}
return user, nil
}