datatracker.ietf.org
Sign in
Version 5.3.0, 2014-04-12
Report a bug

Sieve Email Filtering: Relational Extension
RFC 5231

Document type: RFC - Proposed Standard (January 2008)
Obsoletes RFC 3431
Document stream: IETF
Last updated: 2013-03-02
Other versions: plain text, pdf, html

IETF State: (None)
Consensus: Unknown
Document shepherd: No shepherd assigned

IESG State: RFC 5231 (Proposed Standard)
Responsible AD: Scott Hollenbeck
Send notices to: cyrus@daboo.name, alexey.melnikov@isode.com

Network Working Group                                       W. Segmuller
Request for Comments: 5231                                      B. Leiba
Obsoletes: 3431                          IBM T.J. Watson Research Center
Category: Standards Track                                   January 2008

              Sieve Email Filtering: Relational Extension

Status of This Memo

   This document specifies an Internet standards track protocol for the
   Internet community, and requests discussion and suggestions for
   improvements.  Please refer to the current edition of the "Internet
   Official Protocol Standards" (STD 1) for the standardization state
   and status of this protocol.  Distribution of this memo is unlimited.

Abstract

   This document describes the RELATIONAL extension to the Sieve mail
   filtering language defined in RFC 3028.  This extension extends
   existing conditional tests in Sieve to allow relational operators.
   In addition to testing their content, it also allows for testing of
   the number of entities in header and envelope fields.

   This document obsoletes RFC 3431.

Table of Contents

   1.  Introduction  . . . . . . . . . . . . . . . . . . . . . . . . . 2
   2.  Conventions Used in This Document . . . . . . . . . . . . . . . 2
   3.  Comparators . . . . . . . . . . . . . . . . . . . . . . . . . . 2
   4.  Match Types . . . . . . . . . . . . . . . . . . . . . . . . . . 3
     4.1.  Match Type VALUE  . . . . . . . . . . . . . . . . . . . . . 3
     4.2.  Match Type COUNT  . . . . . . . . . . . . . . . . . . . . . 3
   5.  Interaction with Other Sieve Actions  . . . . . . . . . . . . . 4
   6.  Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
   7.  Extended Example  . . . . . . . . . . . . . . . . . . . . . . . 6
   8.  Changes since RFC 3431  . . . . . . . . . . . . . . . . . . . . 6
   9.  IANA Considerations . . . . . . . . . . . . . . . . . . . . . . 7
   10. Security Considerations . . . . . . . . . . . . . . . . . . . . 7
   11. Normative References  . . . . . . . . . . . . . . . . . . . . . 7

Segmuller & Leiba           Standards Track                     [Page 1]
RFC 5231              Sieve: Relational Extension           January 2008

1.  Introduction

   The RELATIONAL extension to the Sieve mail filtering language [Sieve]
   provides relational operators on the address, envelope, and header
   tests.  This extension also provides a way of counting the entities
   in a message header or address field.

   With this extension, the Sieve script may now determine if a field is
   greater than or less than a value instead of just equivalent.  One
   use is for the x-priority field: move messages with a priority
   greater than 3 to the "work on later" folder.  Mail could also be
   sorted by the from address.  Those userids that start with 'a'-'m' go
   to one folder, and the rest go to another folder.

   The Sieve script can also determine the number of fields in the
   header, or the number of addresses in a recipient field, for example,
   whether there are more than 5 addresses in the to and cc fields.

   The capability string associated with the extension defined in this
   document is "relational".

2.  Conventions Used in This Document

   The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
   "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
   document are to be interpreted as described in BCP 14, RFC 2119.

   Conventions for notations are as in [Sieve] section 1.1, including
   the use of [Kwds] and the use of [ABNF].

3.  Comparators

   This document does not define any comparators or exempt any
   comparators from the require clause.  Any comparator used must be
   treated as defined in [Sieve].

   The "i;ascii-numeric" comparator, as defined in [RFC4790], MUST be
   supported for any implementation of this extension.  The comparator
   "i;ascii-numeric" MUST support at least 32-bit unsigned integers.

   Larger integers MAY be supported.  Note: the "i;ascii-numeric"
   comparator does not support negative numbers.

Segmuller & Leiba           Standards Track                     [Page 2]
RFC 5231              Sieve: Relational Extension           January 2008

4.  Match Types

   This document defines two new match types.  They are the VALUE match
   type and the COUNT match type.

   The syntax is:

   MATCH-TYPE =/ COUNT / VALUE

   COUNT = ":count" relational-match

   VALUE = ":value" relational-match

   relational-match = DQUOTE

[include full document text]