ometra / caronte-client
Caronte authentication client
3.0.0
2026-04-28 23:50 UTC
Requires
- php: ^8.2
- equidna/bee-hive: >=2.0
- equidna/laravel-toolkit: >=1.0.0
- illuminate/support: ^12.0
- inertiajs/inertia-laravel: ^2.0
- laravel/framework: ^12.0
- laravel/prompts: ^0.3.7
- lcobucci/clock: ^3.2
- lcobucci/jwt: ^5.3
Requires (Dev)
- orchestra/testbench: ^10.0
- phpunit/phpunit: ^10.0 || ^11.0
README
This documentation follows the project's Coding Standards and PHPDoc Style Guide.
Project Overview
ometra/caronte-client is a Laravel package that integrates any Laravel host application with the Caronte centralised authentication server. It handles:
- JWT user authentication (login, logout, 2FA, password recovery)
- Automatic token validation and renewal on every request
- Role-based access control tied to a central role registry
- A ready-to-use management UI for users and roles
- Server-to-server inter-app communication via application tokens
Primary audience: Internal development teams adding Caronte authentication to a Laravel application.
Project Type & Tech Summary
| Item | Value |
|---|---|
| Type | Laravel Package (library) |
| PHP | ^8.2 |
| Laravel | ^12.0 |
| JWT library | lcobucci/jwt ^5.3 + lcobucci/clock ^3.2 |
| Database | MySQL / any Laravel-supported driver (via host app) |
| Cache | Host app cache (no package-level cache) |
| Queue | None (all requests are synchronous) |
| External service | Caronte authentication server (HTTP API) |
| Optional dependency | inertiajs/inertia-laravel ^2.0 |
Quick Start
-
Install the package
composer require ometra/caronte-client
-
Publish the configuration
php artisan vendor:publish --tag=caronte:config
-
Add the three required environment variables
CARONTE_URL=https://your-caronte-server.example.com CARONTE_APP_CN=your-app-canonical-name CARONTE_APP_SECRET=a-secret-at-least-32-characters-long
-
Run migrations (creates local user cache tables)
php artisan migrate
-
Protect routes with the provided middleware:
Route::middleware(['caronte.session', 'caronte.roles:admin'])->group(...);
-
Sync your configured roles with the Caronte server:
php artisan caronte:roles:sync
-
Visit the management UI at
/caronte/management(default).
See Deployment Instructions for the full setup guide.