PHPackages                             hlf513/phprbac - 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. hlf513/phprbac

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

hlf513/phprbac
==============

OWASP/phprbac的修改版。修复了一些bug,并对数据库配置的获取做了调整

2.1.0(9y ago)120Apache-2.0PHPPHP &gt;=5.3

Since Mar 14Pushed 9y ago1 watchersCompare

[ Source](https://github.com/hlf513/rbac)[ Packagist](https://packagist.org/packages/hlf513/phprbac)[ Docs](http://phprbac.net/)[ RSS](/packages/hlf513-phprbac/feed)WikiDiscussions master Synced 4w ago

READMEChangelogDependenciesVersions (3)Used By (0)

PHP-RBAC v2.0 修正版
=================

[](#php-rbac-v20-修正版)

使用方法见:

修改的地方
-----

[](#修改的地方)

1. 规范了注释
2. 修改了bug

    - base.php中的delete()方法: > $this-&gt;left =&gt; $this-&gt;Left
    - rbac.php中\\BascRbac的descendants()方法: > //$out \[$v\['Title'\]\] = $v;
        > $out \[\] = $v;
3. 增加了数据库配置的参数化

    > $rbac = new \\PhpRbac\\Rbac($db-&gt;pdo,'phprbac\_');

    参数有三种

    - string : 'unit\_test'
    - array : db配置数组
    - object : PDO | mysqli
4. 其他

    - 未定义变量的初始化

安装
--

[](#安装)

> composer require hlf513/phprbac

###  Health Score

27

—

LowBetter than 47% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 83.4% 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 ~898 days

Total

2

Last Release

3592d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/2879497?v=4)[Longfei He](/maintainers/hlf513)[@hlf513](https://github.com/hlf513)

---

Top Contributors

[![jburns131](https://avatars.githubusercontent.com/u/1120974?v=4)](https://github.com/jburns131 "jburns131 (121 commits)")[![hlf513](https://avatars.githubusercontent.com/u/2879497?v=4)](https://github.com/hlf513 "hlf513 (12 commits)")[![abiusx](https://avatars.githubusercontent.com/u/1401691?v=4)](https://github.com/abiusx "abiusx (7 commits)")[![bblue](https://avatars.githubusercontent.com/u/6132918?v=4)](https://github.com/bblue "bblue (2 commits)")[![bleuscyther](https://avatars.githubusercontent.com/u/2999487?v=4)](https://github.com/bleuscyther "bleuscyther (1 commits)")[![Bilge](https://avatars.githubusercontent.com/u/470626?v=4)](https://github.com/Bilge "Bilge (1 commits)")[![SiGhTfOrbACQ](https://avatars.githubusercontent.com/u/126778?v=4)](https://github.com/SiGhTfOrbACQ "SiGhTfOrbACQ (1 commits)")

---

Tags

securitypermissionrbacowasp

### Embed Badge

![Health badge](/badges/hlf513-phprbac/health.svg)

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

###  Alternatives

[spatie/laravel-permission

Permission handling for Laravel 12 and up

12.9k98.0M1.3k](/packages/spatie-laravel-permission)[bezhansalleh/filament-shield

Filament support for `spatie/laravel-permission`.

2.8k3.5M118](/packages/bezhansalleh-filament-shield)[owasp/phprbac

PHP-RBAC is the de-facto authorization library for PHP. It provides developers with NIST Level 2 Standard Role Based Access Control and more, in the fastest implementation yet.

435985.8k4](/packages/owasp-phprbac)[efficiently/authority-controller

AuthorityController is an PHP authorization library for Laravel 5 which restricts what resources a given user is allowed to access.

15433.2k](/packages/efficiently-authority-controller)[olivier127/rbac-bundle

Symfony PhpRabcBundle allow to use RBAC control access for symfony project

328.7k](/packages/olivier127-rbac-bundle)[hosseinhezami/laravel-permission-manager

Advanced permission manager for Laravel.

383.3k](/packages/hosseinhezami-laravel-permission-manager)

PHPackages © 2026

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