arcanedev/laravel-policies
A lightweight Laravel package for working with authorization policies. It provides helpers to register, resolve, and organize policy classes, making it easier to map models to policies and keep access-control logic consistent across your application.
App\Models\User → App\Policies\UserPolicy) or in an explicit registry. If your codebase has non-conventional policy names, policies outside app/Policies, or domain modules that own their own authorization, an explicit registration layer is a legitimate pattern to evaluate.Gate::policy() and Laravel's policy resolution — on the order of tens of lines. The decision this package informs is not "should we adopt this dependency" but "should we write a small internal policy registry and copy this approach." Recommend the latter.spatie/laravel-permission, Laravel's native Gate abilities, or a policy-plus-scope approach) and this package does none of that work.Consider (as reference only, not as a dependency):
Gate::guessPolicyNamesUsing() doesn't cleanly cover.Look elsewhere (the default case):
Gate::policy() and Gate::guessPolicyNamesUsing() cover the overwhelming majority of registration needs with zero dependencies.To executives (one line): "We evaluated a small open-source Laravel package for organizing authorization policies and recommend not adopting it — it hasn't been updated since 2020, has essentially no users, and does work we can own internally in under a day of engineering at lower long-term risk."
To engineering (the substance):
Gate::policy($model, $policy), optionally with a Gate::guessPolicyNamesUsing() fallback. This gives us the same clarity with full test coverage and version control.How can I help you explore Laravel packages today?