Download the PHP package rawbinn/lp-auth without Composer
On this page you can find all versions of the php package rawbinn/lp-auth. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package lp-auth
Rawbinn LP Auth (rawbinn/lp-auth)
A drop-in authentication package for Laravel with publishable views, configurable routes, role/permission access control, and optional API, 2FA, OTP, passkey, and social login features.
Requirements
- PHP 8.3+
- Laravel 12 or 13
- SQLite/MySQL/PostgreSQL for migrations
Optional packages (enable the matching feature in config):
| Feature | Package |
|---|---|
| API bearer tokens | laravel/sanctum |
| TOTP / 2FA | pragmarx/google2fa |
| Social login | laravel/socialite |
| Passkeys | web-auth/webauthn-lib (experimental) |
Installation
lp-auth:install publishes config, views, language files, and migrations.
Quick start
1. Extend the user model
Point Laravel auth at your model in config/auth.php:
2. Configure features
3. Roles and permissions
Blade directives:
Use @endrole, @endpermission, @endroles, @endpermissions, @endneedsroles, and @endneedspermissions to close blocks. Do not use @endauth for role/permission blocks — that is reserved for Laravel's @auth directive.
4. Middleware
Legacy Larapress aliases are also registered: access.routeNeedsRole, access.routeNeedsPermission.
Routes
Web routes are enabled by default (LP_AUTH_ROUTES=true). Customize paths, prefixes, controllers, and redirects in config/lp-auth.php.
API routes live under config('lp-auth.api.prefix') (default api/auth) and require Sanctum when issuing tokens.
Disable all package routes:
Publishing
| Tag | Description |
|---|---|
lp-auth-config |
Publish config/lp-auth.php |
lp-auth-views |
Publish Blade views |
lp-auth-lang |
Publish language files |
lp-auth-migrations |
Publish migrations |
lp-auth |
Publish everything above |
Published config/lp-auth.php can be trimmed to only the values you need to override. The package merges the full default config from the package automatically.
Migrations on existing apps
The package ships a base users table migration for fresh installs. If your application already has a users table, publish migrations with:
Then keep only the additive migrations (profiles, roles, permissions, OTP, passkeys, auth columns) and skip 2014_10_12_000000_create_users_table.php.
Packagist / Git
Repository: github.com/rawbinn/lp-auth
Tag releases from Git for Packagist distribution. This monorepo also exposes the package through a Composer path repository.
Testing
From the package directory:
From the monorepo root:
Larapress integration
Larapress consumes this package for authentication and access control. Set Larapress-specific redirects and branding in your published config/lp-auth.php.
License
MIT. See LICENSE.
All versions of lp-auth with dependencies
illuminate/support Version ^12.0|^13.0
illuminate/auth Version ^12.0|^13.0
illuminate/hashing Version ^12.0|^13.0
illuminate/routing Version ^12.0|^13.0
illuminate/validation Version ^12.0|^13.0
illuminate/view Version ^12.0|^13.0
illuminate/database Version ^12.0|^13.0