From: Julien Schmidt Date: Mon, 29 May 2017 22:21:33 +0000 (+0800) Subject: [Minor] Do not punish OpenPGP/MIME attachments X-Git-Tag: 1.6.0~97^2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=df802d3790df50bed38a5477f8c8c11f84c0cea0;p=rspamd.git [Minor] Do not punish OpenPGP/MIME attachments Fixes #1655 --- diff --git a/rules/headers_checks.lua b/rules/headers_checks.lua index 585c97b0b..8ee28e40b 100644 --- a/rules/headers_checks.lua +++ b/rules/headers_checks.lua @@ -897,7 +897,10 @@ rspamd_config.CTYPE_MISSING_DISPOSITION = { local cd = p:get_header('Content-Disposition') if (not cd) or (cd and cd:lower():find('^attachment') == nil) then local ci = p:get_header('Content-ID') - if ci then return false end + if ci or (#parts > 1 and (cd and cd:find('filename=.+%.asc') ~= nil)) + then + return false + end return true end end