public class DirectDigestAuthClient extends DirectClient<DigestCredentials,CommonProfile>
This class is the client to authenticate users directly through HTTP digest auth.
Add the commons-codec
dependency to use this class.
logger
Constructor and Description |
---|
DirectDigestAuthClient() |
DirectDigestAuthClient(Authenticator digestAuthenticator) |
DirectDigestAuthClient(Authenticator digestAuthenticator,
ProfileCreator profileCreator) |
Modifier and Type | Method and Description |
---|---|
protected void |
clientInit()
Initialize the client.
|
String |
getRealm() |
protected DigestCredentials |
retrieveCredentials(WebContext context)
Per RFC 2617
If a server receives a request for an access-protected object, and an
acceptable Authorization header is not sent, the server responds with
a "401 Unauthorized" status code, and a WWW-Authenticate header
|
void |
setRealm(String realm) |
String |
toString() |
getCredentials, getLogoutAction, internalInit, redirect
addAuthorizationGenerator, addAuthorizationGenerators, defaultAuthenticator, defaultCredentialsExtractor, defaultProfileCreator, getAuthenticator, getAuthorizationGenerators, getCredentialsExtractor, getCustomProperties, getName, getProfileCreator, getUserProfile, notifySessionRenewal, retrieveUserProfile, setAuthenticator, setAuthorizationGenerator, setAuthorizationGenerators, setAuthorizationGenerators, setCredentialsExtractor, setCustomProperties, setName, setProfileCreator
init
public DirectDigestAuthClient()
public DirectDigestAuthClient(Authenticator digestAuthenticator)
public DirectDigestAuthClient(Authenticator digestAuthenticator, ProfileCreator profileCreator)
protected void clientInit()
DirectClient
clientInit
in class DirectClient<DigestCredentials,CommonProfile>
protected DigestCredentials retrieveCredentials(WebContext context)
retrieveCredentials
in class BaseClient<DigestCredentials,CommonProfile>
context
- the web contextpublic String getRealm()
public void setRealm(String realm)
public String toString()
toString
in class BaseClient<DigestCredentials,CommonProfile>
Copyright © 2019. All rights reserved.