summaryrefslogtreecommitdiffstats
path: root/rules
diff options
context:
space:
mode:
authorDmitriy Alekseev <1865999+dragoangel@users.noreply.github.com>2023-07-12 13:23:33 +0300
committerGitHub <noreply@github.com>2023-07-12 13:23:33 +0300
commit7ff31bdb955abffa37f21782b9a01ccd1acca155 (patch)
tree5955e3dc3d0ba6ce03fa9639bf1ce513b463c417 /rules
parent0729c58cb03befdb31b7a1ca56bd052abfd66477 (diff)
downloadrspamd-7ff31bdb955abffa37f21782b9a01ccd1acca155.tar.gz
rspamd-7ff31bdb955abffa37f21782b9a01ccd1acca155.zip
Optimize apple_ios_x_mailer regex
Diffstat (limited to 'rules')
-rw-r--r--rules/regexp/headers.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/rules/regexp/headers.lua b/rules/regexp/headers.lua
index d6b8b3a08..85d6cfcfd 100644
--- a/rules/regexp/headers.lua
+++ b/rules/regexp/headers.lua
@@ -975,7 +975,7 @@ reconf['APPLE_MAILER'] = {
-- Detect Apple iPhone/iPad Mail
-- Apple iPhone/iPad Mail X-Mailer contains iOS build number, e. g. 9B206, 16H5, 18G5023c
-- https://en.wikipedia.org/wiki/IOS_version_history
-local apple_ios_x_mailer = [[i(?:Phone|Pad) Mail \((?:1[AC]|[34][AB]|5[ABCFGH]|7[A-E]|8[ABCEFGHJKL]|9[AB]|\d{2}[A-Z])\d+[a-z]?\)]]
+local apple_ios_x_mailer = [[i(?:Phone|Pad) Mail \(\d{1,2}[A-Z]\d{1,4}[a-z]?\)]]
reconf['APPLE_IOS_MAILER'] = {
description = 'Sent with Apple iPhone/iPad Mail',
re = string.format('X-Mailer=/^%s/{header}', apple_ios_x_mailer),