|
|
|
|
@ -71,7 +71,7 @@ class Proxy(DatagramProtocol):
|
|
|
|
|
if self.clientinfo and _peer_id != b'\xff\xff\xff\xff':
|
|
|
|
|
print(f"{datetime.now().replace(microsecond=0)} Client: ID:{str(int_id(_peer_id)).rjust(9)} IP:{self.peerTrack[_peer_id]['shost'].rjust(15)} Port:{self.peerTrack[_peer_id]['sport']} Removed.")
|
|
|
|
|
self.transport.write(b'RPTCL'+_peer_id, (self.master,self.peerTrack[_peer_id]['dport']))
|
|
|
|
|
#Tell client we have closed do the session - 3 times, in case they are on a lossy network
|
|
|
|
|
#Tell client we have closed the session - 3 times, in case they are on a lossy network
|
|
|
|
|
self.transport.write(b'MSTCL',(self.peerTrack[_peer_id]['shost'],self.peerTrack[_peer_id]['sport']))
|
|
|
|
|
self.transport.write(b'MSTCL',(self.peerTrack[_peer_id]['shost'],self.peerTrack[_peer_id]['sport']))
|
|
|
|
|
self.transport.write(b'MSTCL',(self.peerTrack[_peer_id]['shost'],self.peerTrack[_peer_id]['sport']))
|
|
|
|
|
@ -154,7 +154,7 @@ class Proxy(DatagramProtocol):
|
|
|
|
|
# Remove the client after send a MSTN or MSTC packet
|
|
|
|
|
if _command in (MSTN,MSTC):
|
|
|
|
|
# Give time to the client for a reply to prevent port reassignment
|
|
|
|
|
self.peerTrack[_peer_id]['timer'].reset(15)
|
|
|
|
|
self.peerTrack[_peer_id]['timer'].reset(5)
|
|
|
|
|
|
|
|
|
|
return
|
|
|
|
|
|
|
|
|
|
|