> oh! if you run the Sieve script in batch, long after the
> delivery was made, the current date is completely useless.
> SETDATE should be changed to initialise the variables to the
> time of delivery, not current time.
Um, no, it may well be that it is the value in the Date: field
that is completely useless. It is all a question of what you're
trying to achieve. [...]
all right, the original idea for adding SETDATE was to use it with
FILEINTO so that you could make archives "dynamically". also, Sieve
is typically used by the delivery agent. the case where a Sieve
client uses IMAP or similar to access the message store after delivery
has taken place, is an edge case. furthermore, the spec says
In this case using the Date: field would be an exceedingly bad idea. You don't
want to let people add stuff to old archives simply by setting the Date: field
to a value in the past.
IMO the ideal value to use here is "date of insertion into the archive". The
current date is a reasonable thing to use for that. The Date: field is not.
| These variables SHOULD reference the time when execution of the
| Sieve script reaches the statement.
so such a client is allowed to use Received headers or whatever it
likes to find the date the user wants for SETDATE. still, the intent
is that it references the time of delivery. for the typical use, the
MDA, it doesn't make any difference. for the standalone MFA (mail
filtering agent), it does make a difference, and I think we should be
explicit about what we want the MFA to do.
I think it should refer to the time the filtering action was taken,
regardless of whether that was in the context of delivery or later filtering.