AppServiceProvider registers 9 granular, context-aware sliding windows based on route expense and vulnerability.| Limiter | Limit | Key | Purpose / Justification |
|---|---|---|---|
api_authenticated | 60 / min | user_id or IP | General API consumption for authenticated users (SEC-16). |
login | 5 / min | IP + email | Prevents credential stuffing. Keys on both IP and the targeted email account. |
register | 5 / min | IP | Prevents mass account creation / spam bots. |
ai | Dynamic / day | user_id or IP | Controlled by config('ai.rate_limit_per_day'). Prevents burning expensive Groq/Llama tokens. |
maps | 10 / min | IP | Protects the expensive Overpass/Mapbox fan-out endpoints. |
weather | 30 / min | IP | Protects public external Open-Meteo fetches (SEC-03). |
checkout | 5 / min | user_id or IP | Prevents spamming order creation and Paymob Payment Intent exhaustion (SEC-08). |
contacts | 5 / min | IP | Prevents spamming the public contact database (SEC-03). |
newsletter | 5 / min | user_id or IP | Prevents email subscription bombing (NEWS-01). |
tymon/jwt-auth) to verify identity without maintaining server-side sessions./api/auth/login and /api/auth/register (using the auth:api guard)./api/auth/refresh to obtain a new token. When refreshed or when the user calls /api/auth/logout, the old token is explicitly Blacklisted in the database/cache. It cannot be used again, severely limiting the window for stolen token abuse.api_authenticated limiter to prevent excessive token generation.verified middleware (pointing to MustVerifyEmail)./email/verification-notification endpoint is hard-throttled at 1 email per 60 seconds.spatie/laravel-permission.super_admin (Bypasses all Gates implicitly)adminagencyuserAppServiceProvider::boot(), we register a global Gate::before interceptor. This guarantees that super_admin can always execute actions without needing explicit permission assignments, reducing DB queries and configuration drift: