orbitale/permissions-bundle
Symfony bundle for managing permissions and access control with simple annotations. Define permissions in YAML, attach them to controller actions, and check user rights through a lightweight, cache-friendly API that integrates cleanly into existing Symfony security setups.
permissions directive — is a legitimate design pattern to evaluate when moving from coarse roles (ROLE_ADMIN) to named, per-action permissions (e.g. invoice.refund). This is a roadmap-level decision worth making deliberately rather than accreting $user->can() calls ad hoc.Consider it only under narrow conditions:
security.voters and @IsGranted-style annotation system, which Laravel has no equivalent hook for), and you need a stopgap to consolidate sprawling role checks.Look elsewhere when:
Gate/Policy system plus spatie/laravel-permission or josephsilber/bouncer covers the same ground natively, with active maintenance and PHP 8+ support. Adopting a Symfony bundle here means fighting the framework.IsGranted attribute + voters, or the maintained symfony/security-bundle patterns, supersede this entirely.To executives: We evaluated orbitale/permissions-bundle and recommend against adoption. Three disqualifiers: it is a Symfony bundle rather than a Laravel package, so it does not integrate with our framework; its last release was December 2017, meaning no security patches or PHP 8 support; and it has zero downstream dependents, so no one is maintaining it. The underlying idea is sound and cheap to replicate — we can implement the same single-permission-check pattern using Laravel's built-in Gate system in roughly a day of engineering, with full support and no third-party risk.
To engineering: Don't install this. It's a Symfony security voter keyed off a permissions annotation; Laravel's authorization pipeline has no seam for it. What we should take from it is the pattern: one Gate::before/dynamic-gate registration that resolves a permission string against a single source of truth, rather than N bespoke policies. Concretely — define permissions as an enum or seeded table, register them via Gate::define in a service provider loop, and enforce with $this->authorize() in controllers and @can in views. That gives us the same ergonomics, the same auditability, and no abandoned dependency. If anyone wants the 2017 source as a design reference, read it; don't require it.
How can I help you explore Laravel packages today?