>>10I just made it so that anyone sending messages that aren't probably terminated (i.e., stray "\n" or "\r" in the messages) gets their connection killed.
From RFC 1459:
IRC messages are always lines of characters terminated with a CR-LF
(Carriage Return - Line Feed) pair, and these messages shall not
exceed 512 characters in length, counting all characters including
the trailing CR-LF.
Technically clients should reject a message that doesn't conform to that (one with a stray LF). I suppose CR, LF, and NUL aren't allowed in the message either, so the IRCd now behaves appropriately anyway. Things like ChatZilla only use LF instead of CRLF and apparently all clients just take an LF by itself as a terminator even though they shouldn't. There might be some shitty daemons around that only use LF and therefore clients have just taken the path of least resistance and only look for an LF.
As far as how they figured out, I don't know, just guessing and messing around? Had the insight to see if there were errors in the protocol parser, which was the part I was most likely to forget something on.