public class DefaultAuthenticationFeedbackHandler extends java.lang.Object implements AuthenticationFeedbackHandler
Constructor and Description |
---|
DefaultAuthenticationFeedbackHandler() |
Modifier and Type | Method and Description |
---|---|
void |
authenticationFailed(HttpServletRequest request,
HttpServletResponse response,
AuthenticationInfo authInfo)
This default implementation does nothing.
|
boolean |
authenticationSucceeded(HttpServletRequest request,
HttpServletResponse response,
AuthenticationInfo authInfo)
This default implementation calls the
handleRedirect(HttpServletRequest, HttpServletResponse) method
to optionally redirect the request after successful authentication. |
static boolean |
handleRedirect(HttpServletRequest request,
HttpServletResponse response)
Handles an optional request for a redirect after successful
authentication and
true if the request has been redirected. |
public DefaultAuthenticationFeedbackHandler()
public static boolean handleRedirect(HttpServletRequest request, HttpServletResponse response)
true
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.
true
if redirect was requested. Otherwise
false
is returned. Note, that true
is
returned regardless of whether sending the redirect response
succeeded or not.public void authenticationFailed(HttpServletRequest request, HttpServletResponse response, AuthenticationInfo authInfo)
Extensions of this class may overwrite to cleanup any internal state.
authenticationFailed
in interface AuthenticationFeedbackHandler
request
- The current requestresponse
- The current responseauthInfo
- The AuthenticationInfo
object used to
authenticate the request.public boolean authenticationSucceeded(HttpServletRequest request, HttpServletResponse response, AuthenticationInfo authInfo)
handleRedirect(HttpServletRequest, HttpServletResponse)
method
to optionally redirect the request after successful authentication.
Extensions of this class may overwrite this method to perform additional cleanup etc.
authenticationSucceeded
in interface AuthenticationFeedbackHandler
request
- The current requestresponse
- The current responseauthInfo
- The AuthenticationInfo
object used to
authenticate the request.handleRedirect(HttpServletRequest, HttpServletResponse)
method.Copyright © 2010 - 2020 Adobe. All Rights Reserved