From 1675c438418d71fc2fd4bf50a0356024c2e6c64b Mon Sep 17 00:00:00 2001 From: James Lu Date: Sun, 10 Jul 2016 20:27:09 -0700 Subject: [PATCH] ts6: the @cooper fix Validate that incoming TS is valid, because bad user timestamps like 0 will cause InspIRCd networks to SQUIT if forwarded over Relay. --- protocols/ts6.py | 1 + 1 file changed, 1 insertion(+) diff --git a/protocols/ts6.py b/protocols/ts6.py index cbbbb71..26331d7 100644 --- a/protocols/ts6.py +++ b/protocols/ts6.py @@ -505,6 +505,7 @@ class TS6Protocol(TS6BaseProtocol): log.debug('(%s) handle_euid got args: nick=%s ts=%s uid=%s ident=%s ' 'host=%s realname=%s realhost=%s ip=%s', self.irc.name, nick, ts, uid, ident, host, realname, realhost, ip) + assert ts != 0, "Bad TS 0 for user %s" % uid if ip == '0': # IP was invalid; something used for services. ip = '0.0.0.0'