add MFA, user web mail portal

This commit is contained in:
2026-08-13 08:07:19 +01:00
parent 70c05cc777
commit bc4bbe6e56
38 changed files with 1072 additions and 59 deletions
+10 -3
View File
@@ -3,10 +3,17 @@ package db
import "time"
type AdminUser struct {
ID int64
Username string
PasswordHash string
ID int64
Username string
PasswordHash string
// MustChangePassword forces a password change before this admin can use the rest
// of the dashboard — true for the seeded default account and every newly-created
// admin (delegated or not). MustChangeUsername additionally forces choosing a new
// username too — true only for the seeded default account (username "admin"),
// never for admins created via the delegation flow, who pick their own username
// up front (see addAdmin/CreateScopedAdminUser).
MustChangePassword bool
MustChangeUsername bool
TOTPSecret string
TOTPEnabled bool
IsGlobalAdmin bool