Internet Draft: SIEVE Statistics Madan Ganesh Velayudham Hewlett-Packard Company Expires: July 14, 2004 February 14, 2004 SIEVE Statistics draft-madanganeshv-sieve-stat-01.txt 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 The list of Internet-Draft Shadow Directories can be accessed at . Copyright Notice Copyright (C) The Internet Society (2003). All Rights Reserved. Abstract This draft describes a mechanism of collecting the statistical information about sieve action on the received mail. It introduces GETSTAT and RESETSTAT commands to [MSIEVE] to get and reset the statistic information about the sieve actions. 1. Introduction Currently manage sieve [MSIEVE] does not have a mechanism by which an user can know how many mails are rejected, discarded or a particular action performed. This draft describes a mechanism of collecting the action counters and a way of getting and clearing the statistics. 2. Conventions Used in this Document The key words "REQUIRED", "MUST", "MUST NOT", "SHOULD", "SHOULD NOT", and "MAY" in this document are to be interpreted as described in "Key words for use in RFCs to Indicate Requirement Levels" [KEYWORDS]. Expires July 14, 2004 Madan [Page 1] Internet-Draft SIEVE Statistics February 14, 2004 In protocol examples, "C:" designates lines sent by the client, while "S:" show lines sent by the server. In such examples, line breaks are for editorial clarity only. 3. Requirement The requirement is to allow an user to get the statistical information about sieve's action on their mails. 4. Updation of action counters Sieve [SIEVE] implementation SHOULD maintain a counter for each of the supported action for each user. When a particular action is completed successfully on the received mail, sieve [SIEVE] implementation MUST increment the corresponding action counter. When updating the the action counters, sieve [SIEVE] implementation MUST make sure that the existing action counters are in consistent state. Action counters for sieve [SIEVE] actions reject, redirect and discard MUST be supported by the sieve [MSIEVE] implementation which support GETSTAT and RESETSTAT commands. 5. CAPABILITY Identification Manage Sieve [MSIEVE] implementation that support these commands MUST include STATISTICS response in the response list to the CAPABILITY command. This entry indicates that the manage sieve [MSIEVE] implementation supports these commands. S: "STATISTICS" 6. GETSTAT Command The GETSTAT command retrieves the supported action counters for the particular user. This command MUST be given after the client is authenticated. Example: C: GETSTAT S: "discard" 5 S: "divert" 2 S: "reject" 8 S: OK Server implementations should include action counters even if they are zero. 7. RESETSTAT Command The RESETSTAT command initializes the supported action counters to zero. RESETSTAT implementation MUST make sure this operation is atomic. That is, server should initialize all the counters or none. This command MUST be given after the client is authenticated. Expires July 14, 2004 Madan [Page 2] Internet-Draft SIEVE Statistics February 14, 2004 Example: C: RESETSTAT S: OK 8. Formal Syntax 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]. command-getstat = "GETSTAT" CRLF command-resetstat = "RESETSTAT" CRLF getstat-resp-list = [ supported-action integer-value CRLF ] * getstat-resp-list supported-action = "discard" / "divert" / "reject" command-getstat-resp = getstat-resp-list CRLF command-resetstat-resp = "OK" | "NO" CRLF 9. Security Considerations It is believed that this draft does not introduce any security issues. 10. Acknowledgements This draft acknowledges the comments provided by Lyndon Nerenberg and Nigel Swinson. 11. Future works To write MIB definitions for Sieve actions and scripts. 12. Change History o Changed response to CAPABILITY from GETSTAT, RESETSTAT to STATISTICS o Corrected Zero valued action counters definition o Included formal syntax for command's response o Corrected Security consideration Appendices A. References The following documents contain definitions or specifications that are necessary to understand this document properly: [ABNF] Crocker, D. and P. Overell, "Augmented BNF for Syntax Specifications: ABNF", RFC 2234, November 1997. Expires July 14, 2004 Madan [Page 3] Internet-Draft SIEVE Statistics February 14, 2004 [KEYWORDS] Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, March 1997. [SIEVE] Showalter, T.; "Sieve: A Mail Filtering Language"; RFC 3028; Mirapoint, Inc.; January 2001 [MSIEVE] Tim Martin; "A Protocol for Remotely Managing Sieve Scripts" WORK IN PROGRESS Author's Address Madan Ganesh Velayudham Hewlett-Packard, 29, Cunningham road, Bangalore, India 560052 madan-ganesh.v@hp.com +91-80-2205-3108 Intellectual Property Statement The IETF takes no position regarding the validity or scope of any intellectual property or other rights that might be claimed to pertain to the implementation or use of the technology described in this document or the extent to which any license under such rights might or might not be available; neither does it represent that it has made any effort to identify any such rights. Information on the IETF's procedures with respect to rights in standards-track and standards-related documentation can be found in BCP-11. Copies of claims of rights made available for publication and any assurances of licenses to be made available, or the result of an attempt made to obtain a general license or permission for the use of such proprietary rights by implementers or users of this specification can be obtained from the IETF Secretariat. The IETF invites any interested party to bring to its attention any copyrights, patents or patent applications, or other proprietary rights which may cover technology that may be required to practice this standard. Please address the information to the IETF Executive Director. Expires July 14, 2004 Madan [Page 4] Internet-Draft SIEVE Statistics February 14, 2004 Full Copyright Statement Copyright (C) The Internet Society 2003. 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. Expires July 14, 2004 Madan [Page 5]