Network Working Group Tim Martin Document: draft-martin-sieve-notify-00.txt Mirapoint Inc. Expires June 9, 2001 4 December 2000 Sieve -- An extension for providing instant notifications Status of this Memo This document is an Internet-Draft and is in full conformance with all provisions of Section 10 of RFC2026. Internet-Drafts are working documents of the Internet Engineering Task Force (IETF), its areas, and its working groups. Note that other groups may also distribute working documents as Internet-Drafts. Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet- Drafts as reference material or to cite them other than as "work in progress." The list of current Internet-Drafts can be accessed at http://www.ietf.org/ietf/1id-abstracts.txt The list of Internet-Draft Shadow Directories can be accessed at http://www.ietf.org/shadow.html. Distribution of this memo is unlimited. Abstract Users go to great lengths to be notified as quickly as possible that they have received new mail. Most of these methods involve polling to check for new messages periodically. A push method handled by the final delivery agent would give users quicker notifications and save server resources. This draft describes an extension to the Sieve mail filtering language that allows users to give specific preferences for notification of Sieve actions. Expires June 9, 2001 Martin [Page 1] Internet Draft Sieve -- Notifications extension December 4, 2000 TTaabbllee ooff CCoonntteennttss Status of this Memo . . . . . . . . . . . . . . . . . . . . . . . . 1 Abstract . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 2. Capability Identifier . . . . . . . . . . . . . . . . . . . . 3 3. Actions . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 3.1. Notify action . . . . . . . . . . . . . . . . . . . . . . . . 3 3.2. Denotify action . . . . . . . . . . . . . . . . . . . . . . . 4 3.3. Default action . . . . . . . . . . . . . . . . . . . . . . . 5 4. Interaction with Other Sieve Actions . . . . . . . . . . . . 5 5. Interaction with Other Sieve Actions . . . . . . . . . . . . 5 6. Security Considerations . . . . . . . . . . . . . . . . . . . 6 7. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 6 8. Copyright . . . . . . . . . . . . . . . . . . . . . . . . . . 6 9. References . . . . . . . . . . . . . . . . . . . . . . . . . 6 10. Author's Address . . . . . . . . . . . . . . . . . . . . . . 7 Expires June 9, 2001 Martin [Page 2] Internet Draft Sieve -- Notifications extension December 4, 2000 1. Introduction This is an extension to the Sieve language defined by [SIEVE] for providing instant notifications of sieve actions that have been preformed. It defines the new action "notify". This document does not dictate the notification method used. The method shall be site-defined. Sieve interpreters for which notifications are impractical or is not possible SHOULD ignore this extension. Conventions for notations are as in [SIEVE] section 1.1, including use of [KEYWORDS]. 2. Capability Identifier The capability string associated with the extension defined in this document is "notify". 3. Actions 3.1. Notify action Syntax: notify [] The Notify action specifies that a notification should be sent to the user upon successful handling of this message. The format of the notification is site-defined. However, all content, including Sieve actions taken on the message, specified in the notify action MUST be included. If errors occurred in another action they SHOULD be reported in the notification. In addition, if the notification method does not provide a timestamp, one SHOULD be appended to the notification. Implementations SHOULD NOT include extraneous information. The "priority" parameter specifies the importance of the notification. The priority parameter shall range from :high (very important) to :medium (moderately important) to :low (not very important). If no priority is giving it shall default to "medium". Expires June 9, 2001 Martin [Page 3] Internet Draft Sieve -- Notifications extension December 4, 2000 Some instant notification methods allow users to specify their state of activity (for example "busy" or "away from keyboard"). If the notification method provides this information it SHOULD be used to selectively send notifications. If for example the user marks herself as "busy" an implentation SHOULD NOT send a notification for a new mailing list message with a priority of :low, however a user should be notified of a high priority action. If the notification method allows users to filter messages based upon certain parameters in the message, users should be able to filter based upon priority. The "message" parameter specifies the message to be included in the notification. The entirety of the string SHOULD be sent but implementations MAY shorten the message for technical or aesthetic reasons. The list of headers specifies which headers the user wishes to be notified of. The header and its contents MUST both be displayed. If this parameter is omitted, the "From", "To", and "Subject" headers shall be displayed by default. If there are errors sending the notification, the Sieve interpreter SHOULD ignore the notification and not retry indefinitely. At maximum, one notification is sent per message. If a message yields multiple notify actions in the processing of a script, the notify action with the highest priority MUST be used. If there are multiple notify actions with the same priority the last one with that priority shall be used. Example: if header :contains "from" "brian_bitono@foo.org" { notify :high "This is probably very important"; } if header :contains "to" "mailinglist@cmu.edu" { notify :low "" "" ["From", "Subject"]; fileinto "INBOX.mailing-list"; } 3.2. Denotify action Syntax: denotify The denotify action specifies that the current notification, if any, shall not be sent. Expires June 9, 2001 Martin [Page 4] Internet Draft Sieve -- Notifications extension December 4, 2000 Example: notify "" "New mail"; if header :contains "from" "mymom@baz.org" { denotify; fileinto "INBOX.junk"; } 3.3. Default action If neither the notify or denotify action is encountered by default a notifications SHOULD be sent. This notification shall be equivalent to a notify action with a priority of medium and the default headers specified. The message shall be site defined. 4. Interaction with Other Sieve Actions Notifications MUST be sent no matter what the message actions might be. Users may wish to know when messages are being discarded or rejected. 5. Interaction with Other Sieve Actions The following syntax specification uses the augmented Backus-Naur Form (BNF) notation as specified in [ABNF]. This uses the ABNF core rules as specified in Appendix A of the ABNF specification [ABNF]. capability =/ notify action =/ notify / denotify priority = :low / :medium / :high / notify = "notify" WSP priority WSP string WSP string-list ;; denotify = "denotify" Expires June 9, 2001 Martin [Page 5] Internet Draft Sieve -- Notifications extension December 4, 2000 6. Security Considerations Security considerations are discussed in [SIEVE]. Additionally implementations must be careful to follow the security considerations of the specific notification methods. It is believed that this extension does not introduce any additional security concerns. 7. Acknowledgments Thanks to Larry Greenfield and Sarah Robeson for help with this document. 8. Copyright Copyright (C) The Internet Society 1999. All Rights Reserved. This document and translations of it may be copied and furnished to others, and derivative works that comment on or otherwise explain it or assist in its implementation may be prepared, copied, published and distributed, in whole or in part, without restriction of any kind, provided that the above copyright notice and this paragraph are included on all such copies and derivative works. However, this document itself may not be modified in any way, such as by removing the copyright notice or references to the Internet Society or other Internet organizations, except as needed for the purpose of developing Internet standards in which case the procedures for copyrights defined in the Internet Standards process must be followed, or as required to translate it into languages other than English. The limited permissions granted above are perpetual and will not be revoked by the Internet Society or its successors or assigns. This document and the information contained herein is provided on an "AS IS" basis and THE INTERNET SOCIETY AND THE INTERNET ENGINEERING TASK FORCE DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 9. References 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 [KEYWORDS]. Expires June 9, 2001 Martin [Page 6] Internet Draft Sieve -- Notifications extension December 4, 2000 [ABNF] Crocker, Overell, "Augmented BNF for Syntax Specifications: ABNF", RFC 2234, Internet Mail Consortium, Demon Internet Ltd, November 1997. [SIEVE] Showalter, T, "Sieve -- a Mail Filtering Language", draft- showalter-sieve-09.txt, Mirapoint, September 1999. 10. Author's Address Tim Martin Mirapoint Inc. 909 Hermosa Court Sunnyvale, CA 94085 Phone: (408) 720-3835 EMail: tmartin@mirapoint.com Expires June 9, 2001 Martin [Page 7]