Re: sieve filter move wrong email to Junk folder

2017-12-15 Thread Gao
Thanks for all of your help. Now I modified my sieve script. Three things changes here: 1.   if header :contains "X-Spam-Status" "YES, " { 2.  if header :contains "subject" ["{SPAM?}"] {  ##add the curly brackets 3.  change the order. So send my Mailscanner labeled spam mail directlly to the jun

Re: sieve filter move wrong email to Junk folder

2017-12-15 Thread Olaf Hopp
On 12/15/2017 02:36 PM, Alex JOST wrote: Am 14.12.2017 um 18:47 schrieb Gao: I use a sieve filter to move spam email to user's Junk folder: # cat spam_to_junk.sieve require "fileinto";    if exists "X-Spam-Status" {    if header :contains "X-Spam-Status" "YES" {    fileinto "Junk

Re: sieve filter move wrong email to Junk folder

2017-12-15 Thread Alex JOST
Am 14.12.2017 um 18:47 schrieb Gao: I use a sieve filter to move spam email to user's Junk folder: # cat spam_to_junk.sieve require "fileinto";   if exists "X-Spam-Status" {   if header :contains "X-Spam-Status" "YES" {   fileinto "Junk";   stop;   } else {  

Re: sieve filter move wrong email to Junk folder

2017-12-15 Thread Steffen Kaiser
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Fri, 15 Dec 2017, Bill Shirley wrote: This is what I use.  Notice the comma: require "fileinto"; if header :contains "X-Spam-Status" "Yes," {   fileinto "SystemFolders.SuspectedSpam";   stop; } I would even add the space: if header :contains "

Re: sieve filter move wrong email to Junk folder

2017-12-14 Thread Bill Shirley
Also, I wouldn't use the second rule:     if header :contains "subject" ["SPAM?"] {       fileinto "Junk";       stop;     } If someone sends you an email with the subject "Can you help me with this spam?" it will get filed into Junk. Bill

Re: sieve filter move wrong email to Junk folder

2017-12-14 Thread Bill Shirley
This is what I use.  Notice the comma: require "fileinto"; if header :contains "X-Spam-Status" "Yes," {   fileinto "SystemFolders.SuspectedSpam";   stop; } Bill On 12/14/2017 1:02 PM, Richard wrote: Date: Thursday, December 14, 2017 09:47:44 -0800 From: Gao I use a sieve filter to move spam

Re: sieve filter move wrong email to Junk folder

2017-12-14 Thread Larry Rosenman
This is what I use with Exim, spam.sieve is included in from a master.sieve: thebighonker.lerctr.org /home/ler $ more sieve/spam.sieve require ["fileinto","imap4flags"]; if header :contains ["X-LERCTR-Spam-Flag","X-TNTSCAN-Spam-Flag"] "YES" { redirect "spamt...@spambouncer.org"; fileinto :f

Re: sieve filter move wrong email to Junk folder

2017-12-14 Thread Gao
Well I changed the line to   if header :contains "X-Spam-Status: YES" { Then I got: # sievec spam_to_junk.sieve spam_to_junk: line 3: error: the header test requires 2 positional argument(s), but 1 is/are specified. spam_to_junk: error: validation failed. sievec(root): Fatal: failed to

Re: sieve filter move wrong email to Junk folder

2017-12-14 Thread Gao
thank you for the advice. I'll change it. Gao On 2017-12-14 10:02 AM, Richard wrote: Date: Thursday, December 14, 2017 09:47:44 -0800 From: Gao I use a sieve filter to move spam email to user's Junk folder: # cat spam_to_junk.sieve require "fileinto";   if exists "X-Spam-Status" {  

Re: sieve filter move wrong email to Junk folder

2017-12-14 Thread Richard
> Date: Thursday, December 14, 2017 09:47:44 -0800 > From: Gao > > I use a sieve filter to move spam email to user's Junk folder: ># cat spam_to_junk.sieve > require "fileinto"; >   if exists "X-Spam-Status" { >   if header :contains "X-Spam-Status" "YES" { >   fileinto "Junk"

sieve filter move wrong email to Junk folder

2017-12-14 Thread Gao
I use a sieve filter to move spam email to user's Junk folder: # cat spam_to_junk.sieve require "fileinto";   if exists "X-Spam-Status" {   if header :contains "X-Spam-Status" "YES" {   fileinto "Junk";   stop;   } else {   }   }   if header :contains "subject"