summaryrefslogtreecommitdiffstats
path: root/rules
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2016-01-22 17:26:23 +0000
committerVsevolod Stakhov <vsevolod@highsecure.ru>2016-01-22 17:26:23 +0000
commitf9cdbed9ded932d7e54aef4b4936d70c84646f1f (patch)
tree6ae2ffff82a0ce4f91d625f76fd9b3887975ac15 /rules
parentdce90e99c7f42de3991824fb2a7a856159088f68 (diff)
downloadrspamd-f9cdbed9ded932d7e54aef4b4936d70c84646f1f.tar.gz
rspamd-f9cdbed9ded932d7e54aef4b4936d70c84646f1f.zip
Add `BROKEN_HEADERS` rule
Diffstat (limited to 'rules')
-rw-r--r--rules/misc.lua13
1 files changed, 13 insertions, 0 deletions
diff --git a/rules/misc.lua b/rules/misc.lua
index 256255145..8d801809c 100644
--- a/rules/misc.lua
+++ b/rules/misc.lua
@@ -133,3 +133,16 @@ rspamd_config.SUBJ_ALL_CAPS = {
group = 'headers',
description = 'All capital letters in subject'
}
+
+rspamd_config.BROKEN_HEADERS = {
+ callback = function(task)
+ if task:has_flag('broken_headers') then
+ return true
+ end
+
+ return false
+ end,
+ score = 1.0,
+ group = 'headers',
+ description = 'Headers structure is likely broken'
+} \ No newline at end of file