diff options
Diffstat (limited to 'sleekxmpp/clientxmpp.py')
-rw-r--r-- | sleekxmpp/clientxmpp.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/sleekxmpp/clientxmpp.py b/sleekxmpp/clientxmpp.py index 2bbd138c..1734a13c 100644 --- a/sleekxmpp/clientxmpp.py +++ b/sleekxmpp/clientxmpp.py @@ -117,7 +117,7 @@ class ClientXMPP(BaseXMPP): self.register_feature( "<session xmlns='urn:ietf:params:xml:ns:xmpp-session' />", self._handle_start_session) - + def handle_connected(self, event=None): #TODO: Use stream state here self.authenticated = False @@ -125,7 +125,6 @@ class ClientXMPP(BaseXMPP): self.bound = False self.bindfail = False - def connect(self, address=tuple()): """ Connect to the XMPP server. @@ -319,7 +318,9 @@ class ClientXMPP(BaseXMPP): sasl_ns, auth)) elif 'sasl:ANONYMOUS' in self.features and not self.boundjid.user: - self.send("<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='ANONYMOUS' />") + self.send("<auth xmlns='%s' mechanism='%s' />" % ( + sasl_ns, + 'ANONYMOUS')) else: logging.error("No appropriate login method.") self.disconnect() |