This is how my security.yml looks like for access control list:
access_control:
- { path: ^/admin, roles: IS_AUTHENTICATED_FULLY }
- { path: ^/admin, roles: ROLE_ADMIN }
What I want to do is that user must have both roles (ROLE_ADMIN and IS_AUTHENTICATED_FULLY) in order to access the path as defined. But with above rules, if the user has any one of the role, the user can access the path as defined which i dont want. I also tried giving rule as follow with no success:
- { path: ^/admin, roles:[ROLE_ADMIN,IS_AUTHENTICATED_FULLY] }
How can I add rule that requires user to have both roles in order to access the path defined ?