Skip to content
Snippets Groups Projects
Commit d0d54151 authored by Marius Burkard's avatar Marius Burkard
Browse files

Merge branch '6051-trigger-junk-move-by-subject-line-impacts-forwarded-emails' into 'develop'

Resolve "Trigger junk move by Subject line impacts forwarded emails"

Closes #6051

See merge request ispconfig/ispconfig3!1409
parents 509a4aa0 1157b9b2
No related branches found
No related tags found
No related merge requests found
use = ["x-spamd-bar", "x-spam-level", "authentication-results"]; use = ["x-spamd-bar", "x-spam-level", "x-spam-status", "authentication-results"];
authenticated_headers = ["authentication-results"]; authenticated_headers = ["authentication-results"];
\ No newline at end of file routines {
remove-headers {
"X-Spam" = 0;
"X-Spamd-Bar" = 0;
"X-Spam-Level" = 0;
"X-Spam-Status" = 0;
}
}
...@@ -4,7 +4,7 @@ if ($RETURNCODE==1) ...@@ -4,7 +4,7 @@ if ($RETURNCODE==1)
{ {
if (!/^List-Unsubscribe:.*/:h ) if (!/^List-Unsubscribe:.*/:h )
{ {
if (!/^(X-Spam-Flag: YES|X-Spam: Yes|Subject: \*\*\*\s*SPAM\s*\*\*\*.*)/:h ) if (!/^(X-Spam-Flag: YES|X-Spam: Yes|X-Spam-Status: Yes)/:h )
{ {
NOW=time NOW=time
if ({start_date} lt $NOW && {end_date} gt $NOW) if ({start_date} lt $NOW && {end_date} gt $NOW)
...@@ -20,4 +20,4 @@ if ($RETURNCODE==1) ...@@ -20,4 +20,4 @@ if ($RETURNCODE==1)
} }
} }
} }
} }
\ No newline at end of file
...@@ -7,7 +7,7 @@ require ["fileinto", "mailbox", "regex", "date", "relational", "vacation", "imap ...@@ -7,7 +7,7 @@ require ["fileinto", "mailbox", "regex", "date", "relational", "vacation", "imap
<tmpl_if name="move_junk" op="==" value="y"> <tmpl_if name="move_junk" op="==" value="y">
# Move spam to spam folder # Move spam to spam folder
if anyof (header :contains "X-Spam-Flag" "YES", header :contains "X-Spam" "Yes", header :contains "subject" "*** SPAM ***", header :contains "subject" "***SPAM***") { if anyof (header :contains "X-Spam-Flag" "YES", header :contains ["X-Spam", "X-Spam-Status"] "Yes") {
fileinto :create "Junk"; fileinto :create "Junk";
# Stop here so that we do not reply on spams # Stop here so that we do not reply on spams
stop; stop;
...@@ -33,7 +33,7 @@ require ["fileinto", "mailbox", "regex", "date", "relational", "vacation", "imap ...@@ -33,7 +33,7 @@ require ["fileinto", "mailbox", "regex", "date", "relational", "vacation", "imap
<tmpl_if name="move_junk" op="==" value="a"> <tmpl_if name="move_junk" op="==" value="a">
# Move spam to spam folder # Move spam to spam folder
if anyof (header :contains "X-Spam-Flag" "YES", header :contains "X-Spam" "Yes", header :contains "subject" "*** SPAM ***", header :contains "subject" "***SPAM***") { if anyof (header :contains "X-Spam-Flag" "YES", header :contains ["X-Spam", "X-Spam-Status"] "Yes") {
fileinto :create "Junk"; fileinto :create "Junk";
# Stop here so that we do not reply on spams # Stop here so that we do not reply on spams
stop; stop;
...@@ -46,7 +46,7 @@ if anyof (header :contains "X-Spam-Flag" "YES", header :contains "X-Spam" "Yes", ...@@ -46,7 +46,7 @@ if anyof (header :contains "X-Spam-Flag" "YES", header :contains "X-Spam" "Yes",
################################################################# #################################################################
# Move spam to spam folder # Move spam to spam folder
if anyof (header :contains "X-Spam-Flag" "YES", header :contains "X-Spam" "Yes", header :contains "subject" "*** SPAM ***", header :contains "subject" "***SPAM***") { if anyof (header :contains "X-Spam-Flag" "YES", header :contains ["X-Spam", "X-Spam-Status"] "Yes") {
# Stop here so that we do not reply on spams # Stop here so that we do not reply on spams
stop; stop;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment