-$Cambridge: exim/doc/doc-txt/ChangeLog,v 1.256 2005/11/14 11:32:16 ph10 Exp $
+$Cambridge: exim/doc/doc-txt/ChangeLog,v 1.257 2005/11/14 11:41:23 ph10 Exp $
Change log file for Exim from version 4.21
-------------------------------------------
even if body_only or headers_only was set. It now gives an appropriate
message.
+PH/09 Applied a patch from the Sieve maintainer which:
+
+ o fixes some comments
+ o adds the (disabled) notify extension core
+ o adds some debug output for the result of if/elsif tests
+ o points to the current vacation draft in the documentation
+ and documents the missing references header update
+
+ and most important:
+
+ o fixes a bug in processing the envelope test (when testing
+ multiple envelope elements, the last element determinted the
+ result)
+
Exim version 4.54
-----------------
-$Cambridge: exim/doc/doc-txt/README.SIEVE,v 1.7 2005/08/30 10:55:52 ph10 Exp $
+$Cambridge: exim/doc/doc-txt/README.SIEVE,v 1.8 2005/11/14 11:41:23 ph10 Exp $
Notes on the Sieve implementation for Exim
The Exim Sieve implementation offers the core as defined by draft
3028bis-4 (next version of RFC 3028 that fixes specification mistakes),
the "envelope" (3028bis), the "fileinto" (3028bis), the "copy" (RFC 3894)
-and the "vacation" (draft-ietf-sieve-vacation-02.txt) extension, the
+and the "vacation" (draft-ietf-sieve-vacation-04.txt) extension, the
"i;ascii-numeric" comparator (RFC 2244).
The Sieve filter is integrated in Exim and works very similar to the
This may be implemented in future by adding a header line to mails that
are filed into "inbox" due to an error in the filter.
+The automatic replies generated by "vacation" do not contain an updated
+"references" header field.
+
Semantics Of Keep
-/* $Cambridge: exim/src/src/sieve.c,v 1.13 2005/08/30 10:55:52 ph10 Exp $ */
+/* $Cambridge: exim/src/src/sieve.c,v 1.14 2005/11/14 11:41:23 ph10 Exp $ */
/*************************************************
* Exim - an Internet mail transport agent *
/* Undefine it for UNIX-style \n end-of-line terminators (default). */
#undef RFC_EOL
-/* Define this for development of the subaddress Sieve extension. */
+/* Define this for development of the Sieve extension "notify". */
+#undef NOTIFY
+
+/* Define this for the Sieve extension "subaddress". */
#define SUBADDRESS
-/* Define this for the vacation Sieve extension. */
+/* Define this for the Sieve extension "vacation". */
#define VACATION
/* Must be >= 1 */
int keep;
int require_envelope;
int require_fileinto;
+#ifdef NOTIFY
+ int require_notify;
+#endif
#ifdef SUBADDRESS
int require_subaddress;
#endif
static const struct String str_fileinto={ str_fileinto_c, 8 };
static uschar str_envelope_c[]="envelope";
static const struct String str_envelope={ str_envelope_c, 8 };
+#ifdef NOTIFY
+static uschar str_notify_c[]="notify";
+static const struct String str_notify={ str_notify_c, 6 };
+#endif
#ifdef SUBADDRESS
static uschar str_subaddress_c[]="subaddress";
static const struct String str_subaddress={ str_subaddress_c, 10 };
return -1;
}
*cond=0;
- for (e=env; e->character; ++e)
+ for (e=env; e->length!=-1 && !*cond; ++e)
{
const uschar *envelopeExpr=CUS 0;
uschar *envelope=US 0;
filter->errmsg=CUS "missing test";
return -1;
}
+ if ((filter_test != FTEST_NONE && debug_selector != 0) ||
+ (debug_selector & D_filter) != 0)
+ {
+ if (exec) debug_printf("if %s\n",cond?"true":"false");
+ }
m=parse_block(filter,exec ? cond : 0, generated);
if (m==-1 || m==2) return m;
if (m==0)
filter->errmsg=CUS "missing test";
return -1;
}
+ if ((filter_test != FTEST_NONE && debug_selector != 0) ||
+ (debug_selector & D_filter) != 0)
+ {
+ if (exec) debug_printf("elsif %s\n",cond?"true":"false");
+ }
m=parse_block(filter,exec && unsuccessful ? cond : 0, generated);
if (m==-1 || m==2) return m;
if (m==0)
fileinto-command = "fileinto" { fileinto-options } string ";"
fileinto-options =
fileinto-options =) [ ":copy" ]
- */
+ */
struct String folder;
uschar *s;
}
if (parse_semicolon(filter)==-1) return -1;
}
+#ifdef NOTIFY
+ else if (parse_identifier(filter,CUS "notify"))
+ {
+ /*
+ notify-command = "notify" { notify-options } ";"
+ notify-options = [":method" string]
+ [":message" string]
+ */
+
+ int m;
+ struct String method;
+ struct String message;
+
+ if (!filter->require_notify)
+ {
+ filter->errmsg=CUS "missing previous require \"notify\";";
+ return -1;
+ }
+ method.character=(uschar*)0;
+ method.length=-1;
+ message.character=(uschar*)0;
+ message.length=-1;
+ for (;;)
+ {
+ if (parse_white(filter)==-1) return -1;
+ if (parse_identifier(filter,CUS ":method")==1)
+ {
+ if (parse_white(filter)==-1) return -1;
+ if ((m=parse_string(filter,&method))!=1)
+ {
+ if (m==0) filter->errmsg=CUS "method string expected";
+ return -1;
+ }
+ }
+ else if (parse_identifier(filter,CUS ":message")==1)
+ {
+ if (parse_white(filter)==-1) return -1;
+ if ((m=parse_string(filter,&message))!=1)
+ {
+ if (m==0) filter->errmsg=CUS "message string expected";
+ return -1;
+ }
+ }
+ else break;
+ }
+ if (parse_semicolon(filter)==-1) return -1;
+ }
+#endif
#ifdef VACATION
else if (parse_identifier(filter,CUS "vacation"))
{
filter->keep=1;
filter->require_envelope=0;
filter->require_fileinto=0;
+#ifdef NOTIFY
+filter->require_notify=0;
+#endif
#ifdef SUBADDRESS
filter->require_subaddress=0;
#endif
{
if (eq_octet(check,&str_envelope,0)) filter->require_envelope=1;
else if (eq_octet(check,&str_fileinto,0)) filter->require_fileinto=1;
+#ifdef NOTIFY
+ else if (eq_octet(check,&str_notify,0)) filter->require_notify=1;
+#endif
#ifdef SUBADDRESS
else if (eq_octet(check,&str_subaddress,0)) filter->require_subaddress=1;
#endif