]> source.dussan.org Git - rspamd.git/commitdiff
[Fix] MISSING_MIMEOLE: avoid matching messages from Android GMail app (#4561) 4600/head
authorAndrew Lewis <nerf@judo.za.org>
Thu, 14 Sep 2023 15:51:49 +0000 (17:51 +0200)
committerAndrew Lewis <nerf@judo.za.org>
Thu, 14 Sep 2023 15:52:36 +0000 (17:52 +0200)
rules/regexp/headers.lua

index b634dd90976e4c44a00222514ca4d59d960d6d34..c4411e53aaec5d269e1cf6e8ae0d68affff80095 100644 (file)
@@ -642,12 +642,14 @@ local has_msmail_pri = 'header_exists(X-MSMail-Priority)'
 local has_mimeole = 'header_exists(X-MimeOLE)'
 local has_squirrelmail_in_mailer = 'X-Mailer=/SquirrelMail\\b/H'
 local has_office_version_in_mailer = [[X-Mailer=/^Microsoft (?:Office )?Outlook [12]\d\.0/]]
+local has_x_android_message_id = 'header_exists(X-Android-Message-Id)'
 reconf['MISSING_MIMEOLE'] = {
-  re = string.format('(%s) & !(%s) & !(%s) & !(%s)',
+  re = string.format('(%s) & !(%s) & !(%s) & !(%s) & !(%s)',
       has_msmail_pri,
       has_mimeole,
       has_squirrelmail_in_mailer,
-      has_office_version_in_mailer),
+      has_office_version_in_mailer,
+      has_x_android_message_id),
   score = 2.0,
   description = 'Mime-OLE is needed but absent (e.g. fake Outlook or fake Exchange)',
   group = 'headers'