possible TB on active reply
This commit is contained in:
parent
3ae4c1e0d4
commit
d23bb1ffee
|
@ -484,7 +484,11 @@ class Connection:
|
||||||
except:
|
except:
|
||||||
pass
|
pass
|
||||||
if streamhost is not None: # this is a result for proxy request
|
if streamhost is not None: # this is a result for proxy request
|
||||||
jid = streamhost.getAttr('jid')
|
jid = None
|
||||||
|
try:
|
||||||
|
jid = streamhost.getAttr('jid')
|
||||||
|
except:
|
||||||
|
raise common.xmpp.NodeProcessed
|
||||||
proxyhosts = []
|
proxyhosts = []
|
||||||
for item in query.getChildren():
|
for item in query.getChildren():
|
||||||
if item.getName() == 'streamhost':
|
if item.getName() == 'streamhost':
|
||||||
|
@ -500,6 +504,9 @@ class Connection:
|
||||||
try:
|
try:
|
||||||
streamhost = query.getTag('streamhost-used')
|
streamhost = query.getTag('streamhost-used')
|
||||||
except: # this bytestream result is not what we need
|
except: # this bytestream result is not what we need
|
||||||
|
pass
|
||||||
|
if streamhost is None:
|
||||||
|
# proxy approves the activate query
|
||||||
raise common.xmpp.NodeProcessed
|
raise common.xmpp.NodeProcessed
|
||||||
jid = streamhost.getAttr('jid')
|
jid = streamhost.getAttr('jid')
|
||||||
id = real_id[3:]
|
id = real_id[3:]
|
||||||
|
@ -671,7 +678,7 @@ class Connection:
|
||||||
listener = gajim.socks5queue.start_listener(self.peerhost[0], port,
|
listener = gajim.socks5queue.start_listener(self.peerhost[0], port,
|
||||||
sha_str, self.result_socks5_sid, file_props['sid'])
|
sha_str, self.result_socks5_sid, file_props['sid'])
|
||||||
if listener == None:
|
if listener == None:
|
||||||
#~ # FIXME - raise error dialog that address is in use
|
# FIXME - raise error dialog that address is in use
|
||||||
return
|
return
|
||||||
|
|
||||||
iq = common.xmpp.Protocol(name = 'iq', to = str(receiver),
|
iq = common.xmpp.Protocol(name = 'iq', to = str(receiver),
|
||||||
|
|
|
@ -550,6 +550,7 @@ class Socks5:
|
||||||
def _get_sha1_auth(self):
|
def _get_sha1_auth(self):
|
||||||
''' get sha of sid + Initiator jid + Target jid '''
|
''' get sha of sid + Initiator jid + Target jid '''
|
||||||
if self.file_props.has_key('is_a_proxy'):
|
if self.file_props.has_key('is_a_proxy'):
|
||||||
|
del(self.file_props['is_a_proxy'])
|
||||||
return sha.new('%s%s%s' % (self.sid, self.file_props['proxy_sender'],
|
return sha.new('%s%s%s' % (self.sid, self.file_props['proxy_sender'],
|
||||||
self.file_props['proxy_receiver'])).hexdigest()
|
self.file_props['proxy_receiver'])).hexdigest()
|
||||||
return sha.new('%s%s%s' % (self.sid, self.initiator, self.target)).hexdigest()
|
return sha.new('%s%s%s' % (self.sid, self.initiator, self.target)).hexdigest()
|
||||||
|
|
Loading…
Reference in New Issue