Files
znc/IRCSock.cpp
psychon 57fe412a35 Don't let a ZNC user connect to itself
If you let your ZNC user to itself, you generate a loop. ZNC will send the
"Welcome to ZNC message" to the connected client, which is itself. So it
receives that messages and sends it to its client again, which...

We detect this situation because we see raw 001 two times, which should never
happen on a normal IRC server. To get even less than zero ;) false positive, we
only disconnect if the second raw 001 is from a server called "irc.znc.in".


git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@1760 726aef4b-f618-498e-8847-2d620e286838
2010-02-18 12:13:22 +00:00

30 KiB