[exim] Testing for the absence of a header

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Adam Nielsen
Date:  
À: exim-users
Nouveaux-sujets: Re: [exim] Testing for the absence of a header - solution
Sujet: [exim] Testing for the absence of a header
Hi everyone,

I'm a bit confused as to how to test for the absence of an e-mail header
in Exim's .forward file. The docs tell you how to do it in Exim's
configuration file, and then tell you it's possible in the .forward file
too, but the syntax appears to be different so I'm not really sure how
to get it to work.

All I want to do is move mail into a folder if the e-mail is missing the
"X-Spam-Score" header. Moving things into folders works fine, it's just
the condition I'm confused with. If anyone knows how to make this work,
do tell:

  # Exim filter
  if not def:header_x-spam-score: then
    save ".spam.unfiltered/"
  endif


Many thanks,
Adam.