feat: add password login and bearer sessions
- Argon2id password hashes, KDF in a thread with its own limit - POST /auth/sessions with Basic, DELETE /auth/sessions/current - Bearer sessions in PostgreSQL, X-User-Id ignored - migration drops lab 1 data without passwords - student-tests on tokens, sessions spec and synced specs Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -9,7 +9,7 @@ from concurrent.futures import ThreadPoolExecutor
|
||||
import httpx
|
||||
import pytest
|
||||
|
||||
from api_client import API, Api, order_key, unique_username
|
||||
from api_client import API, Api, order_key, registration, unique_username
|
||||
from contract import assert_error, assert_ok
|
||||
|
||||
CLIENTS = 10
|
||||
@@ -113,7 +113,7 @@ def test_same_username_at_once(base_url: str) -> None:
|
||||
resp = own.request(
|
||||
"POST",
|
||||
f"{API}/users",
|
||||
json={"username": username, "display_name": f"Racer {number}"},
|
||||
json=registration(username, f"Racer {number}"),
|
||||
)
|
||||
return resp, start, time.monotonic()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user