org.openqa.jetty.jetty.servlet
Class FormAuthenticator
java.lang.Object
org.openqa.jetty.jetty.servlet.FormAuthenticator
- All Implemented Interfaces:
- java.io.Serializable, Authenticator
public class FormAuthenticator
- extends java.lang.Object
- implements Authenticator
FORM Authentication Authenticator.
The HTTP Session is used to store the authentication status of the
user, which can be distributed.
If the realm implements SSORealm, SSO is supported.
- Version:
- $Id: FormAuthenticator.java,v 1.32 2005/08/13 00:01:27 gregwilkins Exp $
- Author:
- Greg Wilkins (gregw), [email protected]
- See Also:
- Serialized Form
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
__J_URI
public static final java.lang.String __J_URI
- See Also:
- Constant Field Values
__J_AUTHENTICATED
public static final java.lang.String __J_AUTHENTICATED
- See Also:
- Constant Field Values
__J_SECURITY_CHECK
public static final java.lang.String __J_SECURITY_CHECK
- See Also:
- Constant Field Values
__J_USERNAME
public static final java.lang.String __J_USERNAME
- See Also:
- Constant Field Values
__J_PASSWORD
public static final java.lang.String __J_PASSWORD
- See Also:
- Constant Field Values
FormAuthenticator
public FormAuthenticator()
getAuthMethod
public java.lang.String getAuthMethod()
- Specified by:
getAuthMethod
in interface Authenticator
setLoginPage
public void setLoginPage(java.lang.String path)
getLoginPage
public java.lang.String getLoginPage()
setErrorPage
public void setErrorPage(java.lang.String path)
getErrorPage
public java.lang.String getErrorPage()
authenticate
public java.security.Principal authenticate(UserRealm realm,
java.lang.String pathInContext,
HttpRequest httpRequest,
HttpResponse httpResponse)
throws java.io.IOException
- Perform form authentication.
Called from SecurityHandler.
- Specified by:
authenticate
in interface Authenticator
- Parameters:
realm
- an UserRealm
valuepathInContext
- a String
valuehttpRequest
- a HttpRequest
valuehttpResponse
- a HttpResponse
value. If non-null response is passed,
then a failed authentication will result in a challenge response being
set in the response.
- Returns:
- UserPrincipal if authenticated else null.
- Throws:
java.io.IOException
- if an error occurs
isLoginOrErrorPage
public boolean isLoginOrErrorPage(java.lang.String pathInContext)
Copyright © 2011. All Rights Reserved.