Authentication and user access package for the Drago project. This package provides a complete authentication layer including user login, registration, password recovery and access control. It is designed as a modular extension for projects built on top of the Drago ecosystem and Nette framework.
- PHP >= 8.3
- Nette Framework
- Composer
- Bootstrap
- Naja
- Node.js
- Drago Project core packages
composer require drago-ex/project-authFile copying is handled automatically by drago-ex/project-tools,
which must be installed in your project. Without it, copy the files manually according to the copy section
in this package's composer.json. To skip this package, set "skip": true under
extra.drago-tools.packages.<package-name> in your root composer.json.
- User authentication (sign in / sign out)
- User registration (sign up)
- Password recovery and reset
- User identity handling
- Integration with Nette Security and DI
- Ready-to-use authentication UI components
Hashes the password, generates a token, and ensures the email is unique.
php vendor/bin/create-user <username> <email> <password>final class SecurePresenter extends Presenter
{
use App\UI\Sign\RequireLogged;
}If you use project ACL (drago-ex/permission), you can generate a module permission class:
php vendor/bin/create-auth-permissionphp vendor/bin/migration db:migrate vendor/drago-ex/project-auth/migrationsThis package exposes setup commands in composer.json under extra.drago-tools.commands.
If drago-ex/project-tools is installed, you can run them from the project root:
php vendor/bin/drago-setup