]> source.dussan.org Git - rspamd.git/commitdiff
Add new header rules
authorSteve Freegard <steve@stevefreegard.com>
Mon, 19 Mar 2018 12:03:27 +0000 (12:03 +0000)
committerSteve Freegard <steve@stevefreegard.com>
Mon, 19 Mar 2018 12:03:27 +0000 (12:03 +0000)
rules/regexp/headers.lua

index 2570e9f75ae60112d57eaeb88fca1e1a4610589c..64a416c9ad6799105e4a3b5985c149f626a07fee 100644 (file)
@@ -923,3 +923,36 @@ reconf['HAS_XOIP'] = {
   score = 0.0,
   group = 'headers'
 }
+
+reconf['HAS_LIST_UNSUB'] = {
+  re = string.format('%s', 'header_exists(List-Unsubscribe)'),
+  description = 'Has List-Unsubscribe header',
+  score = -0.01,
+  group = 'headers'
+}
+
+reconf['HAS_GUC_PROXY_URI'] = {
+   re = '/\\.googleusercontent\\.com\\/proxy/{raw_mime}i',
+   description = 'Has googleusercontent.com proxy URI',
+   score = 0.01,
+   group = 'experimental'
+}
+
+reconf['HAS_GOOGLE_REDIR'] = {
+  re = '/\\.google\\.com\\/url\\?/{raw_mime}i',
+  description = 'Has google.com/url redirection',
+  score = 0.01,
+  group = 'experimental'
+}
+
+reconf['XM_UA_NO_VERSION'] = {
+  re = string.format('(!%s && !%s) && (%s || %s)',
+                     'X-Mailer=/https?:/H',
+                     'User-Agent=/https?:/H',
+                     'X-Mailer=/^[^0-9]+$/H',
+                     'User-Agent=/^[^0-9]+$/H'),
+  description = 'X-Mailer/User-Agent has no version',
+  score = 0.01,
+  group = 'experimental'
+}
+