feat(auth): implement TOTP setup and management
Lint / Lint (Node/Svelte) (push) Successful in 24s
Lint / Lint (Go) (push) Successful in 28s
Lint / Lint (Python) (push) Failing after 14s
Tests / Test (Node/Svelte) (push) Successful in 18s
Tests / Test (Go) (push) Successful in 25s
Tests / Test (Python) (push) Successful in 12s
Lint / Lint (Node/Svelte) (push) Successful in 24s
Lint / Lint (Go) (push) Successful in 28s
Lint / Lint (Python) (push) Failing after 14s
Tests / Test (Node/Svelte) (push) Successful in 18s
Tests / Test (Go) (push) Successful in 25s
Tests / Test (Python) (push) Successful in 12s
- Added TOTP support for two-factor authentication in the auth module. - Introduced new types and interfaces for TOTP setup and token actions in the web UI. - Created backend logic for generating and verifying TOTP secrets and tokens. - Implemented user management features including role assignments and user CRUD operations. - Enhanced UI components for managing users and TOTP settings. - Added styles for optional labels and authentication reset links. - Implemented reset code generation and validation for admin accounts.
This commit is contained in:
1 parent
2f57554154
commit
da97fd4fb1
30 files changed
+2145
-27
No files matched your search
@@ -1,18 +1,43 @@
|
||||
"""Shared PostgreSQL and authentication primitives for Python services."""
|
||||
|
||||
from .auth import AuthStore, AuthUser, hash_password, verify_password
|
||||
from .auth import (
|
||||
ROLE_ADMIN,
|
||||
ROLE_SUPERADMIN,
|
||||
ROLE_USER,
|
||||
RESET_CODE_TTL,
|
||||
AuthStore,
|
||||
AuthUser,
|
||||
ResetManager,
|
||||
can_assign_role,
|
||||
can_manage_users,
|
||||
hash_password,
|
||||
normalize_role,
|
||||
verify_password,
|
||||
)
|
||||
from .config import DatabaseConfig, database_url_from_env
|
||||
from .postgres import Database
|
||||
from .totp import generate_totp_secret, totp_provisioning_uri, verify_totp
|
||||
from .tokens import hash_token, new_session_token
|
||||
|
||||
__all__ = [
|
||||
"AuthStore",
|
||||
"AuthUser",
|
||||
"ROLE_ADMIN",
|
||||
"ROLE_SUPERADMIN",
|
||||
"ROLE_USER",
|
||||
"RESET_CODE_TTL",
|
||||
"ResetManager",
|
||||
"can_assign_role",
|
||||
"can_manage_users",
|
||||
"Database",
|
||||
"DatabaseConfig",
|
||||
"database_url_from_env",
|
||||
"generate_totp_secret",
|
||||
"hash_password",
|
||||
"hash_token",
|
||||
"new_session_token",
|
||||
"normalize_role",
|
||||
"totp_provisioning_uri",
|
||||
"verify_password",
|
||||
"verify_totp",
|
||||
]
|
||||
Reference in new issue
Block a user