Class DefaultAuthenticationFeedbackHandler
java.lang.Object
org.apache.sling.commons.auth.spi.DefaultAuthenticationFeedbackHandler
- All Implemented Interfaces:
AuthenticationFeedbackHandler
@Deprecated(since="2015")
public class DefaultAuthenticationFeedbackHandler
extends Object
implements AuthenticationFeedbackHandler
Deprecated.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
authenticationFailed
(HttpServletRequest request, HttpServletResponse response, AuthenticationInfo authInfo) Deprecated.This default implementation does nothing.boolean
authenticationSucceeded
(HttpServletRequest request, HttpServletResponse response, AuthenticationInfo authInfo) Deprecated.This default implementation calls thehandleRedirect(HttpServletRequest, HttpServletResponse)
method to optionally redirect the request after successful authentication.static boolean
handleRedirect
(HttpServletRequest request, HttpServletResponse response) Deprecated.Handles an optional request for a redirect after successful authentication andtrue
if the request has been redirected.
-
Constructor Details
-
DefaultAuthenticationFeedbackHandler
public DefaultAuthenticationFeedbackHandler()Deprecated.
-
-
Method Details
-
handleRedirect
Deprecated.Handles an optional request for a redirect after successful authentication andtrue
if the request has been redirected.If sending the redirect response fails due to some IO problems, the request is still terminated but an error message is logged indicating the problem.
- Returns:
true
if redirect was requested. Otherwisefalse
is returned. Note, thattrue
is returned regardless of whether sending the redirect response succeeded or not.
-
authenticationFailed
public void authenticationFailed(HttpServletRequest request, HttpServletResponse response, AuthenticationInfo authInfo) Deprecated.This default implementation does nothing.Extensions of this class may overwrite to cleanup any internal state.
- Specified by:
authenticationFailed
in interfaceAuthenticationFeedbackHandler
- Parameters:
request
- The current requestresponse
- The current responseauthInfo
- TheAuthenticationInfo
object used to authenticate the request.
-
authenticationSucceeded
public boolean authenticationSucceeded(HttpServletRequest request, HttpServletResponse response, AuthenticationInfo authInfo) Deprecated.This default implementation calls thehandleRedirect(HttpServletRequest, HttpServletResponse)
method to optionally redirect the request after successful authentication.Extensions of this class may overwrite this method to perform additional cleanup etc.
- Specified by:
authenticationSucceeded
in interfaceAuthenticationFeedbackHandler
- Parameters:
request
- The current requestresponse
- The current responseauthInfo
- TheAuthenticationInfo
object used to authenticate the request.- Returns:
- the result of calling the
handleRedirect(HttpServletRequest, HttpServletResponse)
method.
-