symfonysymfony-voters
Implement granular authorization with Symfony Voters; decouple permission logic from controllers; test authorization separately from business logic
When & Why to Use This Skill
This Claude skill streamlines the implementation of granular authorization within the Symfony framework using Voters. It focuses on improving software architecture by decoupling complex permission logic from controllers, which enhances code maintainability and enables independent testing of security rules according to PHP best practices.
Use Cases
- Refactoring bloated Symfony controllers by moving complex access control logic into dedicated, reusable Voter classes.
- Implementing fine-grained Attribute-Based Access Control (ABAC) to manage permissions for specific database entities.
- Setting up isolated unit tests for authorization logic to ensure security requirements are met without involving core business services.
| name | symfony:symfony-voters |
|---|---|
| description | Use when symfony symfony voters |
symfony:symfony-voters (Micro)
Use when
- Use when symfony symfony voters
Rules
- Keep changes minimal and focused
- Ask before running servers/builds/tests
- Load reference/examples only on explicit request
References
reference.mddocs/complexity-tiers.md