PHPackages                             enigmatix/yii2-rbac - 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. enigmatix/yii2-rbac

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

enigmatix/yii2-rbac
===================

Yii2 RBAC helper

1.0.1(9y ago)0321MITPHPPHP &gt;=5.4.0

Since Jul 19Pushed 9y ago1 watchersCompare

[ Source](https://github.com/enigmatix/yii2-rbac)[ Packagist](https://packagist.org/packages/enigmatix/yii2-rbac)[ RSS](/packages/enigmatix-yii2-rbac/feed)WikiDiscussions master Synced today

READMEChangelog (1)DependenciesVersions (4)Used By (0)

yii2-rbac
=========

[](#yii2-rbac)

Helper Class to build your RBAC using easy configuration arrays.

Some quick examples:

Creates a single role with associated permissions. The default construction is:

A role with sub-roles:

```
             ['Support',   ['Basic','SupportManager']],

```

A role with permissions:

```
             ['UserManager', 'permissions' => ['assumeUserIdentity','resetUserPassword']],

```

A role with a rule:

```
             ['Basic', 'ruleName' => 'notGuest']

```

Or an entry with all three:

```
             ['Support', ['Basic','SupportManager'],
                   'ruleName' => 'notGuest',
                   'permissions' => ['assumeUserIdentity','resetUserPassword']]

```

And then add them via the Rbac Builder:

```
RbacBuilder::addRules([
    ['notGuest' => GuestRule::className()]
]);

RbacBuilder::createRoles(['Support', ['Basic','SupportManager'],
    'ruleName' => 'notGuest',
    'permissions' => ['assumeUserIdentity','resetUserPassword']
    ]);

```

###  Health Score

28

—

LowBetter than 52% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity13

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor1

Top contributor holds 100% 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 ~8 days

Total

3

Last Release

3616d ago

Major Versions

0.1.0 → 1.0.02016-07-19

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/3024847?v=4)[Joel Small](/maintainers/enigmatix)[@enigmatix](https://github.com/enigmatix)

---

Top Contributors

[![enigmatix](https://avatars.githubusercontent.com/u/3024847?v=4)](https://github.com/enigmatix "enigmatix (4 commits)")

---

Tags

helperrbacyii2

### Embed Badge

![Health badge](/badges/enigmatix-yii2-rbac/health.svg)

```
[![Health](https://phpackages.com/badges/enigmatix-yii2-rbac/health.svg)](https://phpackages.com/packages/enigmatix-yii2-rbac)
```

###  Alternatives

[2amigos/yii2-usuario

Highly customizable and extensible user management, authentication, and authorization Yii2 extension

294282.0k15](/packages/2amigos-yii2-usuario)[letyii/yii2-rbac-cached

Cached for yii2 RBAC

112.2k](/packages/letyii-yii2-rbac-cached)

PHPackages © 2026

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