<p align="center"><img src="https://cdn.rawgit.com/santigarcor/laratrust/135aa15fecd22a512c444389d1f8cb94e72d0fa7/docs/img/laratrust.svg"></p>

# Laratrust (Laravel Package)

[![Build Status](https://travis-ci.org/santigarcor/laratrust.svg?branch=master)](https://travis-ci.org/santigarcor/laratrust)
[![Latest Stable Version](https://poser.pugx.org/santigarcor/laratrust/v/stable)](https://packagist.org/packages/santigarcor/laratrust)
[![Total Downloads](https://poser.pugx.org/santigarcor/laratrust/downloads)](https://packagist.org/packages/santigarcor/laratrust)
[![StyleCI](https://styleci.io/repos/59691202/shield)](https://styleci.io/repos/59691202)
[![License](https://poser.pugx.org/santigarcor/laratrust/license)](https://packagist.org/packages/santigarcor/laratrust)
[![Gitter](https://badges.gitter.im/santigarcor/laratrust.svg)](https://gitter.im/santigarcor/laratrust?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)
[![Donate](https://img.shields.io/badge/donate-Ko--fi-blue.svg)](https://ko-fi.com/V7V48I5Y)

Laratrust is an easy and flexible way to add roles, permissions and teams authorization to **Laravel (>=5.6)**.

For Laravel 5.2.32 - 5.6 please use the [5.1 branch](https://laratrust.santigarcor.me/docs/5.1/).

For Laravel < 5.2.32 please use the [4.0 branch](https://github.com/santigarcor/laratrust/tree/4.0).

## Installation, Configuration and Usage
To install, configure and learn how to use Laratrust please go to the [Documentation](https://laratrust.santigarcor.me/).

## What does Laratrust support?

- Multiple user models.
- Multiple roles and permissions can be attached to users.
- Multiple permissions can be attached to roles.
- Roles and permissions verification.
- Roles and permissions caching.
- Events when roles and permissions are attached, detached or synced.
- Multiple roles and permissions can be attached to users within teams.
- Objects ownership verification.
- Multiple guards for the middleware.
- [Laravel gates and policies](http://laratrust.santigarcor.me/docs/5.0/troubleshooting.html).

## License

Laratrust is open-sourced software licensed under the [MIT license](http://opensource.org/licenses/MIT).

## Contributing

Please report any issue you find in the issues page. Pull requests are more than welcome.
