public class SASLDigestMD5Mechanism
extends org.jivesoftware.smack.sasl.SASLDigestMD5Mechanism
org.jivesoftware.smack.sasl.SASLMechanism.AuthMechanism, org.jivesoftware.smack.sasl.SASLMechanism.Challenge, org.jivesoftware.smack.sasl.SASLMechanism.Failure, org.jivesoftware.smack.sasl.SASLMechanism.Response, org.jivesoftware.smack.sasl.SASLMechanism.Success
Constructor and Description |
---|
SASLDigestMD5Mechanism(org.jivesoftware.smack.SASLAuthentication saslAuthentication)
Creates our mechanism.
|
Modifier and Type | Method and Description |
---|---|
void |
authenticate(java.lang.String username,
java.lang.String host,
javax.security.auth.callback.CallbackHandler cbh)
Builds and sends the auth stanza to the server.
|
void |
authenticate(java.lang.String username,
java.lang.String host,
java.lang.String password)
Builds and sends the auth stanza to the server.
|
void |
challengeReceived(java.lang.String challenge)
The server is challenging the SASL mechanism for the stanza he just sent.
|
public SASLDigestMD5Mechanism(org.jivesoftware.smack.SASLAuthentication saslAuthentication)
saslAuthentication
- public void authenticate(java.lang.String username, java.lang.String host, java.lang.String password) throws java.io.IOException, org.jivesoftware.smack.XMPPException
authenticate(String, String, CallbackHandler)
whenever possible.authenticate
in class org.jivesoftware.smack.sasl.SASLMechanism
username
- the username of the user being authenticated.host
- the hostname where the user account resides.password
- the password for this account.java.io.IOException
- If a network error occurs while authenticating.org.jivesoftware.smack.XMPPException
- If a protocol error occurs or the user is not authenticated.public void authenticate(java.lang.String username, java.lang.String host, javax.security.auth.callback.CallbackHandler cbh) throws java.io.IOException, org.jivesoftware.smack.XMPPException
authenticate
in class org.jivesoftware.smack.sasl.SASLMechanism
username
- the username of the user being authenticated.host
- the hostname where the user account resides.cbh
- the CallbackHandler to obtain user information.java.io.IOException
- If a network error occurs while authenticating.org.jivesoftware.smack.XMPPException
- If a protocol error occurs or the user is not authenticated.public void challengeReceived(java.lang.String challenge) throws java.io.IOException
challengeReceived
in class org.jivesoftware.smack.sasl.SASLMechanism
challenge
- a base64 encoded string representing the challenge.java.io.IOException
- if an exception sending the response occurs.
Jitsi, the OpenSource Java VoIP and Instant Messaging client.
Distributable under Apache license.