rfc2087.IMAP4_QUOTA_extension.txt 8.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283
  1. Network Working Group J. Myers
  2. Request for Comments: 2087 Carnegie Mellon
  3. Category: Standards Track January 1997
  4. IMAP4 QUOTA extension
  5. Status of this Memo
  6. This document specifies an Internet standards track protocol for the
  7. Internet community, and requests discussion and suggestions for
  8. improvements. Please refer to the current edition of the "Internet
  9. Official Protocol Standards" (STD 1) for the standardization state
  10. and status of this protocol. Distribution of this memo is unlimited.
  11. 1. Abstract
  12. The QUOTA extension of the Internet Message Access Protocol [IMAP4]
  13. permits administrative limits on resource usage (quotas) to be
  14. manipulated through the IMAP protocol.
  15. Table of Contents
  16. 1. Abstract........................................... 1
  17. 2. Conventions Used in this Document.................. 1
  18. 3. Introduction and Overview.......................... 2
  19. 4. Commands........................................... 2
  20. 4.1. SETQUOTA Command................................... 2
  21. 4.2. GETQUOTA Command................................... 2
  22. 4.3. GETQUOTAROOT Command............................... 3
  23. 5. Responses.......................................... 3
  24. 5.1. QUOTA Response..................................... 3
  25. 5.2. QUOTAROOT Response................................. 4
  26. 6. Formal syntax...................................... 4
  27. 7. References......................................... 5
  28. 8. Security Considerations............................ 5
  29. 9. Author's Address................................... 5
  30. 2. Conventions Used in this Document
  31. In examples, "C:" and "S:" indicate lines sent by the client and
  32. server respectively.
  33. Myers Standards Track [Page 1]
  34. RFC 2087 QUOTA January 1997
  35. 3. Introduction and Overview
  36. The QUOTA extension is present in any IMAP4 implementation which
  37. returns "QUOTA" as one of the supported capabilities to the
  38. CAPABILITY command.
  39. An IMAP4 server which supports the QUOTA capability may support
  40. limits on any number of resources. Each resource has an atom name
  41. and an implementation-defined interpretation which evaluates to an
  42. integer. Examples of such resources are:
  43. Name Interpretation
  44. STORAGE Sum of messages' RFC822.SIZE, in units of 1024 octets
  45. MESSAGE Number of messages
  46. Each mailbox has zero or more implementation-defined named "quota
  47. roots". Each quota root has zero or more resource limits. All
  48. mailboxes that share the same named quota root share the resource
  49. limits of the quota root.
  50. Quota root names do not necessarily have to match the names of
  51. existing mailboxes.
  52. 4. Commands
  53. 4.1. SETQUOTA Command
  54. Arguments: quota root
  55. list of resource limits
  56. Data: untagged responses: QUOTA
  57. Result: OK - setquota completed
  58. NO - setquota error: can't set that data
  59. BAD - command unknown or arguments invalid
  60. The SETQUOTA command takes the name of a mailbox quota root and a
  61. list of resource limits. The resource limits for the named quota root
  62. are changed to be the specified limits. Any previous resource limits
  63. for the named quota root are discarded.
  64. If the named quota root did not previously exist, an implementation
  65. may optionally create it and change the quota roots for any number of
  66. existing mailboxes in an implementation-defined manner.
  67. Myers Standards Track [Page 2]
  68. RFC 2087 QUOTA January 1997
  69. Example: C: A001 SETQUOTA "" (STORAGE 512)
  70. S: * QUOTA "" (STORAGE 10 512)
  71. S: A001 OK Setquota completed
  72. 4.2. GETQUOTA Command
  73. Arguments: quota root
  74. Data: untagged responses: QUOTA
  75. Result: OK - getquota completed
  76. NO - getquota error: no such quota root, permission
  77. denied
  78. BAD - command unknown or arguments invalid
  79. The GETQUOTA command takes the name of a quota root and returns the
  80. quota root's resource usage and limits in an untagged QUOTA response.
  81. Example: C: A003 GETQUOTA ""
  82. S: * QUOTA "" (STORAGE 10 512)
  83. S: A003 OK Getquota completed
  84. 4.3. GETQUOTAROOT Command
  85. Arguments: mailbox name
  86. Data: untagged responses: QUOTAROOT, QUOTA
  87. Result: OK - getquota completed
  88. NO - getquota error: no such mailbox, permission denied
  89. BAD - command unknown or arguments invalid
  90. The GETQUOTAROOT command takes the name of a mailbox and returns the
  91. list of quota roots for the mailbox in an untagged QUOTAROOT
  92. response. For each listed quota root, it also returns the quota
  93. root's resource usage and limits in an untagged QUOTA response.
  94. Example: C: A003 GETQUOTAROOT INBOX
  95. S: * QUOTAROOT INBOX ""
  96. S: * QUOTA "" (STORAGE 10 512)
  97. S: A003 OK Getquota completed
  98. Myers Standards Track [Page 3]
  99. RFC 2087 QUOTA January 1997
  100. 5. Responses
  101. 5.1. QUOTA Response
  102. Data: quota root name
  103. list of resource names, usages, and limits
  104. This response occurs as a result of a GETQUOTA or GETQUOTAROOT
  105. command. The first string is the name of the quota root for which
  106. this quota applies.
  107. The name is followed by a S-expression format list of the resource
  108. usage and limits of the quota root. The list contains zero or
  109. more triplets. Each triplet conatins a resource name, the current
  110. usage of the resource, and the resource limit.
  111. Resources not named in the list are not limited in the quota root.
  112. Thus, an empty list means there are no administrative resource
  113. limits in the quota root.
  114. Example: S: * QUOTA "" (STORAGE 10 512)
  115. 5.2. QUOTAROOT Response
  116. Data: mailbox name
  117. zero or more quota root names
  118. This response occurs as a result of a GETQUOTAROOT command. The
  119. first string is the mailbox and the remaining strings are the
  120. names of the quota roots for the mailbox.
  121. Example: S: * QUOTAROOT INBOX ""
  122. S: * QUOTAROOT comp.mail.mime
  123. 6. Formal syntax
  124. The following syntax specification uses the augmented Backus-Naur
  125. Form (BNF) notation as specified in RFC 822 with one exception; the
  126. delimiter used with the "#" construct is a single space (SP) and not
  127. one or more commas.
  128. Except as noted otherwise, all alphabetic characters are case-
  129. insensitive. The use of upper or lower case characters to define
  130. token strings is for editorial clarity only. Implementations MUST
  131. accept these strings in a case-insensitive fashion.
  132. Myers Standards Track [Page 4]
  133. RFC 2087 QUOTA January 1997
  134. getquota ::= "GETQUOTA" SP astring
  135. getquotaroot ::= "GETQUOTAROOT" SP astring
  136. quota_list ::= "(" #quota_resource ")"
  137. quota_resource ::= atom SP number SP number
  138. quota_response ::= "QUOTA" SP astring SP quota_list
  139. quotaroot_response
  140. ::= "QUOTAROOT" SP astring *(SP astring)
  141. setquota ::= "SETQUOTA" SP astring SP setquota_list
  142. setquota_list ::= "(" 0#setquota_resource ")"
  143. setquota_resource ::= atom SP number
  144. 7. References
  145. [IMAP4] Crispin, M., "Internet Message Access Protocol - Version 4",
  146. RFC 1730, University of Washington, December 1994.
  147. [RFC-822] Crocker, D., "Standard for the Format of ARPA Internet
  148. Text Messages", STD 11, RFC 822.
  149. 8. Security Considerations
  150. Implementors should be careful to make sure the implementation of
  151. these commands does not violate the site's security policy. The
  152. resource usage of other users is likely to be considered confidential
  153. information and should not be divulged to unauthorized persons.
  154. 9. Author's Address
  155. John G. Myers
  156. Carnegie-Mellon University
  157. 5000 Forbes Ave.
  158. Pittsburgh PA, 15213-3890
  159. EMail: jgm+@cmu.edu
  160. Myers Standards Track [Page 5]