View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0006431 | unreal | ircd | public | 2024-07-14 18:13 | 2024-07-14 18:15 |
Reporter | syzop | Assigned To | |||
Priority | normal | Severity | tweak | Reproducibility | always |
Status | new | Resolution | open | ||
Product Version | 6.1.6 | ||||
Summary | 0006431: Underscore and match_simple() | ||||
Description | As 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. | ||||
Tags | No tags attached. | ||||
3rd party modules | |||||
|
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 ;). |