feat: Implement full auth pipeline — login, register, JWT, bootstrap
Backend auth flow is now functional: - services/auth.rs: Argon2id password hashing, JWT access/refresh tokens - services/encryption.rs: AES-256-GCM encrypt/decrypt, hex token generation - api/auth.rs: Login, register, refresh, logout, /me endpoints - middleware/auth.rs: JWT Bearer token extractor (FromRequestParts) - db/users.rs + licenses.rs: Full CRUD with runtime queries (no compile-time DB) - main.rs: Bootstrap admin user on first run via ADMIN_EMAIL/ADMIN_PASSWORD env vars - NATS connection now optional for dev (graceful fallback) - Added hex and http crates to Cargo.toml Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -66,3 +66,9 @@ anyhow = "1"
|
||||
|
||||
# Async trait support
|
||||
async-trait = "0.1"
|
||||
|
||||
# Hex encoding
|
||||
hex = "0.4"
|
||||
|
||||
# HTTP types
|
||||
http = "1"
|
||||
|
||||
Reference in New Issue
Block a user