mirror of
https://github.com/jlu5/PyLink.git
synced 2024-11-24 03:29:28 +01:00
Protocol: abort when receiving SQUIT to our own server
This commit is contained in:
parent
acd0c673cb
commit
9448bc86fd
@ -1285,10 +1285,15 @@ class Protocol():
|
||||
|
||||
def _squit(self, numeric, command, args):
|
||||
"""Handles incoming SQUITs."""
|
||||
# <- ABAAE SQ nefarious.midnight.vpn 0 :test
|
||||
|
||||
split_server = self._getSid(args[0])
|
||||
|
||||
# Normally we'd only need to check for our SID as the SQUIT target, but Nefarious
|
||||
# actually uses the uplink server as the SQUIT target.
|
||||
# <- ABAAE SQ nefarious.midnight.vpn 0 :test
|
||||
if split_server in (self.irc.sid, self.irc.uplink):
|
||||
raise ProtocolError('SQUIT received: (reason: %s)' % args[-1])
|
||||
|
||||
affected_users = []
|
||||
affected_nicks = []
|
||||
log.debug('(%s) Splitting server %s (reason: %s)', self.irc.name, split_server, args[-1])
|
||||
|
Loading…
Reference in New Issue
Block a user