View Issue Details

IDProjectCategoryView StatusLast Update
0006431unrealircdpublic2024-07-14 18:15
Reportersyzop Assigned To 
PrioritynormalSeveritytweakReproducibilityalways
Status newResolutionopen 
Product Version6.1.6 
Summary0006431: Underscore and match_simple()
DescriptionAs mentioned in https://forums.unrealircd.org/viewtopic.php?t=9370 the match_simple() function (and thus in spamfilter type simple too) seems to treat underscore as meaning: underscore or space.

It was intentional for things like +b ~realname:*some_bad_person* where it would match "Some bad person" and I think it was only meant to be like that in match_esc() but I'm not entirely sure. This was done 15+ years ago and the behavior has been like that since then.

match_simple() is called from 110+ places (and even more indirect), so.. needs some careful consideration if we want to change that back to _ meaning really _.

I don't want to do this post-rc1 of 6.1.7 and.. yeah.. to be honest not sure if i will change this in 6.1.8 either either, but it is good to have this issue filed to look at it some day.
TagsNo tags attached.
3rd party modules

Activities

syzop

2024-07-14 18:15

administrator   ~0023261

Changing this would for example affect +b ~text:block:*some_nice_phrase* where it matches "some nice phrase" (and "some_nice_phrase" too). But since the underscore stuff is not documented in that context, I doubt anyone uses it, so then it would be safe to change. Also for ~text:replace: it calls a different (dedicated) routine, where _ really is _, so it would be rather odd for them to have different meaning depending on whether the action is block or block ;).

Issue History

Date Modified Username Field Change
2024-07-14 18:13 syzop New Issue
2024-07-14 18:15 syzop Note Added: 0023261