mirror of
https://github.com/vanitasvitae/Smack.git
synced 2024-11-22 20:12:07 +01:00
Remove SASLAuthentication.init()
This commit is contained in:
parent
bf538129c2
commit
93aaf6d8d7
2 changed files with 2 additions and 11 deletions
|
@ -500,7 +500,6 @@ public abstract class AbstractXMPPConnection implements XMPPConnection {
|
||||||
|
|
||||||
// Reset the connection state
|
// Reset the connection state
|
||||||
initState();
|
initState();
|
||||||
saslAuthentication.init();
|
|
||||||
streamId = null;
|
streamId = null;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
|
|
@ -168,7 +168,6 @@ public final class SASLAuthentication {
|
||||||
SASLAuthentication(AbstractXMPPConnection connection, ConnectionConfiguration configuration) {
|
SASLAuthentication(AbstractXMPPConnection connection, ConnectionConfiguration configuration) {
|
||||||
this.configuration = configuration;
|
this.configuration = configuration;
|
||||||
this.connection = connection;
|
this.connection = connection;
|
||||||
this.init();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -200,6 +199,8 @@ public final class SASLAuthentication {
|
||||||
final String host = connection.getHost();
|
final String host = connection.getHost();
|
||||||
final DomainBareJid xmppServiceDomain = connection.getXMPPServiceDomain();
|
final DomainBareJid xmppServiceDomain = connection.getXMPPServiceDomain();
|
||||||
|
|
||||||
|
authenticationSuccessful = false;
|
||||||
|
|
||||||
synchronized (this) {
|
synchronized (this) {
|
||||||
if (callbackHandler != null) {
|
if (callbackHandler != null) {
|
||||||
currentMechanism.authenticate(host, xmppServiceDomain, callbackHandler, authzid, sslSession);
|
currentMechanism.authenticate(host, xmppServiceDomain, callbackHandler, authzid, sslSession);
|
||||||
|
@ -322,15 +323,6 @@ public final class SASLAuthentication {
|
||||||
return authenticationSuccessful;
|
return authenticationSuccessful;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Initializes the internal state in order to be able to be reused. The authentication
|
|
||||||
* is used by the connection at the first login and then reused after the connection
|
|
||||||
* is disconnected and then reconnected.
|
|
||||||
*/
|
|
||||||
void init() {
|
|
||||||
authenticationSuccessful = false;
|
|
||||||
}
|
|
||||||
|
|
||||||
String getNameOfLastUsedSaslMechansism() {
|
String getNameOfLastUsedSaslMechansism() {
|
||||||
SASLMechanism lastUsedMech = currentMechanism;
|
SASLMechanism lastUsedMech = currentMechanism;
|
||||||
if (lastUsedMech == null) {
|
if (lastUsedMech == null) {
|
||||||
|
|
Loading…
Reference in a new issue