From Symfony 2.3 Security docs:
If access is denied, the system will try to authenticate the user if not already (e.g. redirect the user to th
Could you not just have two login routes?
For example, in security config set
form_login:
login_path: /login_message
In your login controller
/**
* @Template()
* @Route("/notauthorized", name="login_message")
*/
public function loginMessageAction()
{
return [];
}
And then in your loginMessage.html.twg
You must login to access this page.