@Override
public void commence(HttpServletRequest request, HttpServletResponse response,
AuthenticationException authException) throws IOException, ServletException {
AuthenticationEntryPoint aep = (AuthenticationEntryPoint)
request.getAttribute(GeoServerSecurityFilter.AUTHENTICATION_ENTRY_POINT_HEADER);
if (aep!=null) // remove from request
request.removeAttribute(AUTHENTICATION_ENTRY_POINT_HEADER);
// entry point specified ?
if (getEntryEntryPoint()!=null) {
getEntryEntryPoint().commence(request, response, authException);
return;
}
// entry point from request ?
if (aep!=null) {
aep.commence(request, response, authException);
return;
}
// 403, FORBIDDEN
defaultEntryPoint.commence(request, response, authException);