PHPackages                             awes-io/auth - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Authentication &amp; Authorization](/categories/authentication)
4. /
5. awes-io/auth

ActiveLibrary[Authentication &amp; Authorization](/categories/authentication)

awes-io/auth
============

Laravel Authentication package with built-in two-factor (Authy) and social authentication (Socialite).

v1.2.0(6y ago)3826.7k1[1 issues](https://github.com/awes-io/auth/issues)1MITPHPCI failing

Since Jan 26Pushed 6y ago4 watchersCompare

[ Source](https://github.com/awes-io/auth)[ Packagist](https://packagist.org/packages/awes-io/auth)[ Docs](https://github.com/awes-io/auth)[ RSS](/packages/awes-io-auth/feed)WikiDiscussions master Synced today

READMEChangelogDependencies (7)Versions (22)Used By (1)

 [ ![Awes.io logo](https://camo.githubusercontent.com/3411caf1ea53cc7f92a106e51ad617072eed81a7d52da1aca5eea4f96b6d001b/68747470733a2f2f7374617469632e617765732e696f2f70726f6d6f2f4c6f676f5f7369676e5f636f6c6f722e737667) ](https://www.awes.io/?utm_source=github&utm_medium=auth)

Authentication
==============

[](#authentication)

Laravel Authentication package with built-in two-factor (Authy) and social authentication (Socialite).

 [ ![Coverage report](https://camo.githubusercontent.com/9329fa08df761b2c1c7e3ad98ae44796945cbd22237fe00d349ea755b7ab528e/68747470733a2f2f7265706f2e706b676b69742e636f6d2f344742574f2f617765732d696f2f617574682f6261646765732f6d61737465722f636f7665726167652e737667) ](https://www.awes.io/?utm_source=github&utm_medium=shields) [ ![Last version](https://camo.githubusercontent.com/868514d36d5971f7ad4b69b3e61c30bc003b344bff135aa93d6f17d7a233c4f5/68747470733a2f2f7777772e706b676b69742e636f6d2f344742574f2f617765732d696f2f617574682f76657273696f6e2e737667) ](https://www.awes.io/?utm_source=github&utm_medium=shields) [ ![Build status](https://camo.githubusercontent.com/ef23db681756895889016a929df2781a636ee068186ceaae73dea5671550097d/68747470733a2f2f7265706f2e706b676b69742e636f6d2f344742574f2f617765732d696f2f617574682f6261646765732f6d61737465722f6275696c642e737667) ](https://www.awes.io/?utm_source=github&utm_medium=shields) [ ![Downloads](https://camo.githubusercontent.com/9224decfb6148e77b1fa7c532eebd0d36c4b963171fbac6fae264afa7a7e7a0c/68747470733a2f2f7777772e706b676b69742e636f6d2f344742574f2f617765732d696f2f617574682f646f776e6c6f6164732e737667) ](https://www.awes.io/?utm_source=github&utm_medium=shields) [ ![License](https://camo.githubusercontent.com/3de40f529a679d16579ef43e1b3ce886a431ad49b0a286bb8973c943ed74fc31/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f617765732d696f2f617574682e737667) ](https://www.awes.io/?utm_source=github&utm_medium=shields) [ ![CDN Ready](https://camo.githubusercontent.com/d57e8dd532dc17c58abecf507b9dc5eb691c265c1e5034b3a6967cba415f4ac0/68747470733a2f2f7777772e706b676b69742e636f6d2f344742574f2f617765732d696f2f617574682f7374617475732e737667) ](https://www.awes.io/?utm_source=github&utm_medium=shields) [ ![laravel](https://camo.githubusercontent.com/6c8450706caac3ca057866b48ac77f9927d9b206811b156a7c3f05b8e1252b3b/68747470733a2f2f7374617469632e706b676b69742e636f6d2f6261646765732f6c61726176656c2e737667) ](https://www.awes.io/?utm_source=github&utm_medium=shields) [ ![Last commit](https://camo.githubusercontent.com/050c34a0d1600ce440bd0b39272d802eee4a4ce0d070d648d89ae441bb854c8d/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6173742d636f6d6d69742f617765732d696f2f617574682e737667) ](https://www.awes.io/?utm_source=github&utm_medium=shields) [ ![Analytics](https://camo.githubusercontent.com/44a52b7248881a3938ee77af5bd3f4628f3b9a873d75d21e55408132b3d22f9f/68747470733a2f2f67612d626561636f6e2e61707073706f742e636f6d2f55412d3133343433313633362d312f617765732d696f2f61757468) ](https://github.com/awes-io/awes-io) [ ![Hosted by Package Kit](https://camo.githubusercontent.com/31a8a2063d3a2b5eae3ae31d0be49d4366bfcd848455e6a6cd39bb7b71cb2b97/68747470733a2f2f7777772e706b676b69742e636f6d2f6261646765732f686f737465642e737667) ](https://www.pkgkit.com/?utm_source=github&utm_medium=shields) [ ![Patreon](https://camo.githubusercontent.com/cc15e6db5bcba81594411e6ec54eb020345f90a5d21b37616523a18112cd41ff/68747470733a2f2f7374617469632e706b676b69742e636f6d2f6261646765732f70617472656f6e2e737667) ](https://www.patreon.com/join/awesdotio)

 [![Laravel Authentication](https://camo.githubusercontent.com/ebb645ffcb58878dd3c365bb4be7c1a7b1807d32fd65a1a788a31f9870cf1e59/68747470733a2f2f7374617469632e617765732e696f2f6769746875622f617574682d636f7665722e676966 "Awes.io Authentication")](https://camo.githubusercontent.com/ebb645ffcb58878dd3c365bb4be7c1a7b1807d32fd65a1a788a31f9870cf1e59/68747470733a2f2f7374617469632e617765732e696f2f6769746875622f617574682d636f7665722e676966)

Table of Contents
-----------------

[](#table-of-contents)

- [Installation](#installation)
- [Configuration](#configuration)
    - [Social and two-factor authentication](#social-and-two-factor-authentication)
    - [Email verification &amp; resetting passwords](#email-verification-resetting-passwords)
- [Usage](#usage)
- [Testing](#testing)

Installation
------------

[](#installation)

Via Composer

```
$ composer require awes-io/auth
```

The package will automatically register itself.

You can publish migrations:

```
php artisan vendor:publish --provider="AwesIO\Auth\AuthServiceProvider" --tag="migrations"
```

After migrations have been published you can create required db tables by running:

```
php artisan migrate
```

Publish views:

```
php artisan vendor:publish --provider="AwesIO\Auth\AuthServiceProvider" --tag="views"
```

Configuration
-------------

[](#configuration)

Publish config file:

```
php artisan vendor:publish --provider="AwesIO\Auth\AuthServiceProvider" --tag="config"
```

You can disable additional features by commenting them out:

```
'enabled' => [
    'social',
    // 'two_factor',
    // 'email_verification',
],
```

Add new socialite services:

```
'services' => [
    'github' => [
        'name' => 'GitHub'
    ],
    ...
],
'github' => [
    'client_id' => env('GITHUB_CLIENT_ID'),
    ...
],
```

And configure redirect paths:

```
'redirects' => [
    'login' => '/twofactor',
    'reset_password' => '/',
    ...
],
```

### Social and two-factor authentication

[](#social-and-two-factor-authentication)

Several .env variables required if additional modules were enabled in config:

```
# SOCIALITE GITHUB
GITHUB_CLIENT_ID=
GITHUB_CLIENT_SECRET=
GITHUB_REDIRECT_URL=http://auth.test/login/github/callback

# TWO FACTOR AUTHY
AUTHY_SECRET=
```

If you enabled social and/or two factor authentication add respective traits to User model class:

```
use AwesIO\Auth\Models\Traits\HasSocialAuthentication;
use AwesIO\Auth\Models\Traits\HasTwoFactorAuthentication;

class User extends Authenticatable
{
    use HasSocialAuthentication, HasTwoFactorAuthentication;
}
```

### Email verification &amp; resetting passwords

[](#email-verification--resetting-passwords)

To use email verification functionality and to reset passwords, add `SendsEmailVerification` and `SendsPasswordReset` traits:

```
use AwesIO\Auth\Models\Traits\SendsPasswordReset;
use AwesIO\Auth\Models\Traits\SendsEmailVerification;

class User extends Authenticatable
{
    use SendsEmailVerification, SendsPasswordReset;
}
```

Usage
-----

[](#usage)

Add to routes/web.php:

```
AwesAuth::routes();
```

You can disable registration:

```
AwesAuth::routes(['register' => false]);
```

Package will register several routes.

##### Besides default authentication routes, it will add:

[](#besides-default-authentication-routes-it-will-add)

- Socialite routes
    - `'login.social'`
    - `'login/{service}/callback'`
- Two factor authentication setup routes
    - `'twofactor.index'`
    - `'twofactor.store'`
    - `'twofactor.destroy'`
    - `'twofactor.verify'`
- Two factor authentication login routes
    - `'login.twofactor.index'`
    - `'login.twofactor.verify'`
- Email verification routes
    - `'verification.resend'`
    - `'verification.code.verify'`
    - `'verification.code'`
    - `'verification.verify'`

Testing
-------

[](#testing)

You can run the tests with:

```
composer test
```

Contributing
------------

[](#contributing)

Please see [contributing.md](contributing.md) for details and a todolist.

Credits
-------

[](#credits)

- [Galymzhan Begimov](https://github.com/begimov)
- [All Contributors](contributing.md)

License
-------

[](#license)

[MIT](http://opensource.org/licenses/MIT)

###  Health Score

37

—

LowBetter than 83% of packages

Maintenance19

Infrequent updates — may be unmaintained

Popularity31

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity70

Established project with proven stability

 Bus Factor1

Top contributor holds 89.9% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~12 days

Recently: every ~34 days

Total

21

Last Release

2403d ago

Major Versions

v0.1.3 → v1.0.02019-02-19

### Community

Maintainers

![](https://www.gravatar.com/avatar/7932461f5d3d8775210ba7ff5487258ff23c274648a9936341112158aa487480?d=identicon)[Yevhen L.](/maintainers/Yevhen%20L.)

---

Top Contributors

[![begimov](https://avatars.githubusercontent.com/u/3600510?v=4)](https://github.com/begimov "begimov (134 commits)")[![yevhenlisovenko](https://avatars.githubusercontent.com/u/11060056?v=4)](https://github.com/yevhenlisovenko "yevhenlisovenko (14 commits)")[![AlexFN](https://avatars.githubusercontent.com/u/49072623?v=4)](https://github.com/AlexFN "AlexFN (1 commits)")

---

Tags

2faauthauthenticationauthorisationauthorizationauthylaravelregistrationsocialitelaravelauthAuthentication2faTwo Factor Authenticationsocialiteauthorizationauthorisationregistrationauthy

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/awes-io-auth/health.svg)

```
[![Health](https://phpackages.com/badges/awes-io-auth/health.svg)](https://phpackages.com/packages/awes-io-auth)
```

###  Alternatives

[ellaisys/aws-cognito

AWS Cognito package that allows Auth and other related features using the AWS SDK for PHP

120220.7k1](/packages/ellaisys-aws-cognito)[auth0/login

Auth0 Laravel SDK. Straight-forward and tested methods for implementing authentication, and accessing Auth0's Management API endpoints.

2745.0M3](/packages/auth0-login)[andrewdwallo/filament-companies

A comprehensive Laravel authentication and authorization system designed for Filament, focusing on multi-tenant company management.

34450.0k2](/packages/andrewdwallo-filament-companies)[truckersmp/steam-socialite

Laravel Socialite provider for Steam OpenID.

1516.7k](/packages/truckersmp-steam-socialite)[rinvex/laravel-authy

Rinvex Authy is a simple wrapper for Authy TOTP, the best rated Two-Factor Authentication service for consumers, simplest 2fa Rest API for developers and a strong authentication platform for the enterprise.

3376.7k1](/packages/rinvex-laravel-authy)[chervand/yii2-oauth2-server

OAuth 2.0 server for Yii 2.0 with MAC tokens support.

1524.2k1](/packages/chervand-yii2-oauth2-server)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
