summaryrefslogtreecommitdiff
path: root/sleekxmpp/features/feature_mechanisms/mechanisms.py
diff options
context:
space:
mode:
authorLance Stout <lancestout@gmail.com>2012-08-17 10:17:35 -0700
committerLance Stout <lancestout@gmail.com>2012-08-17 10:17:35 -0700
commit8a03bd72ae5d07ebee2bcd13e66441a94edd4f1a (patch)
tree676dcff039486089e87af14903b52b2465424119 /sleekxmpp/features/feature_mechanisms/mechanisms.py
parentf0e1fc5aadcde96a8c8e776c77dd80e91368d216 (diff)
downloadslixmpp-8a03bd72ae5d07ebee2bcd13e66441a94edd4f1a.tar.gz
slixmpp-8a03bd72ae5d07ebee2bcd13e66441a94edd4f1a.tar.bz2
slixmpp-8a03bd72ae5d07ebee2bcd13e66441a94edd4f1a.tar.xz
slixmpp-8a03bd72ae5d07ebee2bcd13e66441a94edd4f1a.zip
Ensure that auth is done based on the original, requested JID and not on the bound JID.
Diffstat (limited to 'sleekxmpp/features/feature_mechanisms/mechanisms.py')
-rw-r--r--sleekxmpp/features/feature_mechanisms/mechanisms.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/sleekxmpp/features/feature_mechanisms/mechanisms.py b/sleekxmpp/features/feature_mechanisms/mechanisms.py
index c5b4c754..672f4fa6 100644
--- a/sleekxmpp/features/feature_mechanisms/mechanisms.py
+++ b/sleekxmpp/features/feature_mechanisms/mechanisms.py
@@ -92,13 +92,13 @@ class FeatureMechanisms(BasePlugin):
values = required_values.union(optional_values)
for value in values:
if value == 'username':
- result[value] = self.xmpp.boundjid.user
+ result[value] = self.xmpp.requested_jid.user
elif value == 'password':
result[value] = creds['password']
elif value == 'authzid':
result[value] = creds.get('authzid', '')
elif value == 'email':
- jid = self.xmpp.boundjid.bare
+ jid = self.xmpp.requested_jid.bare
result[value] = creds.get('email', jid)
elif value == 'channel_binding':
if sys.version_info >= (3, 3):
@@ -106,9 +106,9 @@ class FeatureMechanisms(BasePlugin):
else:
result[value] = None
elif value == 'host':
- result[value] = self.xmpp.boundjid.domain
+ result[value] = self.xmpp.requested_jid.domain
elif value == 'realm':
- result[value] = self.xmpp.boundjid.domain
+ result[value] = self.xmpp.requested_jid.domain
elif value == 'service-name':
result[value] = self.xmpp._service_name
elif value == 'service':