On Thu, 20 May 2021 18:34:54 +0200 Bert Van de Poel wrote: > We've started getting lots of spam with emoji in the subject too the > past few weeks, so I've looked into this as well. As mentioned by RW, > you would need to create some kind of UTF8 regex header Subject rule. > As I'm not too excited about writing such a regex, it's way at the > bottom of my todo list to contemplate whether an SA plugin could be > written for that and to then reach out to the SA developers to see > whether that would be something upstream would accept. But honestly, > I won't be able to any time soon (I don't have the time). Still, > thought I'd mention it, since it might be relevant to your question. > If you do end up figuring out a regex that works out and isn't an > extreme length, I think plenty of people on this list would love to > know!
Try this: header EMOTICON_IN_SUBJECT Subject =~ /\xF0\x9F(?:\x98[\x80-\xFF]|\x99[\x00-x8F])/