Download the PHP package daycry/auth without Composer
On this page you can find all versions of the php package daycry/auth. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Vendor daycry
Package auth
Short Description Authentication for Codeigniter 4
License MIT
Homepage https://github.com/daycry/auth
Package auth
Short Description Authentication for Codeigniter 4
License MIT
Homepage https://github.com/daycry/auth
Please rate this library. Is it a good library?
Informations about the package auth
Daycry Auth
A comprehensive authentication and authorization library for CodeIgniter 4, designed to be flexible, secure, and easy to extend.
Features
Authentication Methods
| Method | Description |
|---|---|
| Session | Email/password with secure remember-me cookies |
| Access Token | Long-lived API keys sent via X-API-KEY header |
| JWT | Stateless Bearer tokens with refresh token rotation |
| Magic Link | Passwordless login via one-time email link |
| OAuth 2.0 | Social login: Google, GitHub, Facebook, Microsoft Azure |
Security Features
| Feature | Description |
|---|---|
| TOTP Two-Factor Auth | Time-based OTP (Google Authenticator, Authy, 1Password) |
| Email Two-Factor Auth | 6-digit code sent to user's email after login |
| Email Activation | Require email confirmation before first login |
| Per-User Account Lockout | Lock account after N failed attempts (independent of IP) |
| IP-Based Blocking | Block IPs that exceed failed attempt limits |
| Rate Limiting | Per-IP, per-user, or per-endpoint request throttling |
| Force Password Reset | Flag accounts for mandatory password change |
| Password Reset Flow | Secure token-based reset with email delivery |
| Self-Service Email Change | Change email with confirmation link to new address |
| Access Token Revocation | Soft-revoke tokens without deleting them |
| Device Session Tracking | See and terminate active logins per device/browser |
| UUID Dual-Key Pattern | Internal id (INT) + external uuid (UUID v7) on users |
Authorization
| Feature | Description |
|---|---|
| Groups | Named roles (e.g., admin, editor, user) |
| Permissions | Granular actions (e.g., posts.create, users.delete) |
| Permission Inheritance | Users inherit all permissions from their groups |
| Wildcard Permissions | posts.* grants all post-related permissions |
| Permission Cache | Configurable TTL cache to avoid repeated DB queries |
| Route Filters | group:admin, permission:posts.edit directly on routes |
Developer Experience
| Feature | Description |
|---|---|
| BaseAuthController | Abstract base with validation, redirect, and error helpers |
| Bootstrap 5 Admin Panel | Manage users, groups, permissions, and logs via UI |
| OAuth Provider Unlinking | Let users disconnect social accounts |
| Pre-Auth Events | pre-login and pre-register CodeIgniter Events |
| CI4 Events System | Hook into login, logout, registered, passwordReset, etc. |
| Chain Authenticator | Try session → access_token → JWT automatically |
| Custom Authenticators | Extend Base with full Dependency Injection support |
Quick Start
Requirements
- PHP 8.1 or higher
- CodeIgniter 4.4 or higher
- Composer
Installation
Basic Usage
Protect Routes
JWT with Refresh Tokens (API)
Documentation
Full documentation is available at:
https://daycry.github.io/auth/
| Section | Description |
|---|---|
| Quick Start | Install and set up in minutes |
| Configuration | Every config option explained |
| Authentication | All auth methods + JWT refresh + password reset |
| Filters | Route protection filters |
| Controllers | All included controllers |
| Authorization | Groups, permissions, RBAC |
| Logging & Events | CI4 Events, DB logs, lockout |
| Testing | Testing auth in your app |
| OAuth 2.0 | Google, GitHub, Facebook, Azure |
| TOTP 2FA | Authenticator app integration |
| WebAuthn / Passkeys | Passwordless login + passkey 2FA |
| Device Sessions | Active session management |
Contributing
Contributions of all kinds are welcome — code, documentation, bug reports, or feedback. See CONTRIBUTING.md for details.
License
This project is licensed under the MIT License — see the LICENSE file for details.
Acknowledgements
Made with contrib.rocks.
Security design informed by:
All versions of auth with dependencies
PHP Build Version
Package Version
Requires
php Version
^8.2
codeigniter4/settings Version ^2
daycry/class-finder Version ^2.0
daycry/encryption Version ^2.0
daycry/jobs Version ^3.0
daycry/jwt Version ^3.0
endroid/qr-code Version ^6.0
league/oauth2-facebook Version ^2.0
league/oauth2-github Version ^3.0
league/oauth2-google Version ^4.0 || ^5.0
michalsn/codeigniter4-uuid Version ^2.0
thenetworg/oauth2-azure Version ^2
web-auth/webauthn-lib Version ^5.3
codeigniter4/settings Version ^2
daycry/class-finder Version ^2.0
daycry/encryption Version ^2.0
daycry/jobs Version ^3.0
daycry/jwt Version ^3.0
endroid/qr-code Version ^6.0
league/oauth2-facebook Version ^2.0
league/oauth2-github Version ^3.0
league/oauth2-google Version ^4.0 || ^5.0
michalsn/codeigniter4-uuid Version ^2.0
thenetworg/oauth2-azure Version ^2
web-auth/webauthn-lib Version ^5.3
The package daycry/auth contains the following files
Loading the files please wait ...