title: Spring Security: Redirect to Login Page in case of 401
body: <p>I have an application that exposes a REST API and is secured using Spring Security. Is there a way to automatically redirect the client (from the server side) to the login page if a request sent to my server results in 401 - unauthorised?</p>