sasl not support msg using debug. Dimitur, maybe it is time to remove blocking versions from svn?

This commit is contained in:
Nikos Kouremenos 2006-02-19 20:50:59 +00:00
parent 571c0d0cb6
commit 105616cfc3
1 changed files with 2 additions and 2 deletions

View File

@ -65,7 +65,7 @@ class SASL(PlugIn):
''' Used to determine if server supports SASL auth. Used internally. ''' ''' Used to determine if server supports SASL auth. Used internally. '''
if not feats.getTag('mechanisms', namespace=NS_SASL): if not feats.getTag('mechanisms', namespace=NS_SASL):
self.startsasl='not-supported' self.startsasl='not-supported'
print >> sys.stderr, 'SASL not supported by server' self.DEBUG('SASL not supported by server', 'error')
return return
mecs=[] mecs=[]
for mec in feats.getTag('mechanisms', namespace=NS_SASL).getTags('mechanism'): for mec in feats.getTag('mechanisms', namespace=NS_SASL).getTags('mechanism'):
@ -74,7 +74,7 @@ class SASL(PlugIn):
self._owner.RegisterHandler('failure', self.SASLHandler, xmlns=NS_SASL) self._owner.RegisterHandler('failure', self.SASLHandler, xmlns=NS_SASL)
self._owner.RegisterHandler('success', self.SASLHandler, xmlns=NS_SASL) self._owner.RegisterHandler('success', self.SASLHandler, xmlns=NS_SASL)
if "DIGEST-MD5" in mecs: if "DIGEST-MD5" in mecs:
node=Node('auth',attrs={'xmlns':NS_SASL,'mechanism':'DIGEST-MD5'}) node=Node('auth',attrs={'xmlns': NS_SASL, 'mechanism': 'DIGEST-MD5'})
elif "PLAIN" in mecs: elif "PLAIN" in mecs:
sasl_data='%s\x00%s\x00%s' % (self.username+'@' + self._owner.Server, sasl_data='%s\x00%s\x00%s' % (self.username+'@' + self._owner.Server,
self.username, self.password) self.username, self.password)