[exim] sieve filter regex extension

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Rogge, Ulrike (IPD)
Date:  
À: exim-users
Sujet: [exim] sieve filter regex extension
Hi all,

we have an courier-mailserver with exim and the webmailer horde. We want
to use horde Ingo to enable the users to use filters. Since Courier is
not able to filter sieve scripts, we want to use exim for doing that.
When activating the vacation-filter it writes the following script

   1: # Sieve Filter
      2: # Generated by Ingo (http://www.horde.org/apps/ingo/) (12/23/2013, 10:07:17 AM)
      3: require ["vacation", "regex"];
      4: # Vacation
      5: if allof ( not exists ["list-help", "list-unsubscribe", "list-subscribe", "list-owner", "list-post", "list-archive", "list-id", "Mailing-List"], not header :comparator "i;ascii-casemap" :is "Precedence" ["list", "bulk", "junk"], not header :comparator "i;ascii-casemap" :matches "To" "Multiple recipients of*" ) {
      6:     if header :regex "Received" "^.*(2013) (\\(.*\\) )?..:..:.. (\\(.*\\) )?((\\+|\\-)[[:digit:]]{4}|.{1,5})( \\(.*\\))?$" {
      7:     if header :regex "Received" "^.*(Dec) (\\(.*\\) )?.... (\\(.*\\) )?..:..:.. (\\(.*\\) )?((\\+|\\-)[[:digit:]]{4}|.{1,5})( \\(.*\\))?$" {
      8:     if header :regex "Received" "^.*(15|16|17|18|19|20|21|22|23|24|25|26|27|28|29|30|31) (\\(.*\\) )?... (\\(.*\\) )?.... (\\(.*\\) )?..:..:.. (\\(.*\\) )?((\\+|\\-)[[:digit:]]{4}|.{1,5})( \\(.*\\))?$" {
      9:     vacation :days 7 :addresses "rogge@???" :subject "test" "test";
     10: }
     11: }
     12: }
     13: if header :regex "Received" "^.*(2014) (\\(.*\\) )?..:..:.. (\\(.*\\) )?((\\+|\\-)[[:digit:]]{4}|.{1,5})( \\(.*\\))?$" {
     14:     if header :regex "Received" "^.*(Jan) (\\(.*\\) )?.... (\\(.*\\) )?..:..:.. (\\(.*\\) )?((\\+|\\-)[[:digit:]]{4}|.{1,5})( \\(.*\\))?$" {
     15:     if header :regex "Received" "^.*([0 ]1) (\\(.*\\) )?... (\\(.*\\) )?.... (\\(.*\\) )?..:..:.. (\\(.*\\) )?((\\+|\\-)[[:digit:]]{4}|.{1,5})( \\(.*\\))?$" {
     16:     vacation :days 7 :addresses "rogge@???" :subject "test" "test";
     17: }
     18: }
     19: }
     20: }


When I test it, I get the following error-message:

   Return-path copied from sender
   Sender      = rogge@???
   Recipient   = rogge@???
   Testing Sieve filter file ".sieve"


Sieve error: unknown capability in line 3

It seems to be the extension "regex". In the exim-documentation "Chapter
2 - Sieve filter" I found the following sentence:

"The Exim Sieve implementation offers the core as defined by RFC 3028,
comparison tests, the subaddress parameter, the copy, envelope,
fileinto, notify, and vacation extensions, but not the reject extension."

The list doesn't include "regex", so is it true, that it won't work? Is
there a way to make it work? Or what else can we do?


Thanks and a merry christmas for you all
Ulrike