public class HttpBasicAuthentication extends Object implements HttpAuthentication, Configurable
| Modifier | Constructor and Description |
|---|---|
protected |
HttpBasicAuthentication(String challenge,
Configuration conf)
Construct an HttpBasicAuthentication for the given challenge parameters.
|
| Modifier and Type | Method and Description |
|---|---|
static HttpBasicAuthentication |
getAuthentication(String challenge,
Configuration conf)
This method is responsible for providing Basic authentication information.
|
static Pattern |
getBasicPattern()
Provides a pattern which can be used by an outside resource to determine if
this class can provide credentials based on simple header information.
|
Configuration |
getConf() |
List<String> |
getCredentials()
Gets the Basic credentials generated by this HttpBasicAuthentication object
|
String |
getRealm()
Gets the realm attribute of the HttpBasicAuthentication object.
|
void |
setConf(Configuration conf) |
protected HttpBasicAuthentication(String challenge, Configuration conf) throws HttpAuthenticationException
WWW-Authenticate: Basic realm="myrealm"challenge - WWW-Authenticate header from web serverHttpAuthenticationExceptionpublic void setConf(Configuration conf)
setConf in interface Configurablepublic Configuration getConf()
getConf in interface Configurablepublic List<String> getCredentials()
getCredentials in interface HttpAuthenticationAuthorization: Basic <Base64 encoded userid:password>public String getRealm()
getAuthentication(String, Configuration)
static methodgetRealm in interface HttpAuthenticationpublic static HttpBasicAuthentication getAuthentication(String challenge, Configuration conf)
challenge - The challenge string provided by the webserver. This is the text
which follows the WWW-Authenticate header, including the Basic
tag.public static final Pattern getBasicPattern()
Copyright © 2021 The Apache Software Foundation