PHPackages                             cblink/hyperf-casbin - 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. [Security](/categories/security)
4. /
5. cblink/hyperf-casbin

ActiveLibrary[Security](/categories/security)

cblink/hyperf-casbin
====================

01.4kPHP

Since Oct 17Pushed 3y ago3 watchersCompare

[ Source](https://github.com/cblink/hyperf-casbin)[ Packagist](https://packagist.org/packages/cblink/hyperf-casbin)[ RSS](/packages/cblink-hyperf-casbin/feed)WikiDiscussions main Synced 3w ago

READMEChangelogDependenciesVersions (1)Used By (0)

 hyperf-casbin
===============

[](#-hyperf-casbin-)

 .

This library is casbin for hyperf. It allows you to easily use casbin in hyperf. Note that it must use Redis, so make sure your project has Redis.

Thanks for the reference provided by the project:

### Installation

[](#installation)

```
composer require cblink/hyperf-casbin

```

Usage
-----

[](#usage)

```
$enforcer = new Enforcer();

//add permission for user
$enforcer->addPermissionForUser('permission', 'user', 'obj', 'act');

//todo

```

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

[](#contributing)

You can contribute in one of three ways:

1. File bug reports using the [issue tracker](https://github.com/cblink/hyperf-casbin/issues).
2. Answer questions or fix bugs on the [issue tracker](https://github.com/cblink/hyperf-casbin/issues).
3. Contribute new features or update the wiki.

*The code contribution process is not very formal. You just need to make sure that you follow the PSR-0, PSR-1, and PSR-2 coding guidelines. Any new code contributions must be accompanied by unit tests where applicable.*

License
-------

[](#license)

MIT

###  Health Score

19

—

LowBetter than 9% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity15

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity25

Early-stage or recently created project

 Bus Factor1

Top contributor holds 66.7% 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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/bfb99629f5da26101e9bdd9c941a00e7d1cd0a883ff51d4edf338f667ee1f685?d=identicon)[elevenDimension](/maintainers/elevenDimension)

---

Top Contributors

[![0daynick](https://avatars.githubusercontent.com/u/17755109?v=4)](https://github.com/0daynick "0daynick (2 commits)")[![elevenwd](https://avatars.githubusercontent.com/u/27636308?v=4)](https://github.com/elevenwd "elevenwd (1 commits)")

### Embed Badge

![Health badge](/badges/cblink-hyperf-casbin/health.svg)

```
[![Health](https://phpackages.com/badges/cblink-hyperf-casbin/health.svg)](https://phpackages.com/packages/cblink-hyperf-casbin)
```

###  Alternatives

[mews/purifier

Laravel 5/6/7/8/9/10 HtmlPurifier Package

2.0k18.7M143](/packages/mews-purifier)[paragonie/ecc

PHP Elliptic Curve Cryptography library

24820.0k38](/packages/paragonie-ecc)[laravelgems/blade-escape

Custom blade directives to figth against XSS

1212.5k](/packages/laravelgems-blade-escape)

PHPackages © 2026

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