sieve byteconde and RFC6609's :once and :include

Дилян Палаузов dilyan.palauzov at aegee.org
Wed Jul 18 16:58:05 EDT 2012


Hello,

The Sieve Email Filtering: Include Extension is partially implemented in 
cyrus-imapd in the syntax INCLUDE LOCATION(=one of :global or :personal) 
SCRIPTNAME.   RFC6609 adds two more optional parameters to the include 
command :once and :optional, which I am going to store in the generated 
bytecode and consider during execution.

The one option to implement this in the bytecode, is to define a new 
INCLUDE command, rename the current one to INCLUDE_ORIG, and add to the 
the bytecode one more parameter for the command.

The other option is to use some more bits in the location parameter, merely:
   in location & 63 is stored B_GLOBAL or B_LOCAL, as it is now
   in location & 64 is stored :once and
   in location & 128 is stored :optional.

If :once == :optional == 0 = are not specified, the bytecode is the same 
as now, otherwise the location parameter is increased by 64 or 128.

Any preferences for the first approach (storing in sieve bytecode a new 
word for once/optional and creating a new INCLUDE/INCLUDE_ORIG bytecode 
command) or for the second (utilizing the unused bits in the LOCATION 
parameter and not adding a new bytecode for INCLUDE_ORIG).

Do you think, that it is necessary to increase the sieve/bytecode.h's 
BYTECODE_VERSION, provided that on master the version was already 
increased for VACATION :SECONDS and there was no release in the meantime?

Greetngs
   Dilian
-------------- next part --------------
A non-text attachment was scrubbed...
Name: dilyan_palauzov.vcf
Type: text/x-vcard
Size: 380 bytes
Desc: not available
Url : http://lists.andrew.cmu.edu/pipermail/cyrus-devel/attachments/20120718/6c0b4059/attachment.vcf 


More information about the Cyrus-devel mailing list