PHPackages                             pails/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. pails/auth

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

pails/auth
==========

v1.5.2(4mo ago)0507[2 issues](https://github.com/bparks/pails-auth/issues)2PHP

Since Jul 25Pushed 4mo ago1 watchersCompare

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

READMEChangelogDependencies (4)Versions (26)Used By (2)

pails-auth
==========

[](#pails-auth)

An authentication and authorization plugin for pails loosely based on UserPie ([userpie.com](http://userpie.com)). At this point it's a near-complete rewrite.

Dependencies
------------

[](#dependencies)

- pails
- pails/activerecord
- pails/actionmailer

We recommend using composer to get the dependencies. Furthermore, we recommend not installing the dependencies for pails-auth directly, but listing pails-auth as a dependency in your pails application's composer.json file.

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

[](#installation)

In the root of a pails app, run

```
composer require pails/auth

```

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

[](#configuration)

Inside any controller where you want to make use of the authentication/authorization methods, `use` the `PailsAuthentication` [trait](http://php.net/manual/en/language.oop5.traits.php).

```
class DefaultController extends Pails\Controller
{
	use PailsAuthentication;
}
```

You can then use the before actions `require_login` or `require_anonymous`:

```
$before_actions = array(
	'require_login' => array('except' => array('index', 'about', 'contact'))
);
```

Two utility methods, `is_logged_in` and `current_user`, are also provided.

Support
-------

[](#support)

pails-auth is a core plugin maintained and supported by Brian Parks.

###  Health Score

47

—

FairBetter than 93% of packages

Maintenance76

Regular maintenance activity

Popularity12

Limited adoption so far

Community14

Small or concentrated contributor base

Maturity73

Established project with proven stability

 Bus Factor1

Top contributor holds 95.1% 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 ~161 days

Recently: every ~399 days

Total

25

Last Release

133d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/5fa7c6719167ebb9c156d400c616cc6df1e7742a31f0ce915b8934a1f4742fe3?d=identicon)[bparks](/maintainers/bparks)

---

Top Contributors

[![bparks](https://avatars.githubusercontent.com/u/538419?v=4)](https://github.com/bparks "bparks (39 commits)")[![kyranb](https://avatars.githubusercontent.com/u/5426926?v=4)](https://github.com/kyranb "kyranb (1 commits)")[![TATDK](https://avatars.githubusercontent.com/u/636270?v=4)](https://github.com/TATDK "TATDK (1 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

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

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

###  Alternatives

[vitalybaev/laravel5-dkim

Laravel 5/6 package for signing outgoing messages with DKIM.

3163.1k](/packages/vitalybaev-laravel5-dkim)

PHPackages © 2026

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