mirror of
https://codeberg.org/Mercury-IM/Smack
synced 2024-11-21 22:02:06 +01:00
Fix SASL EXTERNAL with client cert provided JID
isAnonymous() is now a bit weakened since it also considers
allowNullorEmptyUsername.
SaslExternalMechanism of smack-sasl-provided now also doesn't throw an
UnsupportedOperationException.
Follow up on 7e4e3699a1
This commit is contained in:
parent
1d83db898e
commit
c682091a47
2 changed files with 4 additions and 2 deletions
|
@ -532,7 +532,8 @@ public abstract class AbstractXMPPConnection implements XMPPConnection {
|
|||
|
||||
@Override
|
||||
public final boolean isAnonymous() {
|
||||
return config.getUsername() == null && usedUsername == null;
|
||||
return config.getUsername() == null && usedUsername == null
|
||||
&& !config.allowNullOrEmptyUsername;
|
||||
}
|
||||
|
||||
private String serviceName;
|
||||
|
|
|
@ -34,7 +34,8 @@ public class SASLExternalMechanism extends SASLMechanism {
|
|||
|
||||
@Override
|
||||
protected void authenticateInternal(CallbackHandler cbh) throws SmackException {
|
||||
throw new UnsupportedOperationException("CallbackHandler not (yet) supported");
|
||||
// Do nothing. Auth will be done external to Smack and which will receive the localpart
|
||||
// after the resource binding
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
Loading…
Reference in a new issue