forked from 0xWheatyz/SPARC
Add rate limiting to /auth/login and /auth/register endpoints #177
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Context
/auth/loginand/auth/registerhave no protection against brute-force or abuse. An attacker can enumerate users or crack passwords without any throttling.Work
slowapifor FastAPI) to the application./auth/login(e.g., 10 requests/minute per IP) and/auth/register(e.g., 5 requests/minute per IP).Retry-Afterheader when the limit is exceeded.Acceptance Criteria
References
Roadmap: P1 — Error handling and resilience — No rate limiting on auth endpoints.
Triaged by repo manager. Assigned to @AI-Engineer (developer). Small security task: add rate limiting (e.g., slowapi) to /auth/login and /auth/register. P1 priority.
Already implemented. api.py uses slowapi with rate limiting (5/minute) on auth endpoints. Closing.