Package org.restlet.data
Class AuthenticationInfo
java.lang.Object
org.restlet.data.AuthenticationInfo
Preemptive authentication information. Sent by an origin server to a client
after a successful digest authentication attempt.
Note that when used with HTTP connectors, this class maps to the "Authentication-Info" header.
Note that when used with HTTP connectors, this class maps to the "Authentication-Info" header.
- Author:
- Kelly McLaughlin, Jerome Louvel
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionAuthenticationInfo(String nextNonce, int nonceCount, String cnonce, String quality, String responseDigest) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanReturns the client nonce.Returns the next server nonce.intReturns the nonce-count value.Returns the quality of protection.Returns the optional response digest for mutual authentication.inthashCode()voidsetClientNonce(String clientNonce) Sets the client nonce.voidsetNextServerNonce(String nextNonce) Sets the next server nonce.voidsetNonceCount(int nonceCount) Sets the nonce-count value.voidsetQuality(String qop) Sets the quality of protection.voidsetResponseDigest(String responseDigest) Sets the optional response digest for mutual authentication.
-
Constructor Details
-
AuthenticationInfo
public AuthenticationInfo(String nextNonce, int nonceCount, String cnonce, String quality, String responseDigest) Constructor.- Parameters:
nextNonce- The next nonce value.nonceCount- The nonce-count value.cnonce- The cnonce value.quality- The quality of protection.responseDigest- The optional response digest for mutual authentication.
-
-
Method Details
-
equals
-
getClientNonce
Returns the client nonce.- Returns:
- The client nonce.
-
getNextServerNonce
Returns the next server nonce. This is the nonce the server wishes the client to use for a future authentication response- Returns:
- The next nonce value.
-
getNonceCount
public int getNonceCount()Returns the nonce-count value.- Returns:
- The nonce-count value.
-
getQuality
Returns the quality of protection. The value can beChallengeMessage.QUALITY_AUTHENTICATIONfor authentication orChallengeMessage.QUALITY_AUTHENTICATION_INTEGRITYfor authentication with integrity protection.- Returns:
- The quality of protection.
-
getResponseDigest
Returns the optional response digest for mutual authentication. Note that when used with HTTP connectors, this property maps to the "response-digest" value in the "response-auth" directive of the "Authentication-Info" header.- Returns:
- The optional response digest for mutual authentication.
-
hashCode
public int hashCode() -
setClientNonce
Sets the client nonce.- Parameters:
clientNonce- The client nonce.
-
setNextServerNonce
Sets the next server nonce. This is the nonce the server wishes the client to use for a future authentication response- Parameters:
nextNonce- The next nonce.
-
setNonceCount
public void setNonceCount(int nonceCount) Sets the nonce-count value.- Parameters:
nonceCount- The nonceCount value.
-
setQuality
Sets the quality of protection. The value can beChallengeMessage.QUALITY_AUTHENTICATIONfor authentication orChallengeMessage.QUALITY_AUTHENTICATION_INTEGRITYfor authentication with integrity protection.- Parameters:
qop- The quality of protection.
-
setResponseDigest
Sets the optional response digest for mutual authentication. Note that when used with HTTP connectors, this property maps to the "response-digest" value in the "response-auth" directive of the "Authentication-Info" header.- Parameters:
responseDigest- The response digest.
-