-
Notifications
You must be signed in to change notification settings - Fork 7
Open
Description
When you specifiy several roles une the @secure annotation an AND is done beetwen the roles.
It is more logical to do an OR as done int the JMS bundle because you can filter it in the controller function.
To do it you must change in the Lsw\SecureControllerBundle\Security\ControllerListener onKernelController function
if (!$this->securityContext->isGranted($role)) {
throw new AccessDeniedException(
'Current user is not granted required role "'.$role.'".'
);
}
}
by
if ($this->securityContext->isGranted($role)) return;
}
throw new AccessDeniedException('Current user is not granted');
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels