java.lang.Object
org.apache.jena.http.auth.AuthHeader
Parser for authentication header strings for both challenge and credentials.
- This parser is scheme-specific. e.g. digest credentials can not be token68.
- This parser does not check auth-params names.
- The auth-params map has lower case keys.
-
Method Summary
Modifier and TypeMethodDescriptionstatic AuthHeaderbearerToken(String tokenString) Create an AuthHeader for bearer with a token value.Get the string after the auth scheme as written in the authentication header value.Any auth scheme value that has a=b auth-params, else null.Get theAuthScheme.Get the auth scheme as written in the authentication header value.Return user-password (still base64 encoded) or null (if not basic auth)The rest of the line for "unknown"booleanIs this basic auth?booleanIs this Bearer auth?booleanIs this Digest auth? The digest auth-params are available fromgetAuthParams()booleanIs this some unkown scheme? (not basic, digest or bearer).static AuthHeaderCreate an AuthHeader by parsing an "Authorization" header.static AuthHeaderparseChallenge(String string) Create an AuthHeader by parsing a "WWW-Authenticate" header.
-
Method Details
-
parseAuth
Create an AuthHeader by parsing an "Authorization" header. -
parseChallenge
Create an AuthHeader by parsing a "WWW-Authenticate" header. -
bearerToken
Create an AuthHeader for bearer with a token value. -
getAuthScheme
Get theAuthScheme. -
getAuthSchemeName
Get the auth scheme as written in the authentication header value. -
getAuthArgs
Get the string after the auth scheme as written in the authentication header value. -
getAuthParams
Any auth scheme value that has a=b auth-params, else null. -
isBasicAuth
public boolean isBasicAuth()Is this basic auth? -
getBasicUserPassword
Return user-password (still base64 encoded) or null (if not basic auth) -
isDigestAuth
public boolean isDigestAuth()Is this Digest auth? The digest auth-params are available fromgetAuthParams() -
isBearerAuth
public boolean isBearerAuth()Is this Bearer auth? -
getBearerToken
-
isUnknownAuth
public boolean isUnknownAuth()Is this some unkown scheme? (not basic, digest or bearer). The rest of the line is available fromgetUnknown(). -
getUnknown
The rest of the line for "unknown"
-