web driver. All routes are rendered through Inertia, so the browser never receives a traditional full-page redirect from the auth endpoints — the React app handles the UI state.
Guards and session configuration
Theweb guard is configured in config/auth.php:
The
admin guard uses a separate FilamentUser model and is reserved for the Filament admin panel (/admin). Standard tenant users authenticate through the web guard.Routes
All web auth routes are defined inroutes/auth.php and loaded within the / prefix.
Guest-only routes
These routes are wrapped inmiddleware('guest') — authenticated users are redirected away:
| Method | Path | Named route | Controller action |
|---|---|---|---|
GET | /register | register | RegisteredUserController@create |
POST | /register | — | RegisteredUserController@store |
GET | /login | login | AuthenticatedSessionController@create |
POST | /login | — | AuthenticatedSessionController@store |
GET | /forgot-password | password.request | PasswordResetLinkController@create |
POST | /forgot-password | password.email | PasswordResetLinkController@store |
GET | /reset-password/{token} | password.reset | NewPasswordController@create |
POST | /reset-password | password.store | NewPasswordController@store |
Authenticated-only routes
These routes requiremiddleware('auth'):
| Method | Path | Named route | Description |
|---|---|---|---|
GET | /verify-email | verification.notice | Email verification prompt |
GET | /verify-email/{id}/{hash} | verification.verify | Verify email (signed URL, throttle 6/min) |
POST | /email/verification-notification | verification.send | Resend verification email (throttle 6/min) |
GET | /confirm-password | password.confirm | Confirm password prompt |
POST | /confirm-password | — | Confirm password action |
PUT | /password | password.update | Update password |
GET | /profile | profile.edit | Profile edit page |
PATCH | /profile | profile.update | Update profile |
DELETE | /profile | profile.destroy | Delete account |
POST | /logout | logout | Destroy session |
Registration flow
Display the form
GET /register renders the Auth/Register Inertia page via RegisteredUserController@create.Submit registration
POST /register is handled by RegisteredUserController@store. The request is validated by RegisterTenantRequest, then a RegisterTenantCommand is dispatched through the command bus.The command creates both the user and the associated tenant in a single atomic operation.Login flow
Authenticate
POST /login delegates to LoginRequest::authenticate(). On success, the session is regenerated to prevent session fixation, and the user is redirected to their intended destination.Email verification
TheUser model implements MustVerifyEmail. Laravel attaches a signed URL to the verification email. The verification route enforces both the signed middleware (tamper-proof URL) and throttle:6,1 (6 attempts per minute).
Password reset
Password reset tokens are stored inpassword_reset_tokens and expire after 60 minutes (configurable via AUTH_PASSWORD_TIMEOUT). A new token cannot be requested more than once per minute ('throttle' => 60).
Profile management
TheProfileController delegates to two application-layer actions:
UpdateUserProfileAction— handles dirty email detection and saves changes.DeleteUserAction— requires current password confirmation before deleting the account and invalidating the session.