# cybercog/laravel-ban

Laravel Ban simplify blocking and banning Eloquent models.

Repository: https://github.com/cybercog/laravel-ban
Canonical: https://ross.abutalabs.com/products/laravel-ban
Homepage: https://komarev.com/sources/laravel-ban
Language: PHP
License: MIT
License Family: permissive
Topics: laravel, eloquent, cog, trait, ban, jail, block, access, security, package, justice, restrict, forbid, arrest, user, prison, sanction, php
Last push: 2026-03-01T14:25:58+00:00

## Health v2 (maintenance only)
Score: 66/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 70, release rhythm 40, longevity 100
- inputs: {"age_days": 3468, "days_push": 185, "days_rel": 185, "gap_med": 371, "n_releases_24m": 2}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1126, forks 64 (observed 2026-08-28T04:03:41.300604+00:00)

## What it is
Laravel Ban is a PHP package that adds banning and blocking capabilities to any Laravel Eloquent model via traits and a BanService. It supports ban history, events, scopes, and middleware to prevent banned users from accessing routes.

## Use cases
- ban users in a laravel app
- block eloquent models
- prevent banned users from accessing routes
- keep a history of removed bans
- ban organizations or teams not just users

## When to choose
- you use Laravel Eloquent and need ban/block functionality
- you want ban events, scopes, and middleware out of the box
- you need to ban non-user models like teams or organizations

## When to avoid
- you are not using Laravel or Eloquent
- you need full-featured access control or role-based permissions rather than simple banning
- you need IP-based or infrastructure-level blocking

## Facets
- artifact type: library
- maturity: stable
- function: auth, authorization, middleware, orm
- domain: web-development, security, developer-tools
- platform: php
- tags: laravel-package, eloquent, bannable-models, user-blocking, traits, laravel

## Member repositories
- cybercog/laravel-ban (main) score 66

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:03:41.300604+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T06:39:11.733899+00:00, confidence not recorded.
  - readme: https://github.com/cybercog/laravel-ban (fetched 2026-08-28T04:03:41.300604+00:00, sha e3e391030293)
  - homepage: https://komarev.com/sources/laravel-ban (fetched 2026-08-29T12:43:34.401032+00:00, sha c16769b6ea53)
- Data as of 2026-08-30T08:39:29.467469+00:00.
