Download the PHP package dnj/laravel-aaa without Composer
On this page you can find all versions of the php package dnj/laravel-aaa. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download dnj/laravel-aaa
More information about dnj/laravel-aaa
Files in dnj/laravel-aaa
Package laravel-aaa
Short Description Authentication + Authorization + Accounting For Your Next Laravel Project!
License MIT
Informations about the package laravel-aaa
Laravel-AAA, a customizable and modern package for Authentication + Authorization + Accounting for your laravel project
Discussions • Documentation
What is Laravel-AAA?
Authentication is one of web applications most critical and essential features. Web frameworks like Laravel provide many ways for users to authenticate.\ You can implement Laravel authentication features quickly and securely. However, implementing these authentication features poorly can be risky, as malicious parties can exploit them.\ But, we built a fully customizable package from ground-up to solve this!
Some Laravel-AAA's features in summary are:
- Secure!
- Easy to use.
- Fully customizable.
- Best practices applied.
- Latest versions of PHP and PHPUnit
- Most importantly, It's an Free Open Source Software (FOSS)!
Laravel-AAA is currently under heavy development. You can give your suggestions and feedback on our Discussions page.
How to start
First of all, you need a laravel installation, You can start a laravel project by running command:
Or if you already have Laravel, install laravel-aaa in your project by running:
Then, publish configs using this command:
This will results:
As you see, there are a aaa.php config file that we use it later.
Concepts
We deal with some concepts, like: Type
, TypeAbility
, TypeLocalizedDetails
, User
and Username
Type
We define some Type
s in our app, consider a Type
is a user level that defines user has access to which fetures of your app.
The Type
has an id, a localized nameds that can be defined for any languages, maybe a parent, paybe some child, and some abilities.
TypeAbility
Consider this as a permission for user, each ability is belong to a Type
.
User
Each user is has a Type and the Type define that this user has access to which fetures of your app.
Username
Each user may have some usernames, username can be anything, like: email, cellphone, telegram id, ....
aaa.php
In this file, you can define the guest type, if user not exists in you app (or not logged in), the app will use this type for check permissions.
define the ID of the guest type in aaa.php
in guestType
property.
Policies
Laravel-AAA provides support for polices You can define a polices by runnig command:
Then, add your policies to AuthServiceProvider
:
now, you can check permission like this:
Type Managment
The ITypeManager
interface provides methods for creating, updating, and deleting types, Here's an example of how to create a new type:
User Managment
The IUserManager
interface provides methods for creating, updating, and deleting users, Here's an example of how to create a new user:
Bug Reporting
If you find any bugs, please report it by submitting an issue on our issue page with a detailed explanation. Giving some screenshots would also be very helpful.
Feature Request
You can also submit a feature request on our issue page or discussions and we will try to implement it as soon as possible. If you want to contribute to this project, please contribute to this project.
Development
If you want to run this project in your local system, please follow this guide:
-
Fork this project
-
Clone the project to your local system using this command
-
Change directory to the root directory of this project
-
Install all dependencies using
composer
- Run the project in development mode.
All versions of laravel-aaa with dependencies
dnj/laravel-user-logger Version ^1.1.2
dnj/laravel-localization Version ^1.0.0
yeganemehr/laravel-support Version ^1.0.0