summaryrefslogtreecommitdiff
path: root/sleekxmpp
diff options
context:
space:
mode:
Diffstat (limited to 'sleekxmpp')
-rw-r--r--sleekxmpp/features/feature_mechanisms/mechanisms.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/sleekxmpp/features/feature_mechanisms/mechanisms.py b/sleekxmpp/features/feature_mechanisms/mechanisms.py
index 3818c70e..6f01cb14 100644
--- a/sleekxmpp/features/feature_mechanisms/mechanisms.py
+++ b/sleekxmpp/features/feature_mechanisms/mechanisms.py
@@ -32,6 +32,9 @@ class FeatureMechanisms(BasePlugin):
def plugin_init(self):
self.use_mech = self.config.get('use_mech', None)
+ if not self.use_mech and not self.xmpp.boundjid.user:
+ self.use_mech = 'ANONYMOUS'
+
def tls_active():
return 'starttls' in self.xmpp.features