[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Old ban matches new ban check



(Note: sending to ircd-users, as this should remain non technical)

On May 30, Van Moolenbroek wrote:
| A check in the IRC Server function add_banid, which tests if a new ban
| for a channel is matching with an old ban on that channel, also checks
| if an old ban is matching the new ban. The following two commands will
| not work correctly because of this:
| 
| 1) /MODE #ChannelName +b *!*@*.test.ban
| 2) /MODE #ChannelName +b *!*@*.ban
| 
| The first ban is normally set, but the second will not be set because
| the first one is matching the second. Though, not all users who match
| the second ban, match the first one as well! It wouldn't be very
| practical if clients have to unban the first ban before setting the
| second, because that would force clients to keep up the actual ban list
| of channels they are on. Even the Windows client mIRC doesn't do that!

right, but anybody matching the 1st ban matches the second.
(effectively making the first ban useless)

|   Because of this, I think that the check should be removed. The
| location of the check is ircd/channel.c, function add_banid, lines
| 176/177 (ircd version 2.9.5):
| 
| (176)                           !match(ban->value.cp,banid) ||
| (177)                           !match(banid,ban->value.cp)))
| 
| The check if new ban *!*@*.test.ban is matching old ban *!*@*.ban is
| okay, but the check if old ban *!*@*.test.ban is matching new ban
| *!*@*.ban has to be removed, imho. It is quite annoying, and I hope
| that it will be fixed in the next IRC server version(s).

My guess is that this feature was added to limit the number
of redundant bans set, saving a notable amount of bandwidth.
(you should have seen some channels like #spanish 5 years
ago).

I personnally always hated this feature, but understand it
and don't plan to modify it.  However, I'd be glad to hear
what others have to say on the topic.

As a last note, the current alpha version has a new feature
which should make you a little happier: when a ban is
rejected for the reason you mentionned above, the
conflicting ban is automatically sent to the client.