idnits 2.17.1 draft-ietf-nntpext-base-22.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- ** It looks like you're using RFC 3978 boilerplate. You should update this to the boilerplate described in the IETF Trust License Policy document (see https://trustee.ietf.org/license-info), which is required now. -- Found old boilerplate from RFC 3978, Section 5.5 on line 4766. -- Found old boilerplate from RFC 3979, Section 5, paragraph 2 on line 4750. -- Found old boilerplate from RFC 3979, Section 5, paragraph 3 on line 4756. ** Found boilerplate matching RFC 3978, Section 5.4, paragraph 1 (on line 4772), which is fine, but *also* found old RFC 2026, Section 10.4C, paragraph 1 text on line 34. ** The document seems to lack an RFC 3978 Section 5.1 IPR Disclosure Acknowledgement -- however, there's a paragraph with a matching beginning. Boilerplate error? ** This document has an original RFC 3978 Section 5.4 Copyright Line, instead of the newer IETF Trust Copyright according to RFC 4748. ** This document has an original RFC 3978 Section 5.5 Disclaimer, instead of the newer disclaimer which includes the IETF Trust according to RFC 4748. ** The document seems to lack an RFC 3979 Section 5, para. 1 IPR Disclosure Acknowledgement -- however, there's a paragraph with a matching beginning. Boilerplate error? Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- == No 'Intended status' indicated for this document; assuming Proposed Standard Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- ** The abstract seems to contain references ([RFC2629]), which it shouldn't. Please replace those with straight textual mentions of the documents in question. == There are 43 instances of lines with non-RFC2606-compliant FQDNs in the document. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the RFC 3978 Section 5.4 Copyright Line does not match the current year == Line 214 has weird spacing: '...cal|bar indic...' == Line 828 has weird spacing: '...abc,def the t...' == Line 2180 has weird spacing: '...dhhmmss serv...' == Using lowercase 'not' together with uppercase 'MUST', 'SHALL', 'SHOULD', or 'RECOMMENDED' is not an accepted usage according to RFC 2119. Please use uppercase 'NOT' together with RFC 2119 keywords (if that is what you mean). Found 'MUST not' in this paragraph: These are the only valid response codes for the initial greeting; the server MUST not return any other generic response code. -- The document seems to lack a disclaimer for pre-RFC5378 work, but may have content which was first submitted before 10 November 2008. If you have contacted all the original authors and they are all willing to grant the BCP78 rights to the IETF Trust, then this is fine, and you can ignore this comment. If not, you may need to add the pre-RFC5378 disclaimer. (See the Legal Provisions document at https://trustee.ietf.org/license-info for more information.) -- The document date (March 21, 2004) is 7312 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) == Missing Reference: 'C' is mentioned on line 4134, but not defined == Missing Reference: 'S' is mentioned on line 4135, but not defined -- Looks like a reference, but probably isn't: '1' on line 2912 == Missing Reference: 'GMT' is mentioned on line 2304, but not defined -- Possible downref: Non-RFC (?) normative reference: ref. 'ANSI1986' ** Obsolete normative reference: RFC 2234 (Obsoleted by RFC 4234) ** Obsolete normative reference: RFC 977 (Obsoleted by RFC 3977) -- Obsolete informational reference (is this intentional?): RFC 1036 (Obsoleted by RFC 5536, RFC 5537) -- Obsolete informational reference (is this intentional?): RFC 1305 (Obsoleted by RFC 5905) -- Obsolete informational reference (is this intentional?): RFC 1869 (Obsoleted by RFC 2821) -- Obsolete informational reference (is this intentional?): RFC 2616 (Obsoleted by RFC 7230, RFC 7231, RFC 7232, RFC 7233, RFC 7234, RFC 7235) -- Obsolete informational reference (is this intentional?): RFC 2629 (Obsoleted by RFC 7749) -- Obsolete informational reference (is this intentional?): RFC 2822 (Obsoleted by RFC 5322) Summary: 9 errors (**), 0 flaws (~~), 10 warnings (==), 13 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 1 NNTP C. Feather 2 Internet-Draft Thus plc 3 Expires: September 19, 2004 March 21, 2004 5 Network News Transport Protocol 6 draft-ietf-nntpext-base-22 8 Status of this Memo 10 By submitting this Internet-Draft, I certify that any applicable 11 patent or other IPR claims of which I am aware have been disclosed, 12 and any of which I become aware will be disclosed, in accordance with 13 RFC 3667. 15 Internet-Drafts are working documents of the Internet Engineering 16 Task Force (IETF), its areas, and its working groups. Note that other 17 groups may also distribute working documents as Internet-Drafts. 19 Internet-Drafts are draft documents valid for a maximum of six months 20 and may be updated, replaced, or obsoleted by other documents at any 21 time. It is inappropriate to use Internet-Drafts as reference 22 material or to cite them other than as "work in progress." 24 The list of current Internet-Drafts can be accessed at http:// 25 www.ietf.org/ietf/1id-abstracts.txt. 27 The list of Internet-Draft Shadow Directories can be accessed at 28 http://www.ietf.org/shadow.html. 30 This Internet-Draft will expire on September 19, 2004. 32 Copyright Notice 34 Copyright (C) The Internet Society (2004). All Rights Reserved. 36 Abstract 38 The Network News Transport Protocol (NNTP) has been in use in the 39 Internet for a decade and remains one of the most popular protocols 40 (by volume) in use today. This document is a replacement for RFC 977 41 and officially updates the protocol specification. It clarifies some 42 vagueness in RFC 977, includes some new base functionality, and 43 provides a specific mechanism to add standardized extensions to NNTP. 45 Administration 47 This document is a product of the NNTP Working Group, chaired by Russ 48 Allbery and Ned Freed. 50 This is draft 22. 52 Author's Note 54 This draft is written in XML using an NNTP-specific DTD. Custom 55 software is used to convert this to RFC 2629 [RFC2629] format, and 56 then the public "xml2rfc" package to further reduce this to text, 57 nroff source, and HTML. 59 No perl was used in producing this draft. 61 Rights 63 UNIX is a registered trademark of The Open Group. 65 Table of Contents 67 1. Introduction . . . . . . . . . . . . . . . . . . . . . . 5 68 2. Notation . . . . . . . . . . . . . . . . . . . . . . . . 6 69 3. Basic Concepts . . . . . . . . . . . . . . . . . . . . . 8 70 3.1 Commands and Responses . . . . . . . . . . . . . . . . . 8 71 3.2 Response Codes . . . . . . . . . . . . . . . . . . . . . 10 72 3.2.1 Generic Response Codes . . . . . . . . . . . . . . . . . 11 73 3.2.1.1 Examples . . . . . . . . . . . . . . . . . . . . . . . . 13 74 3.3 Pipelining . . . . . . . . . . . . . . . . . . . . . . . 15 75 3.3.1 Examples . . . . . . . . . . . . . . . . . . . . . . . . 16 76 3.4 Articles . . . . . . . . . . . . . . . . . . . . . . . . 16 77 4. The WILDMAT format . . . . . . . . . . . . . . . . . . . 18 78 4.1 Wildmat syntax . . . . . . . . . . . . . . . . . . . . . 18 79 4.2 Wildmat semantics . . . . . . . . . . . . . . . . . . . 18 80 4.3 Extensions . . . . . . . . . . . . . . . . . . . . . . . 19 81 4.4 Examples . . . . . . . . . . . . . . . . . . . . . . . . 20 82 5. Session administration commands . . . . . . . . . . . . 21 83 5.1 Initial Connection . . . . . . . . . . . . . . . . . . . 21 84 5.2 MODE READER . . . . . . . . . . . . . . . . . . . . . . 22 85 5.3 LIST EXTENSIONS . . . . . . . . . . . . . . . . . . . . 25 86 5.4 QUIT . . . . . . . . . . . . . . . . . . . . . . . . . . 27 87 6. Article posting and retrieval . . . . . . . . . . . . . 28 88 6.1 Group and article selection . . . . . . . . . . . . . . 28 89 6.1.1 GROUP . . . . . . . . . . . . . . . . . . . . . . . . . 28 90 6.1.2 LAST . . . . . . . . . . . . . . . . . . . . . . . . . . 31 91 6.1.3 NEXT . . . . . . . . . . . . . . . . . . . . . . . . . . 32 92 6.2 Retrieval of articles and article sections . . . . . . . 34 93 6.2.1 ARTICLE . . . . . . . . . . . . . . . . . . . . . . . . 34 94 6.2.2 HEAD . . . . . . . . . . . . . . . . . . . . . . . . . . 37 95 6.2.3 BODY . . . . . . . . . . . . . . . . . . . . . . . . . . 39 96 6.2.4 STAT . . . . . . . . . . . . . . . . . . . . . . . . . . 41 97 6.3 Article posting . . . . . . . . . . . . . . . . . . . . 44 98 6.3.1 POST . . . . . . . . . . . . . . . . . . . . . . . . . . 44 99 6.3.2 IHAVE . . . . . . . . . . . . . . . . . . . . . . . . . 46 100 7. Information commands . . . . . . . . . . . . . . . . . . 50 101 7.1 DATE . . . . . . . . . . . . . . . . . . . . . . . . . . 50 102 7.2 HELP . . . . . . . . . . . . . . . . . . . . . . . . . . 50 103 7.3 NEWGROUPS . . . . . . . . . . . . . . . . . . . . . . . 51 104 7.4 NEWNEWS . . . . . . . . . . . . . . . . . . . . . . . . 53 105 7.5 Time . . . . . . . . . . . . . . . . . . . . . . . . . . 54 106 7.5.1 Examples . . . . . . . . . . . . . . . . . . . . . . . . 54 107 7.6 The LIST commands . . . . . . . . . . . . . . . . . . . 55 108 7.6.1 LIST ACTIVE . . . . . . . . . . . . . . . . . . . . . . 55 109 7.6.2 LIST ACTIVE.TIMES . . . . . . . . . . . . . . . . . . . 57 110 7.6.3 LIST DISTRIBUTIONS . . . . . . . . . . . . . . . . . . . 59 111 7.6.4 LIST DISTRIB.PATS . . . . . . . . . . . . . . . . . . . 60 112 7.6.5 LIST NEWSGROUPS . . . . . . . . . . . . . . . . . . . . 61 113 8. Framework for NNTP extensions . . . . . . . . . . . . . 63 114 8.1 Initial IANA registry . . . . . . . . . . . . . . . . . 65 115 8.2 Standard extensions . . . . . . . . . . . . . . . . . . 65 116 8.3 The LISTGROUP extension . . . . . . . . . . . . . . . . 65 117 8.3.1 LISTGROUP . . . . . . . . . . . . . . . . . . . . . . . 66 118 8.4 Article metadata . . . . . . . . . . . . . . . . . . . . 67 119 8.4.1 The :bytes metadata item . . . . . . . . . . . . . . . . 68 120 8.4.2 The :lines metadata item . . . . . . . . . . . . . . . . 68 121 8.5 The OVER extension . . . . . . . . . . . . . . . . . . . 68 122 8.5.1 OVER . . . . . . . . . . . . . . . . . . . . . . . . . . 69 123 8.5.2 LIST OVERVIEW.FMT . . . . . . . . . . . . . . . . . . . 74 124 8.6 The HDR extension . . . . . . . . . . . . . . . . . . . 76 125 8.6.1 HDR . . . . . . . . . . . . . . . . . . . . . . . . . . 76 126 8.6.2 LIST HEADERS . . . . . . . . . . . . . . . . . . . . . . 80 127 9. Augmented BNF Syntax for NNTP . . . . . . . . . . . . . 84 128 9.1 Commands . . . . . . . . . . . . . . . . . . . . . . . . 84 129 9.2 Responses . . . . . . . . . . . . . . . . . . . . . . . 86 130 9.3 Multi-line response contents . . . . . . . . . . . . . . 86 131 9.4 Articles . . . . . . . . . . . . . . . . . . . . . . . . 88 132 9.5 General non-terminals . . . . . . . . . . . . . . . . . 88 133 10. IANA Considerations . . . . . . . . . . . . . . . . . . 90 134 11. Security Considerations . . . . . . . . . . . . . . . . 91 135 11.1 Personal and Proprietary Information . . . . . . . . . . 91 136 11.2 Abuse of Server Log Information . . . . . . . . . . . . 91 137 11.3 Weak Authentication and Access Control . . . . . . . . . 91 138 11.4 DNS Spoofing . . . . . . . . . . . . . . . . . . . . . . 92 139 11.5 UTF-8 issues . . . . . . . . . . . . . . . . . . . . . . 92 140 11.6 Caching of LIST EXTENSIONS results . . . . . . . . . . . 93 141 12. Acknowledgements . . . . . . . . . . . . . . . . . . . . 95 142 Normative References . . . . . . . . . . . . . . . . . . 97 143 Informative References . . . . . . . . . . . . . . . . . 98 144 Author's Address . . . . . . . . . . . . . . . . . . . . 98 145 A. Future Directions . . . . . . . . . . . . . . . . . . . 99 146 B. Interaction with other specifications . . . . . . . . . 100 147 B.1 Header folding . . . . . . . . . . . . . . . . . . . . . 100 148 B.2 Message-IDs . . . . . . . . . . . . . . . . . . . . . . 100 149 B.3 Article posting . . . . . . . . . . . . . . . . . . . . 101 150 C. Summary of Response Codes . . . . . . . . . . . . . . . 103 151 D. Formal specification of the standard extensions . . . . 108 152 D.1 The LISTGROUP extension . . . . . . . . . . . . . . . . 108 153 D.2 The OVER extension . . . . . . . . . . . . . . . . . . . 108 154 D.3 The HDR extension . . . . . . . . . . . . . . . . . . . 109 155 Intellectual Property and Copyright Statements . . . . . 111 157 1. Introduction 159 This document specifies the Network News Transport Protocol (NNTP), 160 which is used for the distribution, inquiry, retrieval, and posting 161 of Netnews articles using a reliable stream-based mechanism. For news 162 reading clients, NNTP enables retrieval of news articles that are 163 stored in a central database, giving subscribers the ability to 164 select only those articles they wish to read. 166 The Netnews model provides for indexing, cross-referencing, and 167 expiration of aged messages. For server-to-server interaction, NNTP 168 is designed for efficient transmission of Netnews articles over a 169 reliable full duplex communication channel. 171 Every attempt is made to ensure that the protocol specification in 172 this document is compatible with the version specified in RFC 977 173 [RFC977]. However, this version does not support the ill-defined 174 SLAVE command and permits four digit years to be specified in the 175 NEWNEWS and NEWGROUPS commands. It changes the default character set 176 to UTF-8 [RFC3629] instead of US-ASCII [ANSI1986]. It now requires 177 all articles to have a message-id, eliminating the "<0>" placeholder 178 used in RFC 977. It also extends the newsgroup name matching 179 capabilities already documented in RFC 977. 181 Generally, new functionality is made available using new commands. A 182 number of such commands (including some commands taken from RFC 2980 183 [RFC2980]) are now mandatory. Part of the new functionality involves 184 a mechanism to discover what new functionality is available to 185 clients from a server. This mechanism can also be used to add more 186 functionality as needs merit such additions. 188 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 189 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 190 document are to be interpreted as described in RFC 2119 [RFC2119]. 192 An implementation is not compliant if it fails to satisfy one or more 193 of the MUST requirements for this protocol. An implementation that 194 satisfies all the MUST and all the SHOULD requirements for its 195 protocols is said to be "unconditionally compliant"; one that 196 satisfies all the MUST requirements but not all the SHOULD 197 requirements for NNTP is said to be "conditionally compliant". 199 For the remainder of this document, the term "client" or "client 200 host" refers to a host making use of the NNTP service, while the term 201 "server" or "server host" refers to a host that offers the NNTP 202 service. 204 2. Notation 206 The following notational conventions are used in this document. 208 UPPERCASE indicates literal text to be included in the 209 command; 210 lowercase indicates a token described elsewhere; 211 [brackets] indicate that the argument is optional; 212 ellipsis... indicates that the argument may be repeated any 213 number of times (it must occur at least once); 214 vertical|bar indicates a choice of two mutually exclusive 215 arguments (exactly one must be provided). 217 The name "message-id" for a command or response argument indicates 218 that it is the message-id of an article as described in Section 3.4, 219 including the angle brackets. 221 The name "wildmat" for an argument indicates that it is a wildmat as 222 defined in Section 4. If the argument does not meet the requirements 223 of that section (for example, if it does not fit the grammar of 224 Section 4.1) the NNTP server MAY place some interpretation on it (not 225 specified by this document) or otherwise MUST treat it as a syntax 226 error. 228 Responses for each command will be described in tables listing the 229 required format of a response followed by the meaning that should be 230 ascribed to that response. 232 The terms "NUL", "TAB", "LF", "CR, and "space" refer to the octets 233 with those codes in US-ASCII [ANSI1986] (that is, %x00, %x09, %x0A, 234 %x0D, and %x20 respectively), as do quoted characters (so "." and "<" 235 refer to %x2E and %x3C). The term "CRLF" or "CRLF pair" means the 236 sequence CR immediately followed by LF (that is, %x0D.0A). A 237 "printable US-ASCII character" is an octet in the range %x21-7E. 239 Examples in this document are not normative but serve to illustrate 240 usages, arguments, and responses. In the examples, a "[C]" will be 241 used to represent the client host and a "[S]" will be used to 242 represent the server host. Most of the examples do not rely on a 243 particular server state. In some cases, however, they do assume that 244 the current selected newsgroup (see the GROUP command (Section 245 6.1.1)) is invalid; when so, this is indicated at the start of the 246 example. 248 Terms which might be read as specifying details of a client or server 249 implementation, such as "database", are used simply to ease 250 description. Providing that implementations conform to the protocol 251 and format specifications in this document, no specific technique is 252 mandated. 254 3. Basic Concepts 256 3.1 Commands and Responses 258 NNTP operates over any reliable data stream 8-bit-wide channel. 259 Initially, the server host starts the NNTP service by listening on a 260 TCP port; when running over TCP/IP, the official port for the NNTP 261 service is 119. When a client host wishes to make use of the service, 262 it MUST establish a TCP connection with the server host by connecting 263 to that host on the same port on which the server is listening. When 264 the connection is established, the NNTP server host MUST send a 265 greeting. The client host and server host then exchange commands and 266 responses (respectively) until the connection is closed or aborted. 268 The character set for all NNTP commands is UTF-8 [RFC3629]. Commands 269 in NNTP MUST consist of a keyword, which MAY be followed by one or 270 more arguments. A CRLF pair MUST terminate all commands. Multiple 271 commands MUST NOT be on the same line. Keywords MUST consist of 272 printable US-ASCII characters. Unless otherwise noted elsewhere in 273 this document, arguments SHOULD consist of printable US-ASCII 274 characters. Keywords and arguments MUST be each separated by one or 275 more space or TAB characters. Keywords MUST be at least three 276 characters and MUST NOT exceed 12 characters. Command lines MUST NOT 277 exceed 512 octets, which includes the terminating CRLF pair. The 278 arguments MUST NOT exceed 497 octets. A server MAY relax these limits 279 for commands defined in an extension. 281 Where this specification permits UTF-8 characters outside the range 282 U+0000 to U+007F, implementations MUST NOT use the Byte Order Mark 283 (U+FEFF, encoding %xEF.BB.BF), and MUST use the Word Joiner (U+2060, 284 encoding %xE2.91.A0) for the meaning Zero Width No-Break Space, in 285 command lines and the initial lines of responses, and SHOULD apply 286 these same principles throughout. 288 The term "character" means a single Unicode code point and 289 implementations are not required to carry out normalisation. Thus 290 U+0084 (A-dieresis) is one character while U+0041 U+0308 (A composed 291 with dieresis) is two; the two need not be treated as equivalent. 293 Commands may have variants, using a second keyword immediately after 294 the first to indicate which variant is required. The only such 295 commands in this specification are LIST and MODE. Note that such 296 variants are sometimes referred to as if they were commands in their 297 own right: "the LIST ACTIVE" command should be read as shorthand for 298 "the ACTIVE variant of the LIST command". 300 Keywords are case-insensitive; the case of keywords for commands MUST 301 be ignored by the server. Command and response arguments are case- or 302 language-specific only when stated, either in this document or in 303 other relevant specifications. 305 An NNTP server MUST implement all the commands in this specification 306 except for those marked as optional and those in extensions. 308 Each response MUST start with a three-digit response code that is 309 sufficient to distinguish all responses. Certain valid responses are 310 defined to be multi-line; for all others, the response is contained 311 in a single line. The first or only line of the response MUST NOT 312 exceed 512 octets, which includes the response code and the 313 terminating CRLF pair; an extension MAY specify a greater maximum for 314 commands that it defines, but not for any other command. 316 All multi-line responses MUST adhere to the following format: 318 1. The response consists of a sequence of one or more "lines", each 319 being a stream of octets ending with a CRLF pair. Apart from 320 those line endings, the stream MUST NOT include the octets NUL, 321 LF, or CR. 323 2. The first such line contains the response code as with a single 324 line response. 326 3. If any subsequent line begins with the "termination octet" ("." 327 or %x2E), that line MUST be "byte-stuffed" by pre-pending an 328 additional termination octet to that line of the response. 330 4. The lines of the response MUST be followed by a terminating line 331 consisting of a single termination octet followed by a CRLF pair 332 in the normal way. Thus a multi-line response is always 333 terminated with the five octets CRLF "." CRLF (%x0D.0A.2E.0D.0A). 335 5. When interpreting a multi-line response, the "byte-stuffing" MUST 336 be undone; i.e. the client MUST ensure that, in any line 337 beginning with the termination octet followed by octets other 338 than a CRLF pair, that initial termination octet is disregarded. 340 6. Likewise, the terminating line ("." CRLF or %x2E.0D.0A) MUST NOT 341 be considered part of the multi-line response; i.e. the client 342 MUST ensure that any line beginning with the termination octet 343 followed immediately by a CRLF pair is disregarded; (the first 344 CRLF pair of the terminating CRLF "." CRLF is, of course, part of 345 the last line of the response). 347 Note that texts using an encoding (such as UTF-16 or UTF-32) that may 348 contain the octets NUL, LF, or CR other than a CRLF pair cannot be 349 reliably conveyed in the above format. However, except when stated 350 otherwise, this specification does not require the content to be 351 UTF-8 and it is possible for octets above and below 128 to be mixed 352 arbitrarily. 354 This document does not place any limit on the length of a subsequent 355 line in a multi-line response. However, the standards that define the 356 format of articles may do so. 358 An NNTP server MAY have an inactivity autologout timer. Such a timer 359 SHOULD be of at least three minutes duration, with the exception that 360 there MAY be a shorter limit on how long the server is willing to 361 wait for the first command from the client. The receipt of any 362 command from the client during the timer interval SHOULD suffice to 363 reset the autologout timer. Similarly, the receipt of any significant 364 amount of data from the client while in the midst of sending a 365 multi-line message to the server (such as during a POST or IHAVE 366 command) SHOULD suffice to reset the autologout timer. When the timer 367 expires, the server SHOULD close the TCP connection without sending 368 any response to the client. 370 3.2 Response Codes 372 Each response MUST begin with a three-digit status indicator. These 373 are status reports from the server and indicate the response to the 374 last command received from the client. 376 The first digit of the response broadly indicates the success, 377 failure, or progress of the previous command: 379 1xx - Informative message. 380 2xx - Command completed OK. 381 3xx - Command OK so far; send the rest of it. 382 4xx - Command was syntactically correct but failed for some 383 reason. 384 5xx - Command unknown, unsupported, unavailable, or syntax error. 386 The next digit in the code indicates the function response category: 388 x0x - Connection, set-up, and miscellaneous messages 389 x1x - Newsgroup selection 390 x2x - Article selection 391 x3x - Distribution functions 392 x4x - Posting 393 x8x - Reserved for authentication and privacy extensions 394 x9x - Reserved for private use (non-standard extensions) 396 Certain responses contain arguments such as numbers and names in 397 addition to the status indicator. In those cases, to simplify 398 interpretation by the client the number and type of such arguments is 399 fixed for each response code, as is whether or not the code 400 introduces a multi-line response. Any extension MUST follow this 401 principle as well, but note that, for historical reasons, the 211 402 response code is an exception to this. In all other cases, the client 403 MUST only use the status indicator itself to determine the nature of 404 the response. The exact response codes that can be returned by any 405 given command are detailed in the description of that command. 407 Arguments MUST be separated from the numeric status indicator and 408 from each other by a single space. All numeric arguments MUST be in 409 base 10 (decimal) format, and MAY have leading zeros. String 410 arguments MUST contain at least one character and MUST NOT contain 411 TAB, LF, CR, or space. The server MAY add any text after the response 412 code or last argument as appropriate, and the client MUST NOT make 413 decisions based on this text. Such text MUST be separated from the 414 numeric status indicator or the last argument by at least one space. 416 The server MUST respond to any command with the appropriate generic 417 response (given in Section 3.2.1) if it represents the situation. 418 Otherwise, each recognized command MUST return one of the response 419 codes specifically listed in its description or in an extension. A 420 server MAY provide extensions to this specification, including new 421 commands, new variants or features of existing commands, and other 422 ways of changing the internal state of the server. However, the 423 server MUST NOT produce any other responses to a client that does not 424 invoke any of the additional features. (Therefore a client that 425 restricts itself to this specification will only receive the 426 responses that are listed.) 428 If a client receives an unexpected response, it SHOULD use the first 429 digit of the response to determine the result. For example, an 430 unexpected 2xx should be taken as success and an unexpected 4xx or 431 5xx as failure. 433 Response codes not specified in this document MAY be used for any 434 installation-specific additional commands also not specified. These 435 SHOULD be chosen to fit the pattern of x9x specified above. 437 Neither this document nor any extension registered with IANA (see 438 Section 8) will specify any response codes of the x9x pattern. 439 (Implementers of extensions are accordingly cautioned not to use such 440 responses for extensions that may subsequently be submitted for 441 registration.) 443 3.2.1 Generic Response Codes 445 The server MUST respond to any command with the appropriate one of 446 the following generic responses if it represents the situation. 448 If the command is not recognized, or it is an optional command or 449 extension that is not implemented by the server, the response code 450 500 MUST be returned. 452 If there is a syntax error in the arguments of a recognized command, 453 including the case where more arguments are provided than the command 454 specifies or the command line is longer than the server accepts, the 455 response code 501 MUST be returned. The line MUST NOT be truncated or 456 split and then interpreted. Note that where a command has variants 457 depending on a second keyword (e.g. LIST ACTIVE and LIST NEWSGROUPS), 458 then 501 MUST be used when the base command is implemented but the 459 requested variant is not, and 500 MUST be used only when the base 460 command itself is not implemented. 462 If the server experiences an internal fault or problem that means it 463 is unable to carry out the command (for example, a necessary file is 464 missing or a necessary service could not be contacted), the response 465 code 403 MUST be returned. If the server recognizes the command but 466 does not provide an optional feature (for example because it does not 467 store the required information), or only handles a subset of 468 legitimate cases (see the HDR command (Section 8.6.1) for an 469 example), the response code 503 MUST be returned. Note that where a 470 command is optional (e.g. LIST ACTIVE.TIMES) and is not provided by a 471 server, this MAY be treated as an unimplemented command (response 472 code 500 or 501 as appropriate) or as a working command where the 473 information is not available (response code 503). 475 If the client is not authorized to use the specified facility when 476 the server is in its current state, then the appropriate one of the 477 following response codes MUST be used. 479 502: it is necessary to terminate the connection and start a new one 480 with the appropriate authority before the command can be used. 481 Note that the server MUST NOT close the TCP connection immediately 482 after a 502 response except at the initial connection (Section 483 5.1) and with the MODE READER (Section 5.2) command. See also the 484 latter command for historical usage of this response. 486 480: the client must authenticate itself to the server (that is, 487 provide information as to the identity of the client) before the 488 facility can be used. This will involve the use of an 489 authentication extension. 491 483: the client must negotiate appropriate privacy protection on the 492 connection. This will involve the use of a privacy extension. 494 401: the client must change the state of the connection in some other 495 manner. The first argument of the response MUST be the 496 extension-label (see Section 8) of the extension (which may be a 497 private extension) that provides the necessary mechanism, or 498 "MODE-READER" if it is necessary to use the MODE READER (Section 499 5.2) command. 501 If the server has to terminate the connection for some reason, it 502 MUST give a 400 response code to the next command and then 503 immediately close the TCP connection. 505 The client MUST be prepared to receive any of these responses for any 506 command (except, of course, that the server MUST NOT generate a 500 507 response code for mandatory commands). 509 3.2.1.1 Examples 511 Example of an unknown command: 513 [C] MAIL 514 [S] 500 Unknown command 516 Example of an unsupported extension: 518 [C] LIST EXTENSIONS 519 [S] 202 Extensions supported: 520 [S] LISTGROUP 521 [S] . 522 [C] OVER 523 [S] 500 Unknown command 525 Example of an unsupported variant: 527 [C] MODE POSTER 528 [S] 501 Unknown MODE option 530 Example of a syntax error: 532 [C] ARTICLE a.message.id@no.angle.brackets 533 [S] 501 Syntax error 535 Example of an overlong command line: 537 [C] HEAD 53 54 55 538 [S] 501 Too many arguments 540 Example of a bad wildmat: 542 [C] LIST ACTIVE u[ks].* 543 [S] 501 Syntax error 545 Example of an attempt to access a facility not available to this 546 connection: 548 [C] MODE READER 549 [S] 200 Reader mode, posting permitted 550 [C] IHAVE 551 [S] 502 Permission denied 553 Example of an attempt to access a facility requiring authentication: 555 [C] GROUP secret.group 556 [S] 480 Permission denied 558 followed by a successful attempt following such authentication: 560 [C] XSECRET fred flintstone 561 [S] 290 Password for fred accepted 562 [C] GROUP secret.group 563 [S] 211 5 1 20 secret.group selected 565 Example of an attempt to access a facility requiring privacy: 567 [C] GROUP secret.group 568 [S] 483 Secure connection required 569 [C] XENCRYPT 570 [Client and server negotiate encryption on the link] 571 [S] 283 Encrypted link established 572 [C] GROUP secret.group 573 [S] 211 5 1 20 secret.group selected 575 Example of a need to change mode before using a facility: 577 [C] GROUP binary.group 578 [S] 401 XHOST Not on this virtual host 579 [C] XHOST binary.news.example.org 580 [S] 290 binary.news.example.org virtual host selected 581 [C] GROUP binary.group 582 [S] 211 5 1 77 binary.group selected 584 Example of a temporary failure: 586 [C] GROUP archive.local 587 [S] 403 Archive server temporarily offline 589 Example of the server needing to close down immediately: 591 [C] ARTICLE 123 592 [S] 400 Power supply failed, running on UPS 593 [Server closes connection.] 595 3.3 Pipelining 597 NNTP is designed to operate over a reliable bi-directional connection 598 such as TCP. Therefore, if a command does not depend on the response 599 to the previous one, it should not matter if it is sent before that 600 response is received. Doing this is called "pipelining". However, 601 certain server implementations throw away all text received from the 602 client following certain commands before sending their response. If 603 this happens, pipelining will be affected because one or more 604 commands will have been ignored or misinterpreted, and the client 605 will be matching the wrong responses to each command. Since there are 606 significant benefits to pipelining, but also circumstances where it 607 is reasonable or common for servers to behave in the above manner, 608 this document puts certain requirements on both clients and servers. 610 Except where stated otherwise, a client MAY use pipelining. That is, 611 it may send a command before receiving the response for the previous 612 command. The server MUST allow pipelining and MUST NOT throw away any 613 text received after a command. Irrespective of whether or not 614 pipelining is used, the server MUST process commands in the order 615 they are sent. 617 If the specific description of a command says it "MUST NOT be 618 pipelined", that command MUST end any pipeline of commands. That is, 619 the client MUST NOT send any following command until receiving the 620 CRLF at the end of the response from the command. The server MAY 621 ignore any data received after the command and before the CRLF at the 622 end of the response is sent to the client. 624 The initial connection must not be part of a pipeline; that is, the 625 client MUST NOT send any command until receiving the CRLF at the end 626 of the greeting. 628 If the client uses blocking system calls to send commands, it MUST 629 ensure that the amount of text sent in pipelining does not cause a 630 deadlock between transmission and reception. The amount of text 631 involved will depend on window sizes in the transmission layer, and 632 is typically 4k octets for TCP. (Since the server only sends data in 633 response to commands from the client, the converse problem does not 634 occur.) 636 3.3.1 Examples 638 Example of correct use of pipelining: 640 [C] GROUP misc.test 641 [C] STAT 642 [C] NEXT 643 [S] 211 1234 3000234 3002322 misc.test 644 [S] 223 3000234 <45223423@example.com> retrieved 645 [S] 223 3000237 <668929@example.org> retrieved 647 Example of incorrect use of pipelining (the MODE READER command may 648 not be pipelined): 650 [C] GROUP misc.test 651 [C] MODE READER 652 [C] DATE 653 [C] NEXT 654 [S] 211 1234 3000234 3002322 misc.test 655 [S] 200 Server ready, posting allowed 656 [S] 223 3000237 <668929@example.org> retrieved 658 The DATE command has been thrown away by the server and so there is 659 no 111 response to match it. 661 3.4 Articles 663 NNTP is intended to transfer articles between clients and servers. 664 For the purposes of this specification, articles are required to 665 conform to the rules in this section and clients and servers MUST 666 correctly process any article received from the other that does so. 667 Note that this requirement applies only to the contents of 668 communications over NNTP; it does not prevent the client or server 669 from subsequently rejecting an article for reasons of local policy. 670 Also see Appendix B for further restrictions on the format of 671 articles in some uses of NNTP. 673 An article consists of two parts: the headers and the body. They are 674 separated by a single empty line, or in other words by two 675 consecutive CRLF pairs (if there is more than one empty line, the 676 second and subsequent ones are part of the body). In order to meet 677 the general requirements of NNTP, an article MUST NOT include the 678 octet NUL, MUST NOT contain the octets LF and CR other than as part 679 of a CRLF pair, and MUST end with a CRLF pair. This specification 680 puts no further restrictions on the body; in particular, it MAY be 681 empty. 683 The headers of an article consist of one or more header lines. Each 684 header line consists of a header name, a colon, a space, the header 685 content, and a CRLF in that order. The name consists of one or more 686 printable US-ASCII characters other than colon and, for the purposes 687 of this specification, is not case-sensitive. There MAY be more than 688 one header line with the same name. The content MUST NOT contain 689 CRLF; it MAY be empty. A header may be "folded"; that is, a CRLF pair 690 may be placed before any TAB or space in the line; there MUST still 691 be some other octet between any two CRLF pairs in a header line. 692 (Note that folding means that the header line occupies more than one 693 line when displayed or transmitted; nevertheless it is still referred 694 to as "a" header line.) The presence or absence of folding does not 695 affect the meaning of the header line; that is, the CRLF pairs 696 introduced by folding are not considered part of the header content. 697 Header lines SHOULD NOT be folded before the space after the colon 698 that follows the header name, and SHOULD include at least one octet 699 other than %x09 or %x20 between CRLF pairs. However, if an article 700 has been received from elsewhere with one of these, clients and 701 servers MAY transfer it to the other without re-folding it. 703 The content of a header SHOULD be in UTF-8. However, if a server 704 receives an article from elsewhere that uses octets in the range 128 705 to 255 in some other manner, it MAY pass it to a client without 706 modification. Therefore clients MUST be prepared to receive such 707 headers and also data derived from them (e.g. in the responses from 708 the OVER extension (Section 8.5)) and MUST NOT assume that they are 709 always UTF-8. 711 Each article MUST have a unique message-id; two articles offered by 712 an NNTP server MUST NOT have the same message-id. For the purposes of 713 this specification, message-ids are opaque strings that MUST meet the 714 following requirements: 716 o A message-id MUST begin with "<" and end with ">", and MUST NOT 717 contain the latter except at the end. 719 o A message-id MUST be between 3 and 250 octets in length. 721 o A message-id MUST NOT contain octets other than printable US-ASCII 722 characters. 724 Two message-ids are the same if and only if they consist of the same 725 sequence of octets. 727 This specification does not describe how the message-id of an article 728 is determined. If the server does not have any way to determine a 729 message-id from the article itself, it MUST synthesize one (this 730 specification does not require the article to be changed as a 731 result). See also Appendix B.2. 733 4. The WILDMAT format 735 The WILDMAT format described here is based on the version first 736 developed by Rich Salz [SALZ1992], which in turn was derived from the 737 format used in the UNIX "find" command to articulate file names. It 738 was developed to provide a uniform mechanism for matching patterns in 739 the same manner that the UNIX shell matches filenames. 741 4.1 Wildmat syntax 743 A wildmat is described by the following ABNF [RFC2234] syntax (note 744 that this syntax contains ambiguities and special cases described at 745 the end): 747 wildmat = wildmat-pattern *("," ["!"] wildmat-pattern) 749 wildmat-pattern = 1*wildmat-item 751 wildmat-item = wildmat-exact / wildmat-wild 753 wildmat-exact = %x21-29 / %x2B / %x2D-3E / %x40-5A / %x5E-7E / 754 UTF8-non-ascii ; exclude * , ? [ \ ] 756 wildmat-wild = "*" / "?" 758 UTF8-non-ascii is defined in Section 9. 760 This syntax must be interpreted subject to the following rule: 762 Where a wildmat-pattern is not immediately preceded by "!", it shall 763 not begin with a "!". 765 Note: the characters \ , [ and ] are not allowed in wildmats, while * 766 and ? are always wildcards. This should not be a problem since these 767 characters cannot occur in newsgroup names, which is the only current 768 use of wildmats. Backslash is commonly used to suppress the special 769 meaning of characters while brackets are used to introduce sets. 770 However, these usages are not universal and interpretation of these 771 characters in the context of UTF-8 strings is both potentially 772 complex and differs from existing practice, so they were omitted from 773 this specification. A future extension to this specification may 774 provide semantics for these characters. 776 4.2 Wildmat semantics 778 A wildmat is tested against a string, and either matches or does not 779 match. To do this, each constituent wildmat-pattern is matched 780 against the string and the rightmost pattern that matches is 781 identified. If that wildmat-pattern is not preceded with "!", the 782 whole wildmat matches. If it is preceded by "!", or if no 783 wildmat-pattern matches, the whole wildmat does not match. 785 For example, consider the wildmat "a*,!*b,*c*": 787 the string "aaa" matches because the rightmost match is with "a*" 789 the string "abb" does not match because the rightmost match is 790 with "*b" 792 the string "ccb" matches because the rightmost match is with "*c*" 794 the string "xxx" does not match because no wildmat-pattern matches 796 A wildmat-pattern matches a string if the string can be broken into 797 components, each of which matches the corresponding wildmat-item in 798 the pattern; the matches must be in the same order, and the whole 799 string must be used in the match. The pattern is "anchored"; that is, 800 the first and last characters in the string must match the first and 801 last item respectively (unless that item is an asterisk matching zero 802 characters). 804 A wildmat-exact matches the same character (which may be more than 805 one octet in UTF-8). 807 "?" matches exactly one character (which may be more than one octet). 809 "*" matches zero or more characters. It can match an empty string, 810 but it cannot match a subsequence of a UTF-8 sequence that is not 811 aligned to the character boundaries. 813 4.3 Extensions 815 An NNTP server or extension MAY extend the syntax or semantics of 816 wildmats provided that all wildmats that meet the requirements of 817 Section 4.1 have the meaning ascribed to them by Section 4.2. Future 818 editions of this document may also extend wildmats. 820 4.4 Examples 822 In these examples, $ and @ are used to represent the two octets %xC2 823 and %xA3 respectively; $@ is thus the UTF-8 encoding for the pound 824 sterling symbol, shown as # in the descriptions. 826 Wildmat Description of strings that match 827 abc the one string "abc" 828 abc,def the two strings "abc" and "def" 829 $@ the one character string "#" 830 a* any string that begins with "a" 831 a*b any string that begins with "a" and ends with "b" 832 a*,*b any string that begins with "a" or ends with "b" 833 a*,!*b any string that begins with "a" and does not end with 834 "b" 835 a*,!*b,c* any string that begins with "a" and does not end with 836 "b", and any string that begins with "c" no matter 837 what it ends with 838 a*,c*,!*b any string that begins with "a" or "c" and does not 839 end with "b" 840 ?a* any string with "a" as its second character 841 ??a* any string with "a" as its third character 842 *a? any string with "a" as its penultimate character 843 *a?? any string with "a" as its antepenultimate character 845 5. Session administration commands 847 5.1 Initial Connection 849 5.1.1 Usage 851 Responses 852 200 Service available, posting allowed 853 201 Service available, posting prohibited 854 400 Service temporarily unavailable [1] 855 502 Service permanently unavailable [1] 857 These are the only valid response codes for the initial greeting; 858 the server MUST not return any other generic response code. 860 [1] Following a 400 or 502 response the server MUST immediately close 861 the connection. 863 5.1.2 Description 865 There is no command presented by the client upon initial connection 866 to the server. The server MUST present an appropriate response code 867 as a greeting to the client. This response informs the client whether 868 service is available and whether the client is permitted to post. 870 If the server will accept further commands from the client including 871 POST, the server MUST present a 200 greeting code. If the server will 872 accept further commands from the client, but it is not authorized to 873 post articles using the POST command, the server MUST present a 201 874 greeting code. 876 Otherwise the server MUST present a 400 or 502 greeting code and then 877 immediately close the connection. 400 SHOULD be used if the issue is 878 only temporary (for example, because of load) and the client can 879 expect to be able to connect successfully at some point in the future 880 without making any changes. 502 MUST be used if the client is not 881 permitted under any circumstances to interact with the server, and 882 MAY be used if the server has insufficient information to determine 883 whether the issue is temporary or permanent. 885 5.1.3 Examples 887 Example of a normal connection from an authorized client which then 888 terminates the session (see Section 5.4): 890 [Initial TCP connection set-up completed.] 891 [S] 200 NNTP Service Ready, posting permitted 893 [C] QUIT 894 [S] 205 NNTP Service exits normally 895 [Server closes connection.] 897 Example of a normal connection from an authorized client that is not 898 permitted to post; it also immediately terminates the session: 900 [Initial TCP connection set-up completed.] 901 [S] 201 NNTP Service Ready, posting prohibited 902 [C] QUIT 903 [S] 205 NNTP Service exits normally 904 [Server closes connection.] 906 Example of a normal connection from an unauthorized client: 908 [Initial TCP connection set-up completed.] 909 [S] 502 NNTP Service permanently unavailable 910 [Server closes connection.] 912 Example of a connection from a client where the server is unable to 913 provide service: 915 [Initial TCP connection set-up completed.] 916 [S] 400 NNTP Service temporarily unavailable 917 [Server closes connection.] 919 5.2 MODE READER 921 5.2.1 Usage 923 This command MUST NOT be pipelined. 925 Syntax 926 MODE READER 928 Responses 929 200 Posting allowed 930 201 Posting prohibited 931 400 Service temporarily unavailable [1] 932 502 Service permanently unavailable [1] 934 [1] Following a 400 or 502 response the server MUST immediately close 935 the connection. 937 5.2.2 Description 939 MODE READER SHOULD be sent by any client that intends to use any 940 command in this specification (including Section 8) other than IHAVE, 941 HEAD, STAT, LIST ACTIVE, or LIST EXTENSIONS; other extensions MAY 942 also require MODE READER to be used. Servers MAY require that this 943 command be issued before any commands other than the above are sent 944 and MAY reject such commands until after a MODE READER command has 945 been sent. Such rejections SHOULD use response code 401 with argument 946 "MODE-READER", but for historical reasons response code 502 MAY be 947 used, even though this situation does not meet the conditions for 948 that response. 950 Once MODE READER is sent, IHAVE (and any related extensions) MAY no 951 longer be permitted, even if it were permitted before the MODE READER 952 command. The results of LIST EXTENSIONS MAY be different following a 953 MODE READER command than prior to the issuing of that command. 955 The server MUST return a response using the same codes as the initial 956 greeting (as described in Section 5.1.1) to indicate its ability to 957 provide reading service to the client. Note that the response need 958 not be the same as the one presented during the initial greeting. 960 Servers are encouraged to not require this command even though 961 clients SHOULD send it when appropriate. It is present to support 962 some news architectures that switch between modes based on whether a 963 given connection is a peer-to-peer connection with another server or 964 a news reading client. 966 5.2.3 Examples 968 Example of use of the MODE READER command by an authorized client 969 which then terminates the session (see Section 5.4): 971 [C] MODE READER 972 [S] 200 NNTP Service Ready, posting permitted 973 [C] QUIT 974 [S] 205 NNTP Service exits normally 975 [Server closes connection.] 977 Example of use of the MODE READER command by an authorized client 978 that is not permitted to post; it also immediately terminates the 979 session: 981 [C] MODE READER 982 [S] 201 NNTP Service Ready, posting prohibited 983 [C] QUIT 984 [S] 205 NNTP Service exits normally 986 [Server closes connection.] 988 Example of use of MODE READER by a client not authorized to receive 989 service from the server as a news reader: 991 [C] MODE READER 992 [S] 502 NNTP Service permanently unavailable 993 [Server closes connection.] 995 Example of a connection from any client where the server is 996 temporarily unable to provide news reader service: 998 [C] MODE READER 999 [S] 400 NNTP Service temporarily unavailable 1000 [Server closes connection.] 1002 Example of a facility that requires MODE READER before use, using the 1003 preferred response: 1005 [C] GROUP misc.test 1006 [S] 401 MODE-READER currently in peering mode 1007 [C] MODE READER 1008 [S] 200 NNTP Service Ready, posting permitted 1009 [C] GROUP misc.test 1010 [S] 211 1234 3000234 3002322 misc.test 1012 Example of a facility that requires MODE READER before use, using the 1013 historical but deprecated response: 1015 [C] GROUP misc.test 1016 [S] 502 Not available in peering mode 1017 [C] MODE READER 1018 [S] 200 NNTP Service Ready, posting permitted 1019 [C] GROUP misc.test 1020 [S] 211 1234 3000234 3002322 misc.test 1022 Example of a facility that cannot be used after MODE READER: 1024 [C] IHAVE 1025 [S] 435 Duplicate 1026 [C] MODE READER 1027 [S] 200 Reader mode, posting permitted 1028 [C] IHAVE 1029 [S] 502 Permission denied 1031 5.3 LIST EXTENSIONS 1033 5.3.1 Usage 1035 This command is optional. 1037 Syntax 1038 LIST EXTENSIONS 1040 Responses 1041 202 Extension list follows (multiline) 1042 402 Server has no extensions 1044 5.3.2 Description 1046 The LIST EXTENSIONS command allows a client to determine which 1047 extensions are supported by the server at any given time. See Section 1048 8 for further discussion of extensions. 1050 This command MUST be implemented by any server that implements any 1051 extensions defined in this document or any other extension in the 1052 IANA registry, and is optional otherwise. 1054 This command MAY be issued at anytime during a session. It is not 1055 required that the client issues this command before attempting to 1056 make use of any extension. The response generated by this command MAY 1057 change during a session because of other state information (which in 1058 turn may be changed by the effects of other commands). An NNTP client 1059 is only able to get the current and correct information concerning 1060 available extensions at any point during a session by issuing a LIST 1061 EXTENSIONS command at that point of that session and processing the 1062 response, and the server MUST ensure that those extensions currently 1063 listed in the returned information are available. Therefore, if an 1064 extension (including those in Section 8) is only available before or 1065 after a MODE READER command, the LIST EXTENSIONS command MUST only 1066 include the extension in that situation. Similarly, if only some of 1067 the commands in an extension will be available, or if the behaviour 1068 of the extension will change in some other manner, before or after a 1069 MODE READER command, this MUST be indicated by different arguments to 1070 the extension-label in the results of LIST EXTENSIONS in each 1071 situation. 1073 While some extensions are likely to be always available or never 1074 available, others will "appear" and "disappear" depending on server 1075 state changes within the session or external events between sessions. 1076 An NNTP client MAY cache the results of this command, but MUST NOT 1077 rely on the correctness of any cached results, whether from earlier 1078 in this session or from a previous session, MUST cope gracefully with 1079 the cached status being out of date, and SHOULD (if caching results) 1080 provide a way to force the cached information to be refreshed. 1081 Furthermore, a client MUST NOT use cached results in relation to 1082 security, privacy, and authentication extensions. See Section 11.6 1083 for further discussion of this topic. 1085 The list of extensions is returned as a multi-line response following 1086 the 202 response code. Each extension is listed on a separate line; 1087 the line MUST begin with an extension-label and optionally one or 1088 more arguments (separated by one or more spaces). The extension-label 1089 and the meaning of the arguments are specified as part of the 1090 definition of the extension. The extension-label is a string of 1 to 1091 12 US-ASCII letters and MUST be in uppercase. Arguments are strings 1092 of 1 or more printable UTF-8 characters (that is, either printable 1093 US-ASCII characters or any UTF-8 sequence outside the US-ASCII range, 1094 but not space or TAB). 1096 The server MUST NOT list the same extension twice in the response, 1097 and MUST list all supported extensions. The order in which the 1098 extensions are listed is not significant. The server need not even 1099 consistently return the same order. If the server does not support 1100 any extensions, it MUST return an empty list. The 402 response code 1101 is documented for historic reasons only; clients SHOULD handle it 1102 gracefully, but servers MUST NOT generate it. 1104 Following a generic failure response, such as 403, an extension might 1105 still be available, and the client MAY attempt to use it. 1107 5.3.3 Examples 1109 Example of a successful response: 1111 [C] LIST EXTENSIONS 1112 [S] 202 Extensions supported: 1113 [S] OVER MSGID 1114 [S] HDR 1115 [S] LISTGROUP 1116 [S] . 1118 The particular extensions shown here are simply examples of what 1119 might be defined in other places, and no particular meaning should be 1120 attributed to them. 1122 Example where no extensions are available: 1124 [C] LIST EXTENSIONS 1125 [S] 202 Extensions supported: 1127 [S] . 1129 Example from a non-conforming server which indicates "no extensions 1130 available" using the 402 response code: 1132 [C] LIST EXTENSIONS 1133 [S] 402 Server has no extensions 1135 5.4 QUIT 1137 5.4.1 Usage 1139 Syntax 1140 QUIT 1142 Responses 1143 205 Connection closing 1145 5.4.2 Description 1147 The client uses the QUIT command to terminate the session. The server 1148 MUST acknowledge the QUIT command and then close the connection to 1149 the client. This is the preferred method for a client to indicate 1150 that it has finished all its transactions with the NNTP server. 1152 If a client simply disconnects (or the connection times out or some 1153 other fault occurs), the server MUST gracefully cease its attempts to 1154 service the client, disconnecting from its end if necessary. 1156 5.4.3 Examples 1158 [C] QUIT 1159 [S] 205 closing connection 1160 [Server closes connection.] 1162 6. Article posting and retrieval 1164 News reading clients have available a variety of mechanisms to 1165 retrieve articles via NNTP. The news articles are stored and indexed 1166 using three types of keys. One key is the message-id of an article. 1167 Another key is composed of the newsgroup name and the article number 1168 within that newsgroup. That key MUST be unique to a particular server 1169 (there will be only one article with that number within a particular 1170 newsgroup), but is not required to be globally unique. Additionally, 1171 because the same article can be cross-posted to multiple newsgroups, 1172 there may be multiple keys that point to the same article on the same 1173 server. The final key is the arrival timestamp, giving the time that 1174 the article arrived at the server. 1176 The server MUST ensure that article numbers are issued in order of 1177 arrival timestamp; that is, articles arriving later MUST have higher 1178 numbers than those that arrive earlier. The server SHOULD allocate 1179 the next sequential unused number to each new article. 1181 Article numbers MUST lie between 1 and 4,294,967,295 inclusive. The 1182 client and server MAY use leading zeroes in specifying article 1183 numbers, but MUST NOT use more than 16 digits. In some situations, 1184 the value zero replaces an article number to show some special 1185 situation. 1187 6.1 Group and article selection 1189 The following commands are used to set the "current selected 1190 newsgroup" and the "current article number", which are used by 1191 various commands. At the start of an NNTP session, both of these 1192 values are set to the special value "invalid". 1194 6.1.1 GROUP 1196 6.1.1.1 Usage 1198 Syntax 1199 GROUP group 1201 Responses 1202 211 number low high group Group successfully selected 1203 411 No such newsgroup 1205 Parameters 1206 group = name of newsgroup 1207 number = estimated number of articles in the group 1208 low = reported low water mark 1209 high = reported high water mark 1211 6.1.1.2 Description 1213 The required argument is the name of the newsgroup to be selected 1214 (e.g. "news.software.b"). A list of valid newsgroups may be obtained 1215 by using the LIST ACTIVE command (see Section 7.6.1). 1217 The successful selection response will return the article numbers of 1218 the first and last articles in the group at the moment of selection 1219 (these numbers are referred to as the "reported low water mark" and 1220 the "reported high water mark"), and an estimate of the number of 1221 articles in the group currently available. 1223 If the group is not empty, the estimate MUST be at least the actual 1224 number of articles available, and MUST be no greater than one more 1225 than the difference between the reported low and high water marks. 1226 (Some implementations will actually count the number of articles 1227 currently stored. Others will just subtract the low water mark from 1228 the high water mark and add one to get an estimate.) 1230 If the group is empty, one of the following three situations will 1231 occur. Clients MUST accept all three cases; servers MUST NOT 1232 represent an empty group in any other way. 1234 o The high water mark will be one less than the low water mark, and 1235 the estimated article count will be zero. Servers SHOULD use this 1236 method to show an empty group. This is the only time that the high 1237 water mark can be less than the low water mark. 1239 o All three numbers will be zero. 1241 o The high water mark is greater than or equal to the low water 1242 mark. The estimated article count might be zero or non-zero; if 1243 non-zero, the same requirements apply as for a non-empty group. 1245 The set of articles in a group may change after the GROUP command is 1246 carried out. That is: 1248 o articles may be removed from the group 1250 o articles may be reinstated in the group with the same article 1251 number, but those articles MUST have numbers no less than the 1252 reported low water mark (note that this is a reinstatement of the 1253 previous article, not a new article reusing the number) 1255 o new articles may be added with article numbers greater than the 1256 reported high water mark (if an article that was the one with the 1257 highest number has been removed and the high water mark adjusted 1258 accordingly, the next new article will not have the number one 1259 greater than the reported high water mark) 1261 Except when the group is empty and all three numbers are zero, 1262 whenever a subsequent GROUP command for the same newsgroup is issued, 1263 either by the same client or a different client, the reported low 1264 water mark in the response MUST be no less than that in any previous 1265 response for that newsgroup in any session, and SHOULD be no less 1266 than that in any previous response for that newsgroup ever sent to 1267 any client. Any failure to meet the latter condition SHOULD be 1268 transient only. The client may make use of the low water mark to 1269 remove all remembered information about articles with lower numbers, 1270 as these will never recur. This includes the situation when the high 1271 water mark is one less than the low water mark. No similar assumption 1272 can be made about the high water mark, as this can decrease if an 1273 article is removed, and then increase again if it is reinstated or if 1274 new articles arrive. 1276 When a valid group is selected by means of this command, the current 1277 selected newsgroup MUST be set to that group and the current article 1278 number MUST be set to the first article in the group. If an empty 1279 newsgroup is selected, the current article pointer is made invalid. 1280 If an invalid group is specified, the current selected newsgroup and 1281 current article number MUST NOT be changed. 1283 The GROUP command (or the LISTGROUP command, if implemented) MUST be 1284 used by a client and a successful response received before any other 1285 command is used that depends on the value of the current selected 1286 newsgroup or current article number. 1288 If the group specified is not available on the server, a 411 response 1289 MUST be returned. 1291 6.1.1.3 Examples 1293 Example for a group known to the server: 1295 [C] GROUP misc.test 1296 [S] 211 1234 3000234 3002322 misc.test 1298 Example for a group unknown to the server: 1300 [C] GROUP example.is.sob.bradner.or.barber 1301 [S] 411 example.is.sob.bradner.or.barber is unknown 1303 Example of an empty group using the preferred response: 1305 [C] GROUP example.currently.empty.newsgroup 1306 [S] 211 0 4000 3999 example.currently.empty.newsgroup 1308 Example of an empty group using an alternative response: 1310 [C] GROUP example.currently.empty.newsgroup 1311 [S] 211 0 0 0 example.currently.empty.newsgroup 1313 Example of an empty group using a different alternative response: 1315 [C] GROUP example.currently.empty.newsgroup 1316 [S] 211 0 4000 4321 example.currently.empty.newsgroup 1318 6.1.2 LAST 1320 6.1.2.1 Usage 1322 Syntax 1323 LAST 1325 Responses 1326 223 n message-id Article found 1327 412 No newsgroup selected 1328 420 Current article number is invalid 1329 422 No previous article in this group 1331 Parameters 1332 n = article number 1333 message-id = article message-id 1335 6.1.2.2 Description 1337 If the current selected newsgroup is valid, the current article 1338 number MUST be set to the previous article in that newsgroup (that 1339 is, the highest existing article number less than the current article 1340 number). If successful, a response indicating the new current article 1341 number and the message-id of that article MUST be returned. No 1342 article text is sent in response to this command. 1344 There MAY be no previous article in the group, although the current 1345 article number is not the reported low water mark. There MUST NOT be 1346 a previous article when the current article number is the reported 1347 low water mark. 1349 Because articles can be removed and added, the results of multiple 1350 LAST and NEXT commands MAY not be consistent over the life of a 1351 particular NNTP session. 1353 If the current article number is already the first article of the 1354 newsgroup, a 422 response MUST be returned. If the current article 1355 number is invalid, a 420 response MUST be returned. If the current 1356 selected newsgroup is invalid, a 412 response MUST be returned. In 1357 all three cases the current selected newsgroup and current article 1358 number MUST NOT be altered. 1360 6.1.2.3 Examples 1362 Example of a successful article retrieval using LAST: 1364 [C] GROUP misc.test 1365 [S] 211 1234 3000234 3002322 misc.test 1366 [C] NEXT 1367 [S] 223 3000237 <668929@example.org> retrieved 1368 [C] LAST 1369 [S] 223 3000234 <45223423@example.com> retrieved 1371 Example of an attempt to retrieve an article without having selected 1372 a group (via the GROUP command) first: 1374 [Assumes current selected newsgroup is invalid.] 1375 [C] LAST 1376 [S] 412 no newsgroup selected 1378 Example of an attempt to retrieve an article using the LAST command 1379 when the current article number is that of the first article in the 1380 group: 1382 [C] GROUP misc.test 1383 [S] 211 1234 3000234 3002322 misc.test 1384 [C] LAST 1385 [S] 422 No previous article to retrieve 1387 Example of an attempt to retrieve an article using the LAST command 1388 when the current selected newsgroup is empty: 1390 [C] GROUP example.empty.newsgroup 1391 [S] 211 0 0 0 example.empty.newsgroup 1392 [C] LAST 1393 [S] 420 No current article selected 1395 6.1.3 NEXT 1397 6.1.3.1 Usage 1398 Syntax 1399 NEXT 1401 Responses 1402 223 n message-id Article found 1403 412 No newsgroup selected 1404 420 Current article number is invalid 1405 421 No next article in this group 1407 Parameters 1408 n = article number 1409 message-id = article message-id 1411 6.1.3.2 Description 1413 If the current selected newsgroup is valid, the current article 1414 number MUST be set to the next article in that newsgroup (that is, 1415 the lowest existing article number greater than the current article 1416 number). If successful, a response indicating the new current article 1417 number and the message-id of that article MUST be returned. No 1418 article text is sent in response to this command. 1420 If the current article number is already the last article of the 1421 newsgroup, a 421 response MUST be returned. In all other aspects 1422 (apart, of course, from the lack of 422 response) this command is 1423 identical to the LAST command (Section 6.1.2). 1425 6.1.3.3 Examples 1427 Example of a successful article retrieval using NEXT: 1429 [C] GROUP misc.test 1430 [S] 211 1234 3000234 3002322 misc.test 1431 [C] NEXT 1432 [S] 223 3000237 <668929@example.org> retrieved 1434 Example of an attempt to retrieve an article without having selected 1435 a group (via the GROUP command) first: 1437 [Assumes current selected newsgroup is invalid.] 1438 [C] NEXT 1439 [S] 412 no newsgroup selected 1441 Example of an attempt to retrieve an article using the NEXT command 1442 when the current article number is that of the last article in the 1443 group: 1445 [C] GROUP misc.test 1446 [S] 211 1234 3000234 3002322 misc.test 1447 [C] STAT 3002322 1448 [S] 223 3002322 <411@example.net> retrieved 1449 [C] NEXT 1450 [S] 421 No next article to retrieve 1452 Example of an attempt to retrieve an article using the NEXT command 1453 when the current selected newsgroup is empty: 1455 [C] GROUP example.empty.newsgroup 1456 [S] 211 0 0 0 example.empty.newsgroup 1457 [C] NEXT 1458 [S] 420 No current article selected 1460 6.2 Retrieval of articles and article sections 1462 The ARTICLE, BODY, HEAD, and STAT commands are very similar. They 1463 differ only in the parts of the article that are presented to the 1464 client and in the successful response code. The ARTICLE command is 1465 described here in full, while the other commands are described in 1466 terms of the differences. As specified in Section 3.4, an article 1467 consists of two parts: the article headers and the article body. When 1468 responding to one of these commands, the server MUST present the 1469 entire article or appropriate part and MUST NOT attempt to alter or 1470 translate it in any way. 1472 6.2.1 ARTICLE 1474 6.2.1.1 Usage 1476 Syntax 1477 ARTICLE message-id 1478 ARTICLE number 1479 ARTICLE 1481 Responses 1483 First form (message-id specified) 1484 220 0|n message-id Article follows (multiline) 1485 430 No article with that message-id 1487 Second form (article number specified) 1488 220 n message-id Article follows (multiline) 1489 412 No newsgroup selected 1490 423 No articles in that range 1492 Third form (current article number used) 1493 220 n message-id Article follows (multiline) 1494 412 No newsgroup selected 1495 420 Current article number is invalid 1497 Parameters 1498 number = Requested article number 1499 n = Returned article number 1500 message-id = Article message-id 1502 6.2.1.2 Description 1504 The ARTICLE command selects an article based on the arguments and 1505 presents the entire article (that is, the headers, an empty line, and 1506 the body in that order). The command has three forms. 1508 In the first form, a message-id is specified and the server presents 1509 the article with that message-id. In this case, the server MUST NOT 1510 alter the current selected newsgroup or current article number. This 1511 is both to facilitate the presentation of articles that may be 1512 referenced within another article being read, and because of the 1513 semantic difficulties of determining the proper sequence and 1514 membership of an article that may have been cross-posted to more than 1515 one newsgroup. 1517 In the response, the article number MUST be replaced with zero, 1518 except that if there is a current selected group and the article is 1519 present in that group, the server MAY use that article number. (The 1520 server is not required to determine whether the article is in the 1521 current selected newsgroup or, if so, what article number it has; the 1522 client MUST always be prepared for zero to be specified.) The server 1523 MUST NOT provide an article number unless use of that number in a 1524 second ARTICLE command immediately following this one would return 1525 the same article. Even if the server chooses to return article 1526 numbers in these circumstances, it need not do so consistently; it 1527 MAY return zero to any such command (also see the STAT examples 1528 (Section 6.2.4.3)). 1530 In the second form, an article number is specified. If there is an 1531 article with that number in the current selected newsgroup, the 1532 server MUST set the current article number to that number. 1534 In the third form, the article indicated by the current article 1535 number in the current selected newsgroup is used. 1537 Note that a previously valid article number MAY become invalid if the 1538 article has been removed. A previously invalid article number MAY 1539 become valid if the article has been reinstated, but such an article 1540 number MUST be no less than the reported low water mark for that 1541 group. 1543 The server MUST NOT change the current selected newsgroup as a result 1544 of this command. The server MUST NOT change the current article 1545 number except when an article number argument was provided and the 1546 article exists; in particular, it MUST NOT change it following an 1547 unsuccessful response. 1549 Since the message-id is unique for each article, it may be used by a 1550 client to skip duplicate displays of articles that have been posted 1551 more than once, or to more than one newsgroup. 1553 The article is returned as a multi-line response following the 220 1554 response code. 1556 If the argument is a message-id and no such article exists, a 430 1557 response MUST be returned. If the argument is a number or is omitted 1558 and the current selected newsgroup is invalid, a 412 response MUST be 1559 returned. If the argument is a number and that article does not exist 1560 in the current selected newsgroup, a 423 response MUST be returned. 1561 If the argument is omitted and the current article number is invalid, 1562 a 420 response MUST be returned. 1564 6.2.1.3 Examples 1566 Example of a successful retrieval of an article (using no article 1567 number): 1569 [C] GROUP misc.test 1570 [S] 211 1234 3000234 3002322 misc.test 1571 [C] ARTICLE 1572 [S] 220 3000234 <45223423@example.com> 1573 [S] Path: pathost!demo!whitehouse!not-for-mail 1574 [S] From: "Demo User" 1575 [S] Newsgroups: misc.test 1576 [S] Subject: I am just a test article 1577 [S] Date: 6 Oct 1998 04:38:40 -0500 1578 [S] Organization: An Example Net, Uncertain, Texas 1579 [S] Message-ID: <411@example.net> 1580 [S] 1581 [S] This is just a test article. 1582 [S] . 1584 Example of a successful retrieval of an article by message-id: 1586 [C] ARTICLE <45223423@example.com> 1588 [S] 220 0 <45223423@example.com> 1589 [S] Path: pathost!demo!whitehouse!not-for-mail 1590 [S] From: "Demo User" 1591 [S] Newsgroups: misc.test 1592 [S] Subject: I am just a test article 1593 [S] Date: 6 Oct 1998 04:38:40 -0500 1594 [S] Organization: An Example Net, Uncertain, Texas 1595 [S] Message-ID: <411@example.net> 1596 [S] 1597 [S] This is just a test article. 1598 [S] . 1600 Example of an unsuccessful retrieval of an article by message-id: 1602 [C] ARTICLE 1603 [S] 430 No Such Article Found 1605 Example of an unsuccessful retrieval of an article by number: 1607 [C] GROUP misc.test 1608 [S] 211 1234 3000234 3002322 news.groups 1609 [C] ARTICLE 300256 1610 [S] 423 No such article number in this group 1612 Example of an unsuccessful retrieval of an article by number because 1613 no newsgroup was selected first: 1615 [Assumes current selected newsgroup is invalid.] 1616 [C] ARTICLE 300256 1617 [S] 412 No newsgroup selected 1619 Example of an attempt to retrieve an article when the current 1620 selected newsgroup is empty: 1622 [C] GROUP example.empty.newsgroup 1623 [S] 211 0 0 0 example.empty.newsgroup 1624 [C] ARTICLE 1625 [S] 420 No current article selected 1627 6.2.2 HEAD 1629 6.2.2.1 Usage 1631 Syntax 1632 HEAD message-id 1633 HEAD number 1634 HEAD 1636 Responses 1638 First form (message-id specified) 1639 221 0|n message-id Headers follow (multiline) 1640 430 No article with that message-id 1642 Second form (article number specified) 1643 221 n message-id Headers follow (multiline) 1644 412 No newsgroup selected 1645 423 No articles in that range 1647 Third form (current article number used) 1648 221 n message-id Headers follow (multiline) 1649 412 No newsgroup selected 1650 420 Current article number is invalid 1652 Parameters 1653 number = Requested article number 1654 n = Returned article number 1655 message-id = Article message-id 1657 6.2.2.2 Description 1659 The HEAD command behaves identically to the ARTICLE command except 1660 that, if the article exists, the response code is 221 instead of 220 1661 and only the headers are presented (the empty line separating the 1662 headers and body MUST NOT be included). 1664 6.2.2.3 Examples 1666 Example of a successful retrieval of the headers of an article (using 1667 no article number): 1669 [C] GROUP misc.test 1670 [S] 211 1234 3000234 3002322 misc.test 1671 [C] HEAD 1672 [S] 221 3000234 <45223423@example.com> 1673 [S] Path: pathost!demo!whitehouse!not-for-mail 1674 [S] From: "Demo User" 1675 [S] Newsgroups: misc.test 1676 [S] Subject: I am just a test article 1677 [S] Date: 6 Oct 1998 04:38:40 -0500 1678 [S] Organization: An Example Net, Uncertain, Texas 1679 [S] Message-ID: <411@example.net> 1680 [S] . 1682 Example of a successful retrieval of the headers of an article by 1683 message-id: 1685 [C] HEAD <45223423@example.com> 1686 [S] 221 0 <45223423@example.com> 1687 [S] Path: pathost!demo!whitehouse!not-for-mail 1688 [S] From: "Demo User" 1689 [S] Newsgroups: misc.test 1690 [S] Subject: I am just a test article 1691 [S] Date: 6 Oct 1998 04:38:40 -0500 1692 [S] Organization: An Example Net, Uncertain, Texas 1693 [S] Message-ID: <411@example.net> 1694 [S] . 1696 Example of an unsuccessful retrieval of the headers of an article by 1697 message-id: 1699 [C] HEAD 1700 [S] 430 No Such Article Found 1702 Example of an unsuccessful retrieval of the headers of an article by 1703 number: 1705 [C] GROUP misc.test 1706 [S] 211 1234 3000234 3002322 misc.test 1707 [C] HEAD 300256 1708 [S] 423 No such article number in this group 1710 Example of an unsuccessful retrieval of the headers of an article by 1711 number because no newsgroup was selected first: 1713 [Assumes current selected newsgroup is invalid.] 1714 [C] HEAD 300256 1715 [S] 412 No newsgroup selected 1717 Example of an attempt to retrieve the headers of an article when the 1718 current selected newsgroup is empty: 1720 [C] GROUP example.empty.newsgroup 1721 [S] 211 0 0 0 example.empty.newsgroup 1722 [C] HEAD 1723 [S] 420 No current article selected 1725 6.2.3 BODY 1727 6.2.3.1 Usage 1728 Syntax 1729 BODY message-id 1730 BODY number 1731 BODY 1733 Responses 1735 First form (message-id specified) 1736 222 0|n message-id Body follows (multiline) 1737 430 No article with that message-id 1739 Second form (article number specified) 1740 222 n message-id Body follows (multiline) 1741 412 No newsgroup selected 1742 423 No articles in that range 1744 Third form (current article number used) 1745 222 n message-id Body follows (multiline) 1746 412 No newsgroup selected 1747 420 Current article number is invalid 1749 Parameters 1750 number = Requested article number 1751 n = Returned article number 1752 message-id = Article message-id 1754 6.2.3.2 Description 1756 The BODY command behaves identically to the ARTICLE command except 1757 that, if the article exists, the response code is 222 instead of 220 1758 and only the body is presented (the empty line separating the headers 1759 and body MUST NOT be included). 1761 6.2.3.3 Examples 1763 Example of a successful retrieval of the body of an article (using no 1764 article number): 1766 [C] GROUP misc.test 1767 [S] 211 1234 3000234 3002322 misc.test 1768 [C] BODY 1769 [S] 222 3000234 <45223423@example.com> 1770 [S] This is just a test article. 1771 [S] . 1773 Example of a successful retrieval of the body of an article by 1774 message-id: 1776 [C] BODY <45223423@example.com> 1777 [S] 222 0 <45223423@example.com> 1778 [S] This is just a test article. 1779 [S] . 1781 Example of an unsuccessful retrieval of the body of an article by 1782 message-id: 1784 [C] BODY 1785 [S] 430 No Such Article Found 1787 Example of an unsuccessful retrieval of the body of an article by 1788 number: 1790 [C] GROUP misc.test 1791 [S] 211 1234 3000234 3002322 misc.test 1792 [C] BODY 300256 1793 [S] 423 No such article number in this group 1795 Example of an unsuccessful retrieval of the body of an article by 1796 number because no newsgroup was selected first: 1798 [Assumes current selected newsgroup is invalid.] 1799 [C] BODY 300256 1800 [S] 412 No newsgroup selected 1802 Example of an attempt to retrieve the body of an article when the 1803 current selected newsgroup is empty: 1805 [C] GROUP example.empty.newsgroup 1806 [S] 211 0 0 0 example.empty.newsgroup 1807 [C] BODY 1808 [S] 420 No current article selected 1810 6.2.4 STAT 1812 6.2.4.1 Usage 1814 Syntax 1815 STAT message-id 1816 STAT number 1817 STAT 1819 Responses 1820 First form (message-id specified) 1821 223 0|n message-id Article exists 1822 430 No article with that message-id 1824 Second form (article number specified) 1825 223 n message-id Article exists 1826 412 No newsgroup selected 1827 423 No articles in that range 1829 Third form (current article number used) 1830 223 n message-id Article exists 1831 412 No newsgroup selected 1832 420 Current article number is invalid 1834 Parameters 1835 number = Requested article number 1836 n = Returned article number 1837 message-id = Article message-id 1839 6.2.4.2 Description 1841 The STAT command behaves identically to the ARTICLE command except 1842 that, if the article exists, it is NOT presented to the client and 1843 the response code is 223 instead of 220. Note that the response is 1844 NOT multi-line. 1846 This command allows the client to determine whether an article 1847 exists, and in the second and third forms what its message-id is, 1848 without having to process an arbitrary amount of text. 1850 6.2.4.3 Examples 1852 Example of STAT on an existing article (using no article number): 1854 [C] GROUP misc.test 1855 [S] 211 1234 3000234 3002322 misc.test 1856 [C] STAT 1857 [S] 223 3000234 <45223423@example.com> 1859 Example of STAT on an existing article by message-id: 1861 [C] STAT <45223423@example.com> 1862 [S] 223 0 <45223423@example.com> 1864 Example of STAT on an article not on the server by message-id: 1866 [C] STAT 1868 [S] 430 No Such Article Found 1870 Example of STAT on an article not in the server by number: 1872 [C] GROUP misc.test 1873 [S] 211 1234 3000234 3002322 misc.test 1874 [C] STAT 300256 1875 [S] 423 No such article number in this group 1877 Example of STAT on an article by number when no newsgroup was 1878 selected first: 1880 [Assumes current selected newsgroup is invalid.] 1881 [C] STAT 300256 1882 [S] 412 No newsgroup selected 1884 Example of STAT on an article when the current selected newsgroup is 1885 empty: 1887 [C] GROUP example.empty.newsgroup 1888 [S] 211 0 0 0 example.empty.newsgroup 1889 [C] STAT 1890 [S] 420 No current article selected 1892 Example of STAT by message-id on a server which sometimes reports the 1893 actual article number: 1895 [C] GROUP misc.test 1896 [S] 211 1234 3000234 3002322 misc.test 1897 [C] STAT 1898 [S] 223 3000234 <45223423@example.com> 1899 [C] STAT <45223423@example.com> 1900 [S] 223 0 <45223423@example.com> 1901 [C] STAT <45223423@example.com> 1902 [S] 223 3000234 <45223423@example.com> 1903 [C] GROUP example.empty.newsgroup 1904 [S] 211 0 0 0 example.empty.newsgroup 1905 [C] STAT <45223423@example.com> 1906 [S] 223 0 <45223423@example.com> 1907 [C] GROUP alt.crossposts 1908 [S] 211 9999 111111 222222 alt.crossposts 1909 [C] STAT <45223423@example.com> 1910 [S] 223 123456 <45223423@example.com> 1911 [C] STAT 1912 [S] 223 111111 <23894720@example.com> 1914 The first STAT command establishes the identity of an article in the 1915 group. The second and third show that the server may, but need not, 1916 give the article number when the message-id is specified. The fourth 1917 STAT command shows that zero must be specified if the article isn't 1918 in the current selected group, the fifth shows that the number, if 1919 provided, must be that relating to the current selected group, and 1920 the last one shows that the current selected article is still not 1921 changed by the use of STAT with a message-id even if it returns an 1922 article number. 1924 6.3 Article posting 1926 Article posting is done in one of two modes: individual article 1927 posting from news reading clients using POST, and article transfer 1928 from other news servers using IHAVE. 1930 6.3.1 POST 1932 6.3.1.1 Usage 1934 This command MUST NOT be pipelined. 1936 Syntax 1937 POST 1939 Responses 1941 Initial responses 1942 340 Send article to be posted 1943 440 Posting not permitted 1945 Subsequent responses 1946 240 Article received OK 1947 441 Posting failed 1949 6.3.1.2 Description 1951 If posting is allowed, a 340 response MUST be returned to indicate 1952 that the article to be posted should be sent. If posting is 1953 prohibited for some installation-dependent reason, a 440 response 1954 MUST be returned. 1956 If posting is permitted, the article MUST be in the format specified 1957 in Section 3.4 and MUST be sent by the client to the server in the 1958 manner specified (in Section 3.1) for multi-line responses (except 1959 that there is no initial line containing a response code). Thus a 1960 single dot (".") on a line indicates the end of the text, and lines 1961 starting with a dot in the original text have that dot doubled during 1962 transmission. 1964 Following the presentation of the termination sequence by the client, 1965 the server MUST return a response indicating success or failure of 1966 the article transfer. Note that response codes 340 and 440 are used 1967 in direct response to the POST command. Others are returned following 1968 the sending of the article. 1970 A response of 240 SHOULD indicate that, barring unforeseen server 1971 errors, the posted article will be made available on the server and/ 1972 or transferred to other servers as appropriate, possibly following 1973 further processing. In other words, articles not wanted by the server 1974 SHOULD be rejected with a 441 response and not accepted and silently 1975 discarded. However, the client SHOULD NOT assume that the article has 1976 been successfully transferred unless it receives an affirmative 1977 response from the server, and SHOULD NOT assume that it is being made 1978 available to other clients without explicitly checking (for example 1979 using the STAT command). 1981 If the session is interrupted before the response is received, it is 1982 possible that an affirmative response was sent but has been lost. 1983 Therefore, in any subsequent session, the client SHOULD either check 1984 whether the article was successfully posted before resending or 1985 ensure that the server will allocate the same message-id to the new 1986 attempt (see Appendix B.2) - the latter approach is preferred since 1987 the article might not have been made available for reading yet (for 1988 example, it may have to go through a moderation process). 1990 6.3.1.3 Examples 1992 Example of a successful posting: 1994 [C] POST 1995 [S] 340 Input article; end with . 1996 [C] From: "Demo User" 1997 [C] Newsgroups: misc.test 1998 [C] Subject: I am just a test article 1999 [C] Organization: An Example Net 2000 [C] 2001 [C] This is just a test article. 2002 [C] . 2003 [S] 240 Article received OK 2005 Example of an unsuccessful posting: 2007 [C] POST 2008 [S] 340 Input article; end with . 2009 [C] From: "Demo User" 2010 [C] Newsgroups: misc.test 2011 [C] Subject: I am just a test article 2013 [C] Organization: An Example Net 2014 [C] 2015 [C] This is just a test article. 2016 [C] . 2017 [S] 441 Posting failed 2019 Example of an attempt to post when posting is not allowed: 2021 [C] MODE READER 2022 [S] 201 NNTP Service Ready, posting prohibited 2023 [C] POST 2024 [S] 440 Posting not permitted 2026 6.3.2 IHAVE 2028 6.3.2.1 Usage 2030 This command MUST NOT be pipelined. 2032 Syntax 2033 IHAVE message-id 2035 Responses 2037 Initial responses 2038 335 Send article to be transferred 2039 435 Article not wanted 2040 436 Transfer not possible; try again later 2042 Subsequent responses 2043 235 Article transferred OK 2044 436 Transfer failed; try again later 2045 437 Transfer rejected; do not retry 2047 Parameters 2048 message-id = Article message-id 2050 6.3.2.2 Description 2052 The IHAVE command informs the server that the client has an article 2053 with the specified message-id. If the server desires a copy of that 2054 article a 335 response MUST be returned, instructing the client to 2055 send the entire article. If the server does not want the article (if, 2056 for example, the server already has a copy of it), a 435 response 2057 MUST be returned, indicating that the article is not wanted. Finally, 2058 if the article isn't wanted immediately but the client should retry 2059 later if possible (if, for example, another client is in the process 2060 of sending the same article to the server), a 436 response MUST be 2061 returned. 2063 If transmission of the article is requested, the client MUST send the 2064 entire article, including headers and body, in the format defined 2065 above (Section 3.1) for multi-line responses (except that there is no 2066 initial line containing a response code). Thus a single dot (".") on 2067 a line indicates the end of the text, and lines starting with a dot 2068 in the original text have that dot doubled during transmission. The 2069 server MUST return either a 235 response, indicating that the article 2070 was successfully transferred, a 436 response, indicating that the 2071 transfer failed but should be tried again later, or a 437 response, 2072 indicating that the article was rejected. 2074 This function differs from the POST command in that it is intended 2075 for use in transferring already-posted articles between hosts. It 2076 SHOULD NOT be used when the client is a personal news reading 2077 program, since use of this command indicates that the article has 2078 already been posted at another site and is simply being forwarded 2079 from another host. However, despite this, the server MAY elect not to 2080 post or forward the article if, after further examination of the 2081 article, it deems it inappropriate to do so. Reasons for such 2082 subsequent rejection of an article may include such problems as 2083 inappropriate newsgroups or distributions, disc space limitations, 2084 article lengths, garbled headers, and the like. These are typically 2085 restrictions enforced by the server host's news software and not 2086 necessarily the NNTP server itself. 2088 The client SHOULD NOT assume that the article has been successfully 2089 transferred unless it receives an affirmative response from the 2090 server. A lack of response (such as a dropped network connection or a 2091 network timeout) SHOULD be treated the same as a 436 response. 2093 Because some news server software may not be able immediately to 2094 determine whether or not an article is suitable for posting or 2095 forwarding, an NNTP server MAY acknowledge the successful transfer of 2096 the article (with a 235 response) but later silently discard it. 2098 6.3.2.3 Examples 2100 Example of successfully sending an article to another site: 2102 [C] IHAVE 2103 [S] 335 Send it; end with . 2104 [C] Path: pathost!demo!somewhere!not-for-mail 2105 [C] From: "Demo User" 2106 [C] Newsgroups: misc.test 2108 [C] Subject: I am just a test article 2109 [C] Date: 6 Oct 1998 04:38:40 -0500 2110 [C] Organization: An Example Com, San Jose, CA 2111 [C] Message-ID: 2112 [C] 2113 [C] This is just a test article. 2114 [C] . 2115 [S] 235 Article transferred OK 2117 Example of sending an article to another site that rejects it. Note 2118 that the message-id in the IHAVE command is not the same as the one 2119 in the article headers; while this is bad practice and SHOULD NOT be 2120 done, it is not forbidden. 2122 [C] IHAVE 2123 [S] 335 Send it; end with . 2124 [C] Path: pathost!demo!somewhere!not-for-mail 2125 [C] From: "Demo User" 2126 [C] Newsgroups: misc.test 2127 [C] Subject: I am just a test article 2128 [C] Date: 6 Oct 1998 04:38:40 -0500 2129 [C] Organization: An Example Com, San Jose, CA 2130 [C] Message-ID: 2131 [C] 2132 [C] This is just a test article. 2133 [C] . 2134 [S] 437 Article rejected; don't send again 2136 Example of sending an article to another site where the transfer 2137 fails: 2139 [C] IHAVE 2140 [S] 335 Send it; end with . 2141 [C] Path: pathost!demo!somewhere!not-for-mail 2142 [C] From: "Demo User" 2143 [C] Newsgroups: misc.test 2144 [C] Subject: I am just a test article 2145 [C] Date: 6 Oct 1998 04:38:40 -0500 2146 [C] Organization: An Example Com, San Jose, CA 2147 [C] Message-ID: 2148 [C] 2149 [C] This is just a test article. 2150 [C] . 2151 [S] 436 Transfer failed 2153 Example of sending an article to a site that already has it: 2155 [C] IHAVE 2157 [S] 435 Duplicate 2159 Example of sending an article to a site that requests the article be 2160 tried again later: 2162 [C] IHAVE 2163 [S] 436 Retry later 2165 7. Information commands 2167 This section lists other commands that may be used at any time 2168 between the beginning of a session and its termination. Using these 2169 commands does not alter any state information, but the response 2170 generated from their use may provide useful information to clients. 2172 7.1 DATE 2174 7.1.1 Usage 2176 Syntax 2177 DATE 2179 Responses 2180 111 yyyymmddhhmmss server date and time 2182 Parameters 2183 yyyymmddHHmmss = Current UTC date and time on server 2185 7.1.2 Description 2187 This command exists to help clients find out the current Coordinated 2188 Universal Time [TF.686-1] from the server's perspective. This command 2189 SHOULD NOT be used as a substitute for NTP [RFC1305] but to provide 2190 information that might be useful when using the NEWNEWS command (see 2191 Section 7.4). A system providing NNTP service SHOULD keep the system 2192 clock as accurate as possible, either with NTP or by some other 2193 method. 2195 The server MUST return a 111 response specifying the date and time on 2196 the server in the form yyyymmddhhmmss. This date and time is in 2197 Coordinated Universal Time. 2199 7.1.3 Examples 2201 [C] DATE 2202 [S] 111 19990623135624 2204 7.2 HELP 2206 7.2.1 Usage 2207 Syntax 2208 HELP 2210 Responses 2211 100 Help text follows (multiline) 2213 7.2.2 Description 2215 This command provides a short summary of commands that are understood 2216 by this implementation of the server. The help text will be presented 2217 as a multiline response following the 100 response code. 2219 This text is not guaranteed to be in any particular format and MUST 2220 NOT be used by clients as a replacement for the LIST EXTENSIONS 2221 command described in Section 5.3 2223 7.2.3 Examples 2225 [C] HELP 2226 [S] 100 Help text follows 2227 [S] This is some help text. There is no specific 2228 [S] formatting requirement for this test, though 2229 [S] it is customary for it to list the valid commands 2230 [S] and give a brief definition of what they do 2231 [S] . 2233 7.3 NEWGROUPS 2235 7.3.1 Usage 2237 Syntax 2238 NEWGROUPS date time [GMT] 2240 Responses 2241 231 List of new newsgroups follows (multiline) 2243 Parameters 2244 date = Date in yymmdd or yyyymmdd format 2245 time = Time in hhmmss format 2247 7.3.2 Description 2249 This command returns a list of newsgroups created on the server since 2250 the specified date and time. The results are in the same format as 2251 the LIST ACTIVE command (see Section 7.6.1). However, they MAY 2252 include groups not available on the server (and so not returned by 2253 LIST ACTIVE) and MAY omit groups for which the creation date is not 2254 available. The results SHOULD be consistent with those of the LIST 2255 ACTIVE.TIMES command (Section 7.6.2), except that if the specified 2256 date and time is earlier than the oldest entry in the latter then the 2257 results of this command may include extra groups. 2259 The date is specified as 6 or 8 digits in the format [xx]yymmdd, 2260 where xx is the first two digits of the year (19-99), yy is the last 2261 two digits of the year (00-99), mm is the month (01-12), and dd is 2262 the day of the month (01-31). Clients SHOULD specify all four digits 2263 of the year. If the first two digits of the year are not specified 2264 (this is supported only for backwards compatibility), the year is to 2265 be taken from the current century if yy is smaller than or equal to 2266 the current year, otherwise the year is from the previous century. 2268 The time is specified as 6 digits in the format hhmmss, where hh is 2269 the hours in the 24-hour clock (00-23), mm is the minutes (00-59), 2270 and ss is the seconds (00-60, to allow for leap seconds). The token 2271 "GMT" specifies that the date and time are given in Coordinated 2272 Universal Time [TF.686-1]; if it is omitted then the date and time 2273 are specified in the server's local timezone. Note that there is no 2274 way using the protocol specified in this document to establish the 2275 server's local timezone. 2277 Note that an empty list is a possible valid response and indicates 2278 that there are no new newsgroups since that date-time. 2280 Clients SHOULD make all queries using Coordinated Universal Time 2281 (i.e. by including the "GMT" argument) when possible. 2283 7.3.3 Examples 2285 Example where there are new groups: 2287 [C] NEWGROUPS 19990624 000000 GMT 2288 [S] 231 list of new newsgroups follows 2289 [S] alt.rfc-writers.recovery 4 1 y 2290 [S] tx.natives.recovery 89 56 y 2291 [S] . 2293 Example where there are no new groups: 2295 [C] NEWGROUPS 19990624 000000 GMT 2296 [S] 231 list of new newsgroups follows 2297 [S] . 2299 7.4 NEWNEWS 2301 7.4.1 Usage 2303 Syntax 2304 NEWNEWS wildmat date time [GMT] 2306 Responses 2307 230 List of new articles follows (multiline) 2309 Parameters 2310 wildmat = Newsgroups of interest 2311 date = Date in yymmdd or yyyymmdd format 2312 time = Time in hhmmss format 2314 7.4.2 Description 2316 This command returns a list of message-ids of articles posted or 2317 received on the server, in the newsgroups whose names match the 2318 wildmat, since the specified date and time. One message-id is sent on 2319 each line; the order of the response has no specific significance and 2320 may vary from response to response in the same session. A message-id 2321 MAY appear more than once; if it does so, it has the same meaning as 2322 if it appeared only once. 2324 Date and time are in the same format as the NEWGROUPS command (see 2325 Section 7.3). 2327 Note that an empty list is a possible valid response and indicates 2328 that there is currently no new news in the relevant groups. 2330 Clients SHOULD make all queries in Coordinated Universal Time (i.e. 2331 by using the "GMT" argument) when possible. 2333 7.4.3 Examples 2335 Example where there are new articles: 2337 [C] NEWNEWS news.*,sci.* 19990624 000000 GMT 2338 [S] 230 list of new articles by message-id follows 2339 [S] 2340 [S] 2341 [S] . 2343 Example where there are no new articles: 2345 [C] NEWNEWS alt.* 19990624 000000 GMT 2347 [S] 230 list of new articles by message-id follows 2348 [S] . 2350 7.5 Time 2352 As described in Section 6, each article has an arrival timestamp. 2353 Each newsgroup also has a creation timestamp. These timestamps are 2354 used by the NEWNEWS and NEWGROUP commands to construct their 2355 responses. 2357 The DATE command MUST return a timestamp from the same clock as is 2358 used for determining article arrival and group creation times. This 2359 clock SHOULD be monotonic, and adjustments SHOULD be made by running 2360 it fast or slow compared to "real" time rather than by making sudden 2361 jumps. 2363 Clients can ensure that they do not have gaps in lists of articles or 2364 groups by using the DATE command in the following manner: 2366 First session: 2367 Issue DATE command and record result 2368 Issue NEWNEWS command using a previously chosen timestamp 2370 Subsequent sessions: 2371 Issue DATE command and hold result in temporary storage 2372 Issue NEWNEWS command using timestamp saved from previous session 2373 Overwrite saved timestamp with that currently in temporary storage 2375 In order to allow for minor errors, clients MAY want to adjust the 2376 timestamp back by two or three minutes before using it in NEWNEWS. 2378 7.5.1 Examples 2380 First session: 2382 [C] DATE 2383 [S] 111 20010203112233 2384 [C] NEWNEWS local.chat 20001231 235959 GMT 2385 [S] 230 list follows 2386 [S] 2387 [S] 2388 [S] 2389 [S] . 2391 Second session (the client has subtracted 3 minutes from the 2392 timestamp returned previously): 2394 [C] DATE 2395 [S] 111 20010204003344 2396 [C] NEWNEWS local.chat 20010203 111933 GMT 2397 [S] 230 list follows 2398 [S] 2399 [S] 2400 [S] 2401 [S] . 2403 Note how arrived in the 3 minute gap and so 2404 is listed in both responses. 2406 7.6 The LIST commands 2408 7.6.1 LIST ACTIVE 2410 7.6.1.1 Usage 2412 Syntax 2413 LIST ACTIVE [wildmat] 2415 Responses 2416 215 Information follows (multiline) 2418 Parameters 2419 wildmat = groups of interest 2421 7.6.1.2 Description 2423 The LIST ACTIVE command with no arguments returns a list of valid 2424 newsgroups and associated information. The server MUST include every 2425 group that the client is permitted to select with the GROUP (Section 2426 6.1.1) command. Each newsgroup is sent as a line of text in the 2427 following format: 2429 group high low status 2431 where: 2433 "group" is the name of the newsgroup; 2435 "high" is the reported high water mark for the group; 2437 "low" is the reported low water mark for the group; 2438 "status" is the current status of the group on this server. 2440 Each field in the line is separated from its neighbouring fields by 2441 one or more spaces. 2443 Note that an empty list is a possible valid response, and indicates 2444 that there are currently no valid newsgroups. 2446 The reported high and low water marks are as described in the GROUP 2447 command (see Section 6.1.1). 2449 The status field is typically one of: 2451 "y" posting is permitted 2453 "n" posting is not permitted 2455 "m" postings will be forwarded to the newsgroup moderator 2457 The server SHOULD use these values when these meanings are required 2458 and MUST NOT use them with any other meaning. Other values for the 2459 status may exist; the definition of these other values and the 2460 circumstances under which they are returned may be specified in an 2461 extension or may be private to the server. A client SHOULD treat an 2462 unrecognized status as giving no information. 2464 The status of a newsgroup only indicates how posts to that newsgroup 2465 are normally processed and is not necessarily customised to the 2466 specific client. For example, if the current client is forbidden from 2467 posting, then this will apply equally to groups with status "y". 2468 Conversely, a client with special privileges (not defined by this 2469 specification) might be able to post to a group with status "n". 2471 If the optional wildmat argument is specified, the response is 2472 limited to only the groups (if any) whose names match the wildmat. If 2473 no wildmat is specified, the keyword ACTIVE MAY be omitted without 2474 altering the effect of the command. 2476 7.6.1.3 Examples 2478 Example of LIST ACTIVE returning a list of newsgroups: 2480 [C] LIST ACTIVE 2481 [S] 215 list of newsgroups follows 2482 [S] misc.test 3002322 3000234 y 2483 [S] comp.risks 442001 441099 m 2484 [S] alt.rfc-writers.recovery 4 1 y 2485 [S] tx.natives.recovery 89 56 y 2487 [S] tx.natives.recovery.d 11 9 n 2488 [S] . 2490 The same output on an implementation that includes leading zeroes: 2492 [C] LIST ACTIVE 2493 [S] 215 list of newsgroups follows 2494 [S] misc.test 0003002322 0003000234 y 2495 [S] comp.risks 0000442001 0000441099 m 2496 [S] alt.rfc-writers.recovery 0000000004 0000000001 y 2497 [S] tx.natives.recovery 0000000089 0000000056 y 2498 [S] tx.natives.recovery.d 0000000011 0000000009 n 2499 [S] . 2501 Example of LIST ACTIVE omitting the second keyword and returning no 2502 newsgroups: 2504 [C] LIST 2505 [S] 215 list of newsgroups follows 2506 [S] . 2508 Example of LIST ACTIVE with a wildmat: 2510 [C] LIST ACTIVE *.recovery 2511 [S] 215 list of newsgroups follows 2512 [S] alt.rfc-writers.recovery 4 1 y 2513 [S] tx.natives.recovery 89 56 y 2514 [S] . 2516 7.6.2 LIST ACTIVE.TIMES 2518 7.6.2.1 Usage 2520 This command is optional. 2522 Syntax 2523 LIST ACTIVE.TIMES [wildmat] 2525 Responses 2526 215 Information follows (multiline) 2528 Parameters 2529 wildmat = groups of interest 2531 7.6.2.2 Description 2533 The active.times list is maintained by some news transport systems to 2534 contain information about who created a particular newsgroup and 2535 when. Each line of this list consists of three fields separated from 2536 each other by one or more spaces. The first field is the name of the 2537 newsgroup. The second is the time when this group was created on this 2538 news server, measured in seconds since the start of January 1, 1970. 2539 The third is plain text intended to describe the entity that created 2540 the newsgroup; it is often a mailbox as defined in RFC 2822 2541 [RFC2822]. 2543 The list MAY omit newsgroups for which the information is unavailable 2544 and MAY include groups not available on the server; in particular, it 2545 MAY omit all groups created before the date and time of the oldest 2546 entry. The client MUST NOT assume that the list is complete or that 2547 it matches the list returned by LIST ACTIVE. The NEWGROUPS command 2548 (Section 7.3) may provide a better way to access this information and 2549 the results of the two commands SHOULD be consistent (subject to the 2550 caveats in the description of that command). 2552 If the information is available, it is returned as a multi-line 2553 response following the 215 response code. If the optional wildmat 2554 argument is specified, the response is limited to only the groups (if 2555 any) whose names match the wildmat and for which the information is 2556 available. 2558 Note that an empty list is a possible valid response (whether or not 2559 a wildmat is specified) and indicates that there are no groups 2560 meeting the above criteria. 2562 7.6.2.3 Examples 2564 Example of LIST ACTIVE.TIMES returning a list of newsgroups: 2566 [C] LIST ACTIVE.TIMES 2567 [S] 215 information follows 2568 [S] misc.test 930445408 2569 [S] alt.rfc-writers.recovery 930562309 2570 [S] tx.natives.recovery 930678923 2571 [S] . 2573 Example of LIST ACTIVE.TIMES returning an error where the command is 2574 recognized but the software does not maintain this information: 2576 [C] LIST ACTIVE.TIMES 2577 [S] 503 program error, function not performed 2579 Example of LIST ACTIVE.TIMES sent to a server that does not recognize 2580 this command: 2582 [C] LIST ACTIVE.TIMES 2583 [S] 501 Syntax Error 2585 7.6.3 LIST DISTRIBUTIONS 2587 7.6.3.1 Usage 2589 This command is optional. 2591 Syntax 2592 LIST DISTRIBUTIONS 2594 Responses 2595 215 Information follows (multiline) 2597 7.6.3.2 Description 2599 The distributions list is maintained by some news transport systems 2600 to contain information about valid values for the content of the 2601 Distribution header in a news article and about what the various 2602 values mean. Each line of this list consists of two fields separated 2603 from each other by one or more spaces. The first field is a value and 2604 the second is a short explanation of the meaning of that value. 2606 If the information is available, it is returned as a multi-line 2607 response following the 215 response code. 2609 7.6.3.3 Examples 2611 Example of LIST DISTRIBUTIONS returning a list of distributions: 2613 [C] LIST DISTRIBUTIONS 2614 [S] 215 information follows 2615 [S] usa United States of America 2616 [S] na North America 2617 [S] world All over the World 2618 [S] . 2620 Example of LIST DISTRIBUTIONS returning an error where the command is 2621 recognized but the software does not maintain this information: 2623 [C] LIST DISTRIBUTIONS 2624 [S] 503 program error, function not performed 2626 Example of LIST DISTRIBUTIONS sent to a server that does not 2627 recognize this command: 2629 [C] LIST DISTRIBUTIONS 2630 [S] 501 Syntax Error 2632 7.6.4 LIST DISTRIB.PATS 2634 7.6.4.1 Usage 2636 This command is optional. 2638 Syntax 2639 LIST DISTRIB.PATS 2641 Responses 2642 215 Information follows (multiline) 2644 7.6.4.2 Description 2646 The distrib.pats list is maintained by some news transport systems to 2647 choose a value for the content of the Distribution header of a news 2648 article being posted. Each line of this list consists of three fields 2649 separated from each other by a colon (":"). The first field is a 2650 weight, the second field is a wildmat (which may be a simple group 2651 name), and the third field is a value for the Distribution header 2652 content. 2654 The client MAY use this information to construct an appropriate 2655 Distribution header given the name of a newsgroup. To do so, it 2656 should determine the lines whose second field matches the newsgroup 2657 name, select from among them the line with the highest weight (with 0 2658 being the lowest), and use the value of the third field to construct 2659 the Distribution header. 2661 If the information is available, it is returned as a multi-line 2662 response following the 215 response code. 2664 7.6.4.3 Examples 2666 Example of LIST DISTRIB.PATS returning a list of newsgroups: 2668 [C] LIST DISTRIB.PATS 2669 [S] 215 information follows 2670 [S] 10:local.*:local 2671 [S] 5:*:world 2673 [S] 20:local.here.*:thissite 2674 [S] . 2676 Example of LIST DISTRIB.PATS returning an error where the command is 2677 recognized but the software does not maintain this information: 2679 [C] LIST DISTRIB.PATS 2680 [S] 503 program error, function not performed 2682 Example of LIST DISTRIB.PATS sent to a server that does not recognize 2683 this command: 2685 [C] LIST DISTRIB.PATS 2686 [S] 501 Syntax Error 2688 7.6.5 LIST NEWSGROUPS 2690 7.6.5.1 Usage 2692 This command is optional. 2694 Syntax 2695 LIST NEWSGROUPS [wildmat] 2697 Responses 2698 215 Information follows (multiline) 2700 Parameters 2701 wildmat = groups of interest 2703 7.6.5.2 Description 2705 The newsgroups list is maintained by some news transport systems to 2706 contain the name of each newsgroup that is available on the server 2707 and a short description about the purpose of the group. Each line of 2708 this list consists of two fields separated from each other by one or 2709 more space or TAB characters (usual practice is a single TAB). The 2710 first field is the name of the newsgroup and the second is a short 2711 description of the group. 2713 The list MAY omit newsgroups for which the information is unavailable 2714 and MAY include groups not available on the server. The client MUST 2715 NOT assume that the list is complete or that it matches the list 2716 returned by LIST ACTIVE. 2718 If the information is available, it is returned as a multi-line 2719 response following the 215 response code. If the optional wildmat 2720 argument is specified, the response is limited to only the groups (if 2721 any) whose names match the wildmat and for which the information is 2722 available. 2724 Note that an empty list is a possible valid response (whether or not 2725 a wildmat is specified) and indicates that there are no groups 2726 meeting the above criteria. 2728 7.6.5.3 Examples 2730 Example of LIST NEWSGROUPS returning a list of newsgroups: 2732 [C] LIST NEWSGROUPS 2733 [S] 215 information follows 2734 [S] misc.test General Usenet testing 2735 [S] alt.rfc-writers.recovery RFC Writers Recovery 2736 [S] tx.natives.recovery Texas Natives Recovery 2737 [S] . 2739 Example of LIST NEWSGROUPS returning an error where the command is 2740 recognized but the software does not maintain this information: 2742 [C] LIST NEWSGROUPS 2743 [S] 503 program error, function not performed 2745 Example of LIST NEWSGROUPS sent to a server that does not recognize 2746 this command: 2748 [C] LIST NEWSGROUPS 2749 [S] 501 Syntax error 2751 8. Framework for NNTP extensions 2753 Although NNTP is widely and robustly deployed, some parts of the 2754 Internet community might wish to extend the NNTP service. This 2755 document defines a means whereby an extended NNTP client can query 2756 the server to determine the service extensions that it supports. 2758 It must be emphasized that any extension to the NNTP service should 2759 not be considered lightly. NNTP's strength comes primarily from its 2760 simplicity. Experience with many protocols has shown that: 2762 Protocols with few options tend towards ubiquity, whilst protocols 2763 with many options tend towards obscurity. 2765 This means that each and every extension, regardless of its benefits, 2766 must be carefully scrutinized with respect to its implementation, 2767 deployment, and interoperability costs. In many cases, the cost of 2768 extending the NNTP service will likely outweigh the benefit. 2770 Given this environment, the framework for extensions described in 2771 this document consists of: 2773 o a mechanism for clients to determine a server's available 2774 extensions 2776 o a registry of NNTP service extensions 2778 The LIST EXTENSIONS command is described in this document (see 2779 Section 5.3) and is the mechanism for clients to use to determine 2780 what extensions are available. Except where stated otherwise, the 2781 commands in this document are understood (even if not supported) by 2782 all servers and are not described in the list of features returned by 2783 the LIST EXTENSIONS command. 2785 The IANA shall maintain a registry of NNTP service extensions. 2787 An extension is identified by a unique extension-label, which is a 2788 string of 1 to 12 uppercase US-ASCII letters. The extension-label 2789 will often be the name of a new command that the extension adds. 2790 However this is not a requirement: an extension might not add any new 2791 commands or keywords. 2793 An extension is either a private extension or else it is included in 2794 the IANA registry and is defined in an RFC. Such RFCs either must be 2795 on the standards track or must define an IESG-approved experimental 2796 protocol. 2798 The definition of an extension must include: 2800 o a descriptive name for the extension; 2802 o the extension-label (which is returned by LIST EXTENSIONS to 2803 indicate to the client that the server supports this particular 2804 extension) - the extension-label of a registered extension MUST 2805 NOT begin with "X"; 2807 o the syntax, values, and meanings of any arguments following the 2808 extension-label in the output of LIST EXTENSIONS; 2810 o any new NNTP commands associated with the extension - the names of 2811 commands associated with registered extensions MUST NOT begin with 2812 "X"; 2814 o the syntax and possible values of arguments associated with the 2815 new NNTP commands; 2817 o the response codes and possible values of arguments for the 2818 responses of the new NNTP commands; 2820 o any new arguments the extension associates with any other 2821 pre-existing NNTP commands; 2823 o how support for the extension affects the behaviour of a server 2824 and NNTP client; 2826 o any increase in the maximum length of commands and initial 2827 response lines over the value specified in this document; 2829 o a specific statement about the effect on pipelining this extension 2830 may have (if any); 2832 o a specific statement about the circumstances when use of this 2833 extension can alter the output from LIST EXTENSIONS; 2835 o the circumstances under which the extension can cause any 2836 pre-existing command to produce a 401, 480, or 483 response; 2838 o whether the extension can be used before or after the MODE READER 2839 command, and what changes (if any) the latter has on the 2840 extension. 2842 A private extension need not be included in the output of LIST 2843 EXTENSIONS. A server MAY provide additional keywords - either for new 2844 commands or new variants of existing commands - as part of a private 2845 extension. To avoid the risk of a clash with a future registered 2846 extension, the names of private extensions and commands defined by 2847 them SHOULD begin with "X". 2849 A server MUST NOT send different response codes to basic NNTP 2850 commands documented here or commands documented in registered 2851 extensions in response to the availability or use of a private 2852 extension. 2854 8.1 Initial IANA registry 2856 The IANA's initial registry of NNTP service extensions consists of 2857 these entries: 2859 +-------------------------+--------------+--------------------------+ 2860 | Extension | Label | Added behaviour | 2861 +-------------------------+--------------+--------------------------+ 2862 | Specific article | LISTGROUP | Defined in this document | 2863 | numbers | | | 2864 | | | | 2865 | Overview support | OVER | Defined in this document | 2866 | | | | 2867 | Batched header | HDR | Defined in this document | 2868 | retrieval | | | 2869 +-------------------------+--------------+--------------------------+ 2871 8.2 Standard extensions 2873 Each of the following sections describes an extension that a server 2874 MAY provide. If the server provides the extension, it MUST include 2875 the appropriate extension label in the response to LIST EXTENSIONS. 2876 If it does not provide it, it MUST NOT include the appropriate 2877 extension label. The descriptions of facilities in each section are 2878 written as if the extension is provided. If it is not provided, the 2879 entire section should be ignored. 2881 The formal definitions of these extensions are provided in Appendix 2882 D. 2884 If the server provides an extension, it MUST implement all of the 2885 commands in the specification of the extension except for those 2886 marked as optional. If it does not provide an extension, it MUST NOT 2887 implement any of the commands in the specification of that extension. 2889 8.3 The LISTGROUP extension 2891 This extension provides one command and has the extension label 2892 LISTGROUP. 2894 8.3.1 LISTGROUP 2896 8.3.1.1 Usage 2898 Syntax 2899 LISTGROUP [group] 2901 Responses 2902 211 number low high group Article numbers follow (multiline) 2903 411 No such newsgroup 2904 412 No newsgroup selected [1] 2906 Parameters 2907 group = name of newsgroup 2908 number = estimated number of articles in the group 2909 low = reported low water mark 2910 high = reported high water mark 2912 [1] The 412 response can only occur if no group has been specified. 2914 8.3.1.2 Description 2916 The LISTGROUP command is used to get a listing of all the article 2917 numbers in a particular newsgroup. 2919 The optional argument is the name of the newsgroup to be selected 2920 (e.g. "news.software.misc"). A list of valid newsgroups may be 2921 obtained from the LIST ACTIVE command. If no group is specified, the 2922 current selected newsgroup is used. 2924 The list of article numbers is returned as a multi-line response 2925 following the 211 response code (the arguments on the initial 2926 response line are the same as for the GROUP command (see Section 2927 6.1.1). The list contains one number per line, is in numerical order, 2928 and lists precisely those articles that exist in the group. 2930 When a valid group is selected by means of this command, the current 2931 selected newsgroup MUST be set to that group and the current article 2932 number MUST be set to the first article in the group. If an empty 2933 newsgroup is selected, the current article pointer is made invalid. 2934 If an invalid group is specified, the current selected newsgroup and 2935 current article number MUST NOT be changed. 2937 The LISTGROUP command MAY be used by a client as a replacement for 2938 the GROUP command in establishing a valid current selected newsgroup 2939 and current article number. 2941 If the group specified is not available on the server, a 411 response 2942 MUST be returned. If no group is specified and the current selected 2943 newsgroup is invalid, a 412 response MUST be returned. 2945 8.3.1.3 Examples 2947 Example of LISTGROUP on an empty group: 2949 [C] LISTGROUP example.empty.newsgroup 2950 [S] 211 0 0 0 example.empty.newsgroup list follows 2951 [S] . 2953 Example of LISTGROUP on a valid current selected newsgroup: 2955 [C] GROUP misc.test 2956 [S] 211 2000 3000234 3002322 misc.test 2957 [C] LISTGROUP 2958 [S] 211 2000 3000234 3002322 misc.test list follows 2959 [S] 3000234 2960 [S] 3000237 2961 [S] 3000238 2962 [S] 3000239 2963 [S] 3002322 2964 [S] . 2966 Example of LISTGROUP failing because no group has been selected: 2968 [Assumes current selected newsgroup is invalid.] 2969 [C] LISTGROUP 2970 [S] 412 no current group 2971 [C] GROUP example.is.sob.bradner.or.barber 2972 [S] 411 no such group 2973 [C] LISTGROUP 2974 [S] 412 no current group 2976 8.4 Article metadata 2978 The OVER and HDR extensions refer to the concept of "article 2979 metadata". This is data about articles that does not occur within the 2980 article itself. Each metadata item has a name which MUST begin with a 2981 colon (and which MUST NOT contain a colon elsewhere within it). As 2982 with header names, metadata item names are not case-sensitive. 2984 When generating a metadata item, the server MUST compute it for 2985 itself and MUST NOT trust any related value provided in the article. 2986 (In particular, a Lines or Bytes header in the article MUST NOT be 2987 assumed to specify the correct number of lines or bytes in the 2988 article.) If the server has access to several non-identical copies of 2989 an article, the value returned MUST be correct for any copy of that 2990 article retrieved during the same session. 2992 This specification defines two metadata items: ":bytes" and ":lines". 2993 Other metadata items may be defined by extensions. The names of 2994 metadata items defined by registered extensions MUST NOT begin with 2995 ":x-". To avoid the risk of a clash with a future registered 2996 extension, the names of metadata items defined by private extensions 2997 SHOULD begin with ":x-". 2999 8.4.1 The :bytes metadata item 3001 The :bytes metadata item for an article is a decimal integer. It 3002 SHOULD equal the number of octets in the entire article - headers, 3003 body, and separating empty line (counting a CRLF pair as two octets, 3004 and excluding both the "." CRLF terminating the response and any "." 3005 added for "byte-stuffing" purposes). 3007 Note to client implementers: some existing servers return a value 3008 different to that above. The commonest reasons for this are: 3010 o counting a CRLF pair as one octet; 3012 o including the "." character used for byte-stuffing in the number; 3014 o including the terminating "." CRLF in the number; 3016 o using one copy of an article for counting the octets but then 3017 returning another one that differs in some (permitted) manner. 3019 Implementations should be prepared for such variation and MUST NOT 3020 rely on the value being accurate. 3022 8.4.2 The :lines metadata item 3024 The :lines metadata item for an article is a decimal integer. It MUST 3025 equal the number of lines in the article body (excluding the empty 3026 line separating headers and body); equivalently, it is two less than 3027 the number of CRLF pairs that the BODY command would return for that 3028 article (the extra two are those following the response code and the 3029 termination octet). 3031 8.5 The OVER extension 3033 This extension provides two commands, OVER and LIST OVERVIEW.FMT. The 3034 label for this extension is OVER. 3036 The OVER extension provides access to the "overview database", which 3037 is a database of headers extracted from incoming articles. Only 3038 certain headers are included in the database. The database also 3039 includes some article metadata. 3041 The information stored in the database may change over time. If the 3042 database records the content or absence of a given field (that is, a 3043 header or metadata item) for all articles, it is said to be 3044 "consistent" for that field. If it records the content of a header 3045 for some articles but not for others that nevertheless included that 3046 header, or records a metadata item for some articles but not others 3047 to which that item applies, it is said to be "inconsistent" for that 3048 field. 3050 The LIST OVERVIEW.FMT command SHOULD list all the fields for which 3051 the database is consistent at that moment. It MAY omit such fields 3052 (for example if it is not known whether the database is consistent or 3053 inconsistent). It MUST NOT include fields for which the database is 3054 inconsistent or which are not stored in the database. Therefore if a 3055 header appears in the LIST OVERVIEW.FMT output but not the OVER 3056 output for a given article, that header does not appear in the 3057 article, and similarly for metadata items. 3059 These rules assume the fields being stored in the database remain 3060 constant for long periods of time, with the database therefore being 3061 consistent. When the set of fields to be stored is changed, it will 3062 be inconsistent until either the database is rebuilt or the only 3063 articles remaining are those received since the change. Therefore the 3064 output from LIST OVERVIEW.FMT needs to be altered twice: before any 3065 fields stop being stored, they MUST be removed from the output, then 3066 when the database is once more known to be consistent, the new fields 3067 SHOULD be added to the output. 3069 Support for the message-id form of the OVER command is optional. If 3070 an implementation supports this form, it MUST use the argument 3071 "MSGID" following the extension label in the output of LIST 3072 EXTENSIONS; if not, it MUST NOT use any argument. 3074 This extension is based on the Overview/NOV database [ROBE1995] 3075 developed by Geoff Collyer. 3077 8.5.1 OVER 3079 8.5.1.1 Usage 3080 Syntax 3081 OVER message-id 3082 OVER range 3083 OVER 3085 Responses 3087 First form (message-id specified) 3088 224 Overview information follows (multiline) 3089 430 No article with that message-id 3091 Second form (range specified) 3092 224 Overview information follows (multiline) 3093 412 No newsgroup selected 3094 423 No articles in that range 3096 Third form (current article number used) 3097 224 Overview information follows (multiline) 3098 412 No newsgroup selected 3099 420 Current article number is invalid 3101 Parameters 3102 range = number(s) of articles 3103 message-id = message-id of article 3105 8.5.1.2 Description 3107 The OVER command returns the contents of the headers and metadata in 3108 the database for an article specified by message-id, or from a 3109 specified article or range of articles in the current selected 3110 newsgroup. 3112 The message-id argument indicates a specific article. The range 3113 argument may be any of the following: 3115 o an article number 3117 o an article number followed by a dash to indicate all following 3119 o an article number followed by a dash followed by another article 3120 number 3122 If neither is specified, the current article number is used. Support 3123 for the first (message-id) form is optional. If it is not supported, 3124 the generic response code 503 MUST be returned. 3126 If the information is available, it is returned as a multi-line 3127 response following the 224 response code and contains one line per 3128 article, sorted in numerical order of article number (note that 3129 unless the argument is a range including a dash, there will only be 3130 one line but it will still be in multi-line format). Each line 3131 consists of a number of fields separated by a TAB. A field may be 3132 empty (in which case there will be two adjacent TABs), and a sequence 3133 of trailing TABs may be omitted. 3135 The first 8 fields MUST be the following, in order: 3137 "0" or article number (see below) 3138 Subject header content 3139 From header content 3140 Date header content 3141 Message-ID header content 3142 References header content 3143 :bytes metadata item 3144 :lines metadata item 3146 If the article is specified by message-id (the first form of the 3147 command), the article number MUST be replaced with zero, except that 3148 if there is a current selected group and the article is present in 3149 that group, the server MAY use that article number (see the ARTICLE 3150 command (Section 6.2.1) and STAT examples (Section 6.2.4.3) for more 3151 details). In the other two forms of the command, the article number 3152 MUST be returned. 3154 Any subsequent fields are the contents of the other headers and 3155 metadata held in the database. 3157 For the five mandatory headers, the content of each field MUST be 3158 based on the content of the header (that is, with the header name and 3159 following colon and space removed). If the article does not contain 3160 that header, or if the content is empty, the field MUST be empty. For 3161 the two mandatory metadata items, the content of the field MUST be 3162 just the value, with no other text. 3164 For all subsequent fields that contain headers, the content MUST be 3165 the entire header line other than the trailing CRLF. For all 3166 subsequent fields that contain metadata, the field consists of the 3167 metadata name, a single space, and then the value. 3169 For all fields, the value is processed by first removing all CRLF 3170 pairs (that is, undoing any folding and removing the terminating 3171 CRLF) and then replacing each TAB with a single space. If there is no 3172 such header in the article, or no such metadata item, or no header or 3173 item stored in the database for that article, the corresponding field 3174 MUST be empty. 3176 Note that, after unfolding, the characters NUL, LF, and CR cannot 3177 occur in the header of an article offered by a conformant server. 3178 Nevertheless, servers SHOULD check for these characters and replace 3179 each one by a single space (so that, for example, CR LF LF TAB will 3180 become two spaces, since the CR and first LF will be removed by the 3181 unfolding process). This will encourage robustness in the face of 3182 non-conforming data; it is also possible that future versions of this 3183 specification could permit these characters to appear in articles. 3185 The server SHOULD NOT produce output for articles that no longer 3186 exist. 3188 If the argument is a message-id and no such article exists, a 430 3189 response MUST be returned. If the argument is a range or is omitted 3190 and the current selected newsgroup is invalid, a 412 response MUST be 3191 returned. If the argument is a range and no articles in that number 3192 range exist in the current selected newsgroup, a 423 response MUST be 3193 returned. If the argument is omitted and the current article number 3194 is invalid, a 420 response MUST be returned. 3196 8.5.1.3 Examples 3198 In the first three examples, TAB has been replaced by vertical bar 3199 and some lines have been folded for readability. 3201 Example of a successful retrieval of overview information for an 3202 article (using no article number): 3204 [C] GROUP misc.test 3205 [S] 211 1234 3000234 3002322 misc.test 3206 [C] OVER 3207 [S] 224 Overview information follows 3208 [S] 300234|I am just a test article|"Demo User" 3209 |6 Oct 1998 04:38:40 -0500| 3210 <45223423@example.com>|<45454@example.net>|1234| 3211 17|Xref: news.example.com misc.test:3000363 3212 [S] . 3214 Example of a successful retrieval of overview information for an 3215 article by message-id: 3217 [C] LIST EXTENSIONS 3218 [S] 202 extensions supported: 3219 [S] OVER MSGID 3220 [S] . 3221 [C] OVER <45223423@example.com> 3222 [S] 224 Overview information follows 3223 [S] 0|I am just a test article|"Demo User" 3224 |6 Oct 1998 04:38:40 -0500| 3225 <45223423@example.com>|<45454@example.net>|1234| 3226 17|Xref: news.example.com misc.test:3000363 3227 [S] . 3229 Note that the article number has been replaced by "0". 3231 Example of the same commands on a system that does not implement 3232 retrieval by message-id: 3234 [C] LIST EXTENSIONS 3235 [S] 202 extensions supported: 3236 [S] OVER 3237 [S] . 3238 [C] OVER <45223423@example.com> 3239 [S] 503 Overview by message-id unsupported 3241 Example of a successful retrieval of overview information for a range 3242 of articles: 3244 [C] GROUP misc.test 3245 [S] 211 1234 3000234 3002322 misc.test 3246 [C] OVER 3000234-3000240 3247 [S] 224 Overview information follows 3248 [S] 300234|I am just a test article|"Demo User" 3249 |6 Oct 1998 04:38:40 -0500| 3250 <45223423@example.com>|<45454@example.net>|1234| 3251 17|Xref: news.example.com misc.test:3000363 3252 [S] 3000235|Another test article|nobody@nowhere.to 3253 (Demo User)|6 Oct 1998 04:38:45 -0500|<45223425@to.to>|| 3254 4818|37||Distribution: fi 3255 [S] 3000238|Re: I am just a test article|somebody@elsewhere.to| 3256 7 Oct 1998 11:38:40 +1200|| 3257 <45223423@to.to>|9234|51 3258 [S] . 3260 Note the missing "References" and Xref headers in the second line, 3261 the missing trailing field(s) in the first and last lines, and that 3262 there are only results for those articles that still exist. 3264 Example of an unsuccessful retrieval of overview information on an 3265 article by number: 3267 [C] GROUP misc.test 3268 [S] 211 1234 3000234 3002322 misc.test 3269 [C] OVER 300256 3270 [S] 420 No such article in this group 3272 Example of an unsuccessful retrieval of overview information by 3273 number because no newsgroup was selected first: 3275 [Assumes current selected newsgroup is invalid.] 3276 [C] OVER 3277 [S] 412 No newsgroup selected 3279 Example of an attempt to retrieve information when the current 3280 selected newsgroup is empty: 3282 [C] GROUP example.empty.newsgroup 3283 [S] 211 0 0 0 example.empty.newsgroup 3284 [C] OVER 3285 [S] 420 No current article selected 3287 8.5.2 LIST OVERVIEW.FMT 3289 8.5.2.1 Usage 3291 This command is optional. 3293 Syntax 3294 LIST OVERVIEW.FMT 3296 Responses 3297 215 Information follows (multiline) 3299 8.5.2.2 Description 3301 The LIST OVERVIEW.FMT command returns a description of the fields in 3302 the database for which it is consistent (as described above). 3304 If the information is available, it is returned as a multi-line 3305 response following the 215 response code. The information contains 3306 one line per field in the order they are returned by the OVER 3307 command; the first 7 lines MUST (except for the case of letters) be 3308 exactly: 3310 Subject: 3311 From: 3312 Date: 3313 Message-ID: 3314 References: 3315 :bytes 3316 :lines 3318 except that, for compatibility with existing implementations, the 3319 last two lines MAY instead be: 3321 Bytes: 3322 Lines: 3324 even though they refer to metadata, not headers. 3326 All subsequent lines MUST consist of either a header name followed by 3327 ":full", or the name of a piece of metadata. 3329 There are no leading or trailing spaces in the output. 3331 Note that the 7 fixed lines describe the 2nd to 8th fields of the 3332 OVER output. The "full" suffix (which may use either uppercase, 3333 lowercase, or a mix) is a reminder that the corresponding fields 3334 include the header name. 3336 This command MAY generate different results if used more than once in 3337 a session. 3339 8.5.2.3 Examples 3341 Example of LIST OVERVIEW.FMT output corresponding to the example OVER 3342 output above, using the preferred format: 3344 [C] LIST OVERVIEW.FMT 3345 [S] 215 Order of fields in overview database. 3346 [S] Subject: 3347 [S] From: 3348 [S] Date: 3349 [S] Message-ID: 3350 [S] References: 3351 [S] :bytes 3352 [S] :lines 3353 [S] Xref:full 3354 [S] Distribution:full 3355 [S] . 3357 Example of LIST OVERVIEW.FMT output corresponding to the example OVER 3358 output above, using the alternative format: 3360 [C] LIST OVERVIEW.FMT 3361 [S] 215 Order of fields in overview database. 3362 [S] Subject: 3363 [S] From: 3364 [S] Date: 3365 [S] Message-ID: 3367 [S] References: 3368 [S] Bytes: 3369 [S] Lines: 3370 [S] Xref:FULL 3371 [S] Distribution:FULL 3372 [S] . 3374 Example of LIST OVERVIEW.FMT returning an error where the command is 3375 recognized but the software does not maintain this information: 3377 [C] LIST OVERVIEW.FMT 3378 [S] 503 overview.fmt not available 3380 8.6 The HDR extension 3382 This extension provides two new commands: HDR and LIST HEADERS. The 3383 label for this extension is HDR. 3385 The HDR extension provides access to specific headers and metadata 3386 items (collectively "fields") of articles or groups of articles. In 3387 the case of headers, an implementation MAY restrict the use of this 3388 extension to a specific list of headers or MAY allow it to be used 3389 with any header; it may behave differently when the HDR command is 3390 used with a message-id argument and when it is used with a range or 3391 no argument. 3393 The HDR command may take information from a database rather than 3394 directly from the articles. If so, the same issues of consistency and 3395 inconsistency apply as with the OVER extension (Section 8.5) and the 3396 LIST HEADERS command SHOULD take the same approach as the LIST 3397 OVERVIEW.FMT command in resolving them. 3399 8.6.1 HDR 3401 8.6.1.1 Usage 3403 Syntax 3404 HDR header message-id 3405 HDR header range 3406 HDR header 3408 Responses 3410 First form (message-id specified) 3411 225 Headers follow (multiline) 3412 430 No article with that message-id 3414 Second form (range specified) 3415 225 Headers follow (multiline) 3416 412 No newsgroup selected 3417 423 No articles in that range 3419 Third form (current article number used) 3420 225 Headers follow (multiline) 3421 412 No newsgroup selected 3422 420 Current article number is invalid 3424 Parameters 3425 header = name of header, without the colon 3426 range = number(s) of articles 3427 message-id = message-id of article 3429 8.6.1.2 Description 3431 The HDR command retrieves specific headers from an article specified 3432 by message-id, or from a specified article or range of articles in 3433 the current selected newsgroup. It can also return certain metadata 3434 about the article or articles. 3436 The required header argument is the name of a header (e.g. "subject") 3437 in an article, or the name of a metadata item, and is 3438 case-insensitive. Names of metadata items always begin with a colon. 3439 Except where stated otherwise, metadata items are treated as if they 3440 were header contents, and references to headers in this description 3441 apply equally to metadata items. 3443 The message-id argument indicates a specific article. The range 3444 argument may be any of the following: 3446 o an article number 3448 o an article number followed by a dash to indicate all following 3450 o an article number followed by a dash followed by another article 3451 number 3453 If neither is specified, the current article number is used. 3455 If the information is available, it is returned as a multi-line 3456 response following the 225 response code and contains one line for 3457 each article in the range that exists (note that unless the argument 3458 is a range including a dash, there will be at most one line but it 3459 will still be in multi-line format). The line consists of the article 3460 number, a space, and then the contents of the header or metadata 3461 item. In the case of a header, the header name, colon, and the first 3462 space after the colon are all omitted. 3464 If the article is specified by message-id (the first form of the 3465 command), the article number MUST be replaced with zero, except that 3466 if there is a current selected group and the article is present in 3467 that group, the server MAY use that article number (see the ARTICLE 3468 command (Section 6.2.1) and STAT examples (Section 6.2.4.3) for more 3469 details). In the other two forms of the command, the article number 3470 MUST be returned. 3472 Header contents are modified as follows: all CRLF pairs are removed, 3473 and then each TAB is replaced with a single space (note that this is 3474 the same transformation as is performed by the OVER extension 3475 (Section 8.5.1.2), and the same comment concerning NUL, CR, and LF 3476 applies). 3478 The header content is in all cases taken from the article. This means 3479 that, for example, a request for the header "Lines" returns the 3480 contents of the "Lines" header of the specified articles, if any, not 3481 the line count metadata or any other server-generated value. If the 3482 header occurs in a given article multiple times, only the content of 3483 the first occurrence is returned by HDR. 3485 If the requested header is not present in the article or if it is 3486 present but empty, a line for that article is included in the output 3487 but the header content portion of the line is empty (the space after 3488 the article number MAY be retained or omitted). If any article number 3489 in the provided range does not exist in the group, no line for that 3490 article number is included in the output. 3492 If the second argument is a message-id and no such article exists, a 3493 430 response MUST be returned. If the second argument is a range or 3494 is omitted and the current selected newsgroup is invalid, a 412 3495 response MUST be returned. If the second argument is a range and no 3496 articles in that number range exist in the current selected 3497 newsgroup, a 423 response MUST be returned. If the second argument is 3498 omitted and the current article number is invalid, a 420 response 3499 MUST be returned. 3501 A server MAY only allow HDR commands for a limited set of headers and 3502 metadata items; it may behave differently in this respect for the 3503 first (message-id) form than for the other forms. If so, it MUST 3504 respond with the generic 503 response to attempts to request other 3505 headers, rather than returning erroneous results such as a successful 3506 empty response. 3508 If HDR uses a separate database and it is inconsistent for the 3509 requested header or metadata item, the server MAY return what results 3510 it can or it MAY respond with the generic 503 response; in the latter 3511 case, the field MUST NOT appear in the output from LIST HEADERS. 3513 8.6.1.3 Examples 3515 Example of a successful retrieval of subject lines from a range of 3516 articles (3000235 has no Subject header, and 3000236 is missing): 3518 [C] GROUP misc.test 3519 [S] 211 1234 3000234 3002322 misc.test 3520 [C] HDR Subject 3000234-300238 3521 [S] 225 Headers follow 3522 [S] 3000234 I am just a test article 3523 [S] 3000235 3524 [S] 3000237 Re: I am just a test article 3525 [S] 3000238 Ditto 3526 [S] . 3528 Example of a successful retrieval of line counts from a range of 3529 articles: 3531 [C] GROUP misc.test 3532 [S] 211 1234 3000234 3002322 misc.test 3533 [C] HDR :lines 3000234-300238 3534 [S] 225 Headers follow 3535 [S] 3000234 42 3536 [S] 3000235 5 3537 [S] 3000237 11 3538 [S] 3000238 2378 3539 [S] . 3541 Example of a successful retrieval of the subject line from an article 3542 by message-id: 3544 [C] GROUP misc.test 3545 [S] 211 1234 3000234 3002322 misc.test 3546 [C] HDR subject 3547 [S] 225 Header information follows 3548 [S] 0 I am just a test article 3549 [S] . 3551 Example of a successful retrieval of the subject line from the 3552 current article: 3554 [C] GROUP misc.test 3555 [S] 211 1234 3000234 3002322 misc.test 3556 [C] HDR subject 3558 [S] 225 Header information follows 3559 [S] 3000234 I am just a test article 3560 [S] . 3562 Example of an unsuccessful retrieval of a header from an article by 3563 message-id: 3565 [C] HDR subject 3566 [S] 430 No Such Article Found 3568 Example of an unsuccessful retrieval of headers from articles by 3569 number because no newsgroup was selected first: 3571 [Assumes current selected newsgroup is invalid.] 3572 [C] HDR subject 300256- 3573 [S] 412 No newsgroup selected 3575 Example of an unsuccessful retrieval of headers because the current 3576 selected newsgroup is empty: 3578 [C] GROUP example.empty.newsgroup 3579 [S] 211 0 0 0 example.empty.newsgroup 3580 [C] HDR subject 1- 3581 [S] 423 No articles in that range 3583 Example of an unsuccessful retrieval of headers because the server 3584 does not allow HDR commands for that header: 3586 [C] GROUP misc.test 3587 [S] 211 1234 3000234 3002322 misc.test 3588 [C] HDR Content-Type 3000234-300238 3589 [S] 503 HDR not permitted on Content-Type 3591 8.6.2 LIST HEADERS 3593 8.6.2.1 Usage 3595 Syntax 3596 LIST HEADERS [MSGID|RANGE] 3598 Responses 3599 215 Header and metadata list follows (multiline) 3601 Parameters 3602 MSGID = requests list for access by message-id 3603 RANGE = requests list for access by range 3605 8.6.2.2 Description 3607 The LIST HEADERS command returns a list of headers and metadata items 3608 that may be retrieved using the HDR command. 3610 The information is returned as a multi-line response following the 3611 215 response code and contains one line for each header or metadata 3612 item name (excluding the colon in the former case). If the 3613 implementation allows any header to be retrieved, it MUST NOT include 3614 any header names in the list but MUST include the special entry ":" 3615 (a single colon on its own); it MUST still list any metadata items 3616 that are available. The order of items in the list is not 3617 significant; the server need not even consistently return the same 3618 order. The list MAY be empty (though in this circumstance there is 3619 little point in providing the extension). 3621 An implementation that also supports the OVER extension SHOULD at 3622 least permit all the headers and metadata items listed in the output 3623 from the LIST OVERVIEW.FMT command. 3625 If the server treats the first form of the HDR command (message-id 3626 specified) differently to the other two forms (range specified or 3627 current article number used) in respect of which headers or metadata 3628 items are available, then: 3630 o if the MSGID argument is specified, the results MUST be those 3631 available for the first form of the HDR command; 3633 o if the RANGE argument is specified, the results MUST be those 3634 available for the second and third forms of the HDR command; 3636 o if no argument is specified, the results MUST be those available 3637 in all forms of the HDR command (that is, it MUST only list those 3638 items listed in both the previous cases). 3640 If the server does not treat the various forms differently, then it 3641 MUST always produce the same results and ignore any argument. 3643 8.6.2.3 Examples 3645 Example of an implementation providing access to only a few headers: 3647 [C] LIST HEADERS 3648 [S] 215 headers supported: 3649 [S] Subject 3650 [S] Message-ID 3651 [S] Xref 3652 [S] . 3654 Example of an implementation providing access to the same fields as 3655 the first example in Section 8.5.2.3: 3657 [C] LIST EXTENSIONS 3658 [S] 202 extensions supported: 3659 [S] OVER 3660 [S] HDR 3661 [S] . 3662 [C] LIST HEADERS 3663 [S] 215 headers and metadata items supported: 3664 [S] Date 3665 [S] Distribution 3666 [S] From 3667 [S] Message-ID 3668 [S] References 3669 [S] Subject 3670 [S] Xref 3671 [S] :bytes 3672 [S] :lines 3673 [S] . 3675 Example of an implementation providing access to all headers: 3677 [C] LIST HEADERS 3678 [S] 215 metadata items supported: 3679 [S] : 3680 [S] :lines 3681 [S] :bytes 3682 [S] :x-article-number 3683 [S] . 3685 Example of an implementation distinguishing the first form of the HDR 3686 command from the other two forms: 3688 [C] LIST HEADERS RANGE 3689 [S] 215 metadata items supported: 3690 [S] : 3691 [S] :lines 3692 [S] :bytes 3693 [S] . 3694 [C] LIST HEADERS MSGID 3695 [S] 215 headers and metadata items supported: 3696 [S] Date 3697 [S] Distribution 3698 [S] From 3699 [S] Message-ID 3700 [S] References 3701 [S] Subject 3703 [S] :lines 3704 [S] :bytes 3705 [S] :x-article-number 3706 [S] . 3707 [C] LIST HEADERS 3708 [S] 215 headers and metadata items supported: 3709 [S] Date 3710 [S] Distribution 3711 [S] From 3712 [S] Message-ID 3713 [S] References 3714 [S] Subject 3715 [S] :lines 3716 [S] :bytes 3717 [S] . 3719 Note how :x-article-number does not appear in the last set of output. 3721 9. Augmented BNF Syntax for NNTP 3723 Each of the following sections describes the syntax of a major 3724 element of NNTP. This syntax extends and refines the descriptions 3725 elsewhere in this specification, and should be given precedence when 3726 resolving apparent conflicts. Note that ABNF [RFC2234] strings are 3727 case-insensitive. Non-terminals used in several places are defined in 3728 a separate section at the end. 3730 9.1 Commands 3732 This syntax defines the non-terminal "command-line", which represents 3733 what is sent from the client to the server. 3735 command-line = command EOL 3736 command = article-command / 3737 body-command / 3738 date-command / 3739 group-command / 3740 hdr-command / 3741 head-command / 3742 help-command / 3743 ihave-command / 3744 last-command / 3745 list-active-command / 3746 list-active-times-command / 3747 list-distrib-pats-command / 3748 list-distributions-command / 3749 list-extensions-command / 3750 list-headers-command / 3751 list-newsgroups-command / 3752 list-overview-fmt-command / 3753 listgroup-command / 3754 mode-reader-command / 3755 newgroups-command / 3756 newnews-command / 3757 next-command / 3758 over-command / 3759 post-command / 3760 quit-command / 3761 stat-command / 3762 x-command 3764 article-command = "ARTICLE" [article-ref] 3765 body-command = "BODY" [article-ref] 3766 date-command = "DATE" 3767 group-command = "GROUP" WS newsgroup-name 3768 hdr-command = "HDR" WS header-meta-name [range-ref] 3769 head-command = "HEAD" [article-ref] 3770 help-command = "HELP" 3771 ihave-command = "IHAVE" WS message-id 3772 last-command = "LAST" 3773 list-active-command = "LIST" [WS "ACTIVE" [WS wildmat]] 3774 list-active-times-command = "LIST" WS "ACTIVE.TIMES" [WS wildmat] 3775 list-distrib-pats-command = "LIST" WS "DISTRIB.PATS" 3776 list-distributions-command = "LIST" WS "DISTRIBUTIONS" 3777 list-extensions-command = "LIST" WS "EXTENSIONS" 3778 list-headers-command = "LIST" WS "HEADERS" WS ["MSGID" / "RANGE"] 3779 list-newsgroups-command = "LIST" WS "NEWSGROUPS" [WS wildmat] 3780 list-overview-fmt-command = "LIST" WS "OVERVIEW.FMT" 3781 listgroup-command = "LISTGROUP" [WS newsgroup-name] 3782 mode-reader-command = "MODE" WS "READER" 3783 newgroups-command = "NEWGROUPS" WS date-time 3784 newnews-command = "NEWNEWS" WS wildmat WS date-time 3785 next-command = "NEXT" 3786 over-command = "OVER" [WS range-ref] 3787 post-command = "POST" 3788 quit-command = "QUIT" 3789 stat-command = "STAT" [article-ref] 3790 x-command = x-command-name *(WS x-argument) 3791 ; Each extension command is specified fully elsewhere 3793 article-ref = WS (article-number / message-id) 3794 date = [2DIGIT] 6DIGIT 3795 date-time = date WS time [WS "GMT"] 3796 header-meta-name = header-name / metadata-name 3797 metadata-name = ":" 1*A-NOTCOLON 3798 newsgroup-name = 1*wildmat-exact 3799 range = article-number ["-" [article-number]] 3800 range-ref = WS (range / message-id) 3801 time = 6DIGIT 3802 x-command-name = 3*12A-CHAR 3803 x-argument = 1*P-CHAR 3805 wildmat = wildmat-pattern *("," ["!"] wildmat-pattern) 3806 wildmat-pattern = 1*wildmat-item 3807 wildmat-item = wildmat-exact / wildmat-wild 3808 wildmat-exact = %x21-29 / %x2B / %x2D-3E / %x40-5A / %x5E-7E / 3809 UTF8-non-ascii ; exclude * , ? [ \ ] 3810 wildmat-wild = "*" / "?" 3812 9.2 Responses 3814 This syntax defines the non-terminal "response", which represents 3815 what is sent from the server to the client in response to a command. 3817 response = simple-response / multiline-response 3818 multiline-response = simple-response *content-line termination 3819 termination = "." CRLF 3820 content-line = [content-text] CRLF 3821 content-text = (".." / B-NONDOT) *B-CHAR 3823 simple-response = 3DIGIT arguments [ SP trailing-comment ] CRLF 3824 trailing-comment = *U-CHAR 3825 arguments = *(SP argument) ; How many depends on the response 3826 argument = 1*A-CHAR 3828 9.3 Multi-line response contents 3830 This syntax defines the content of the various multi-line responses, 3831 in each case after any "byte-stuffing" has been undone. 3833 multiline-response-content: article-response / 3834 body-response / 3835 hdr-response / 3836 head-response / 3837 help-response / 3838 list-active-response / 3839 list-active-times-response / 3840 list-distrib-pats-response / 3841 list-distributions-response / 3842 list-extensions-response / 3843 list-headers-response / 3844 list-newsgroups-response / 3845 list-overview-fmt-response / 3846 listgroup-response / 3847 newgroups-response / 3848 newnews-response / 3849 over-response 3851 article-response = article 3852 body-response = body 3853 hdr-response = *(article-number SP hdr-content CRLF) 3854 head-response = 1*header 3855 help-response = *(*B-CHAR CRLF) 3856 list-active-response = *(newsgroup-name SPA article-number 3857 SPA article-number SPA newsgroup-status CRLF) 3858 list-active-times-response = 3859 *(newsgroup-name SPA 1*DIGIT SPA newsgroup-creator CRLF) 3860 list-distrib-pats-response = 3861 *(1*DIGIT ":" wildmat ":" distribution CRLF) 3862 list-distributions-response = 3863 *(distribution SPA distribution-description CRLF) 3864 list-extensions-response = 3865 *(extension-label *(SPA extension-argument) CRLF) 3866 list-headers-response = *(header-meta-name CRLF) / 3867 *((metadata-name / ":") CRLF) 3868 list-newsgroups-response = 3869 *(newsgroup-name WS newsgroup-description CRLF) 3870 list-overview-fmt-response = list-overview-fmt-text 3871 listgroup-response = *(article-number CRLF) 3872 newgroups-response = list-active-response 3873 newnews-response = *(message-id CRLF) 3874 over-response = *(article-number over-content CRLF) 3876 list-overview-fmt-text = 3877 "Subject:" CRLF 3878 "From:" CRLF 3879 "Date:" CRLF 3880 "Message-ID:" CRLF 3881 "References:" CRLF 3882 ( ":bytes" CRLF ":lines" / "Bytes:" CRLF "Lines:") CRLF 3883 *((header-name ":full" / metadata-name) CRLF) 3885 distribution = 1*P-CHAR 3886 distribution-description = U-TEXT 3887 extension-argument = 1*P-CHAR 3888 extension-label = 1*12UPPER 3889 hdr-content = *S-NONTAB 3890 hdr-n-content = [(header-name ":" / metadata-name) SP hdr-content] 3891 newsgroup-creator = U-TEXT 3892 newsgroup-description = S-TEXT 3893 newsgroup-status = %x79 / %x6E / %x6D / private-status 3894 over-content = 1*6(TAB hdr-content) / 3895 7(TAB hdr-content) *(TAB hdr-n-content) 3896 private-status = 1*P-CHAR ; except the values in newsgroup-status 3898 9.4 Articles 3900 This syntax defines the non-terminal "article", which represents the 3901 format of an article as described in Section 3.4. 3903 article = 1*header CRLF body 3904 header = header-name ":" [CRLF] SP header-content CRLF 3905 header-content = *(S-CHAR / [CRLF] WS) 3906 body = *(*B-CHAR CRLF) 3908 9.5 General non-terminals 3910 article-number = 1*16DIGIT 3911 header-name = 1*A-NOTCOLON 3912 message-id = "<" 1*248A-NOTGT ">" 3914 ; Assorted special character sets 3915 ; A- means based on ASCII, excluding controls and SP 3916 ; P- means based on UTF-8, excluding controls and SP 3917 ; U- means based on UTF-8, excluding NUL CR and LF 3918 ; B- means based on bytes, excluding NUL CR and LF 3919 A-CHAR = %x21-7E 3920 A-NOTCOLON = %x21-39 / %x3B-7E ; exclude ":" 3921 A-NOTGT = %x21-3D / %x3F-7E ; exclude ">" 3922 P-CHAR = A-CHAR / UTF8-non-ascii 3923 U-CHAR = CTRL / TAB / SP / A-CHAR / UTF8-non-ascii 3924 U-NONTAB = CTRL / SP / A-CHAR / UTF8-non-ascii 3925 U-TEXT = P-CHAR *U-CHAR 3926 B-CHAR = CTRL / TAB / SP / %x21-FF 3927 B-NONDOT = CTRL / TAB / SP / %x21-2D / %x2F-FF ; exclude "." 3929 CR = %x0D 3930 CRLF = CR LF 3931 CTRL = %x01-08 / %x0B-0C / %x0E-1F 3932 DIGIT = %x30-39 3933 EOL = *(SP / TAB) CRLF 3934 LF = %x0A 3935 SP = %x20 3936 SPA = 1*SP 3937 TAB = %x09 3938 UPPER = %41-5A 3939 UTF8-non-ascii = UTF8-2 / UTF8-3 / UTF8-4 3940 UTF8-2 = %xC2-DF UTF8-tail 3941 UTF8-3 = %xE0 %xA0-BF UTF8-tail / %xE1-EC 2UTF8-tail / 3942 %xED %x80-9F UTF8-tail / %xEE-EF 2UTF8-tail 3943 UTF8-4 = %xF0 %x90-BF 2UTF8-tail / %xF1-F3 3UTF8-tail / 3944 %xF4 %x80-8F 2UTF8-tail 3945 UTF8-tail = %x80-BF 3946 WS = 1*(SP / TAB) 3948 The following non-terminals require special consideration. They 3949 represent situations where material SHOULD be restricted to UTF-8, 3950 but implementations MUST be able to cope with other character 3951 encodings. Therefore there are two sets of definitions for them. 3953 Implementations MUST accept any content that meets this syntax: 3955 S-CHAR = %x21-FF 3956 S-NONTAB = CTRL / SP / S-CHAR 3957 S-TEXT = (CTRL / S-CHAR) *B-CHAR 3959 Implementations SHOULD only generate content that meets this syntax: 3961 S-CHAR = P-CHAR 3962 S-NONTAB = U-NONTAB 3963 S-TEXT = U-TEXT 3965 10. IANA Considerations 3967 This specification requires IANA to keep a registry of 3968 extension-labels. The initial contents of this registry are specified 3969 in Section 8.1. As described in Section 8, names beginning with X are 3970 reserved for private use while all other names are to be associated 3971 with a specification in an RFC on the standards-track or defining an 3972 IESG-approved experimental protocol. 3974 11. Security Considerations 3976 This section is meant to inform application developers, information 3977 providers, and users of the security limitations in NNTP as described 3978 by this document. The discussion does not include definitive 3979 solutions to the problems revealed, though it does make some 3980 suggestions for reducing security risks. 3982 11.1 Personal and Proprietary Information 3984 NNTP, because it was created to distribute network news articles, 3985 will forward whatever information is stored in those articles. 3986 Specification of that information is outside this scope of this 3987 document, but it is likely that some personal and/or proprietary 3988 information is available in some of those articles. It is very 3989 important that designers and implementers provide informative 3990 warnings to users so personal and/or proprietary information in 3991 material that is added automatically to articles (e.g. in headers) is 3992 not disclosed inadvertently. Additionally, effective and easily 3993 understood mechanisms to manage the distribution of news articles 3994 SHOULD be provided to NNTP Server administrators, so that they are 3995 able to report with confidence the likely spread of any particular 3996 set of news articles. 3998 11.2 Abuse of Server Log Information 4000 A server is in the position to save session data about a user's 4001 requests that might identify their reading patterns or subjects of 4002 interest. This information is clearly confidential in nature and its 4003 handling can be constrained by law in certain countries. People using 4004 the NNTP protocol to provide data are responsible for ensuring that 4005 such material is not distributed without the permission of any 4006 individuals that are identifiable by the published results. 4008 11.3 Weak Authentication and Access Control 4010 There is no user-based or token-based authentication in the basic 4011 NNTP specification. Access is normally controlled by server 4012 configuration files. Those files specify access by using domain names 4013 or IP addresses. However, this specification does permit the creation 4014 of extensions to the NNTP protocol itself for such purposes. While 4015 including such mechanisms is optional, doing so is strongly 4016 encouraged. 4018 Other mechanisms are also available. For example, a proxy server 4019 could be put in place that requires authentication before connecting 4020 via the proxy to the NNTP server. 4022 11.4 DNS Spoofing 4024 Many existing NNTP implementations authorize incoming connections by 4025 checking the IP address of that connection against the IP addresses 4026 obtained via DNS lookups of lists of domain names given in local 4027 configuration files. Servers that use this type of authentication, 4028 and clients that find a server by doing a DNS lookup of the server 4029 name, rely very heavily on the Domain Name Service, and are thus 4030 generally prone to security attacks based on the deliberate 4031 misassociation of IP addresses and DNS names. Clients and servers 4032 need to be cautious in assuming the continuing validity of an IP 4033 number/DNS name association. 4035 In particular, NNTP clients and servers SHOULD rely on their name 4036 resolver for confirmation of an IP number/DNS name association, 4037 rather than caching the result of previous host name lookups. Many 4038 platforms already can cache host name lookups locally when 4039 appropriate, and they SHOULD be configured to do so. It is proper for 4040 these lookups to be cached, however, only when the TTL (Time To Live) 4041 information reported by the name server makes it likely that the 4042 cached information will remain useful. 4044 If NNTP clients or servers cache the results of host name lookups in 4045 order to achieve a performance improvement, they MUST observe the TTL 4046 information reported by DNS. If NNTP clients or servers do not 4047 observe this rule, they could be spoofed when a previously accessed 4048 server's IP address changes. As network renumbering is expected to 4049 become increasingly common, the possibility of this form of attack 4050 will grow. Observing this requirement thus reduces this potential 4051 security vulnerability. 4053 This requirement also improves the load-balancing behaviour of 4054 clients for replicated servers using the same DNS name and reduces 4055 the likelihood of a user's experiencing failure in accessing sites 4056 that use that strategy. 4058 11.5 UTF-8 issues 4060 UTF-8 [RFC3629] permits only certain sequences of octets and 4061 designates others as either malformed or "illegal". The Unicode 4062 standard identifies a number of security issues related to illegal 4063 sequences and forbids their generation by conforming implementations. 4065 Implementations of this specification MUST NOT generate malformed or 4066 illegal sequences and SHOULD detect them and take some appropriate 4067 action. This could include: 4069 o generating a 501 response code. 4071 o replacing such sequences by the sequence %xEF.BF.BD, which encodes 4072 the "replacement character" U+FFFD; 4074 o closing the connection; 4076 o replacing such sequences by a "guessed" valid sequence (based on 4077 properties of the UTF-8 encoding); 4079 In the last case, the implementation MUST ensure that any replacement 4080 cannot be used to bypass validity or security checks. For example, 4081 the illegal sequence %xC0.A0 is an over-long encoding for space 4082 (%x20). If it is replaced by the latter in a command line, this needs 4083 to happen before the command line is parsed into individual 4084 arguments. If the replacement came after parsing, it would be 4085 possible to generate an argument with an embedded space, which is 4086 forbidden. Use of the "replacement character" does not have this 4087 problem, since it is permitted wherever non-US-ASCII characters are. 4088 Implementations SHOULD use one of the first two solutions where the 4089 general structure of the NNTP stream remains intact, and close the 4090 connection if it is no longer possible to parse it sensibly. 4092 11.6 Caching of LIST EXTENSIONS results 4094 The LIST EXTENSIONS command provides information about the extensions 4095 currently available from the server. Whenever there is a relevant 4096 change to the server state, the results of this command are required 4097 to change accordingly. 4099 In most situations the results from this command in a given server 4100 state will not change from session to session; a given extension will 4101 be installed permanently on a server. Some clients may therefore wish 4102 to remember which extensions a server supports to avoid the delay of 4103 an additional command and response, particularly if they open 4104 multiple connections in the same session. 4106 However, information about extensions related to security and privacy 4107 MUST NOT be cached, since this could allow a variety of attacks. 4109 For example, consider a server which permits the use of cleartext 4110 passwords on links that are encrypted but not otherwise: 4112 [Initial TCP connection set-up completed.] 4113 [S] 200 NNTP Service Ready, posting permitted 4114 [C] LIST EXTENSIONS 4115 [S] 202 Extensions supported: 4116 [S] XENCRYPT 4117 [S] . 4118 [C] XENCRYPT 4120 [Client and server negotiate encryption on the link] 4121 [S] 283 Encrypted link established 4122 [C] LIST EXTENSIONS 4123 [S] 202 Extensions supported: 4124 [S] XSECRET 4125 [S] . 4126 [C] XSECRET fred flintstone 4127 [S] 290 Password for fred accepted 4129 If the client caches the last LIST EXTENSIONS result, then on the 4130 next session it will attempt to use XSECRET on an unencrypted link: 4132 [Initial TCP connection set-up completed.] 4133 [S] 200 NNTP Service Ready, posting permitted 4134 [C] XSECRET fred flintstone 4135 [S] 483 Only permitted on secure links 4137 exposing the password to any eavesdropper. While the primary cause of 4138 this is passing a secret without first checking the security of the 4139 link, caching of LIST EXTENSIONS results can increase the risk. 4141 Any security extension should include requirements to check the 4142 security state of the link in a manner appropriate to that extension. 4144 Caching should normally only be considered for anonymous clients that 4145 do not use any security or privacy extensions and for which the time 4146 required for an additional command and response is a noticeable 4147 issue. 4149 12. Acknowledgements 4151 The author acknowledges the original authors of NNTP as documented in 4152 RFC 977 [RFC977]: Brian Kantor and Phil Lapsey. 4154 The author gratefully acknowledges the work of the NNTP committee 4155 chaired by Eliot Lear. The organization of this document was 4156 influenced by the last available draft from this working group. A 4157 special thanks to Eliot for generously providing the original 4158 machine-readable sources for that document. 4160 The author gratefully acknowledges the work of the DRUMS working 4161 group, specifically RFC 1869 [RFC1869], which is the basis of the 4162 NNTP extensions mechanism detailed in this document. 4164 The author gratefully acknowledges the authors of RFC 2616 [RFC2616] 4165 for providing specific and relevant examples of security issues that 4166 should be considered for HTTP. Since many of the same considerations 4167 exist for NNTP, those examples that are relevant have been included 4168 here with some minor rewrites. 4170 The author gratefully acknowledges the comments and additional 4171 information provided by the following individuals in preparing one or 4172 more of the progenitors of this document: 4174 Russ Allbery 4175 Wayne Davison 4176 Chris Lewis 4177 Tom Limoncelli 4178 Eric Schnoebelen 4179 Rich Salz 4181 This work was motivated by the work of various news reader authors 4182 and news server authors, which includes those listed below: 4184 Rick Adams 4185 Original author of the NNTP extensions to the RN news reader and 4186 last maintainer of Bnews 4188 Stan Barber 4189 Original author of the NNTP extensions to the news readers that 4190 are part of Bnews 4192 Geoff Collyer 4193 Original author of the OVERVIEW database proposal and one of the 4194 original authors of CNEWS 4196 Dan Curry 4197 Original author of the xvnews news reader 4199 Wayne Davison 4200 Author of the first threading extensions to the RN news reader 4201 (commonly called TRN) 4203 Geoff Huston 4204 Original author of ANU NEWS 4206 Phil Lapsey 4207 Original author of the UNIX reference implementation for NNTP 4209 Iain Lea 4210 Original maintainer of the TIN news reader 4212 Chris Lewis 4213 First known implementer of the AUTHINFO GENERIC extension 4215 Rich Salz 4216 Original author of INN 4218 Henry Spencer 4219 One of the original authors of CNEWS 4221 Kim Storm 4222 Original author of the NN news reader 4224 Finally, the present author gratefully acknowledges the vast amount 4225 of work put into previous drafts by the previous author: 4227 Stan Barber 4229 Normative References 4231 [ANSI1986] 4232 American National Standards Institute, "Coded Character 4233 Set - 7-bit American Standard Code for Information 4234 Interchange", ANSI X3.4, 1986. 4236 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 4237 Requirement Levels", BCP 14, RFC 2119, March 1997. 4239 [RFC2234] Crocker, D. and P. Overell, "Augmented BNF for Syntax 4240 Specifications: ABNF", RFC 2234, November 1997. 4242 [RFC3629] Yergeau, F., "UTF-8, a transformation format of ISO 4243 10646", STD 63, RFC 3629, November 2003. 4245 [RFC977] Kantor, B. and P. Lapsley, "Network News Transfer 4246 Protocol", RFC 977, February 1986. 4248 [TF.686-1] 4249 International Telecommunications Union - Radio, "Glossary, 4250 ITU-R Recommendation TF.686-1", ITU-R Recommendation 4251 TF.686-1, October 1997. 4253 Informative References 4255 [RFC1036] Horton, M. and R. Adams, "Standard for interchange of 4256 USENET messages", RFC 1036, December 1987. 4258 [RFC1305] Mills, D., "Network Time Protocol (Version 3) 4259 Specification, Implementation", RFC 1305, March 1992. 4261 [RFC1869] Klensin, J., Freed, N., Rose, M., Stefferud, E. and D. 4262 Crocker, "SMTP Service Extensions", STD 10, RFC 1869, 4263 November 1995. 4265 [RFC2616] Fielding, R., Gettys, J., Mogul, J., Nielsen, H., 4266 Masinter, L., Leach, P. and T. Berners-Lee, "Hypertext 4267 Transfer Protocol -- HTTP/1.1", RFC 2616, June 1999. 4269 [RFC2629] Rose, M., "Writing I-Ds and RFCs using XML", RFC 2629, 4270 June 1999. 4272 [RFC2822] Resnick, P., "Internet Message Format", RFC 2822, April 4273 2001. 4275 [RFC2980] Barber, S., "Common NNTP Extensions", RFC 2980, October 4276 2000. 4278 [ROBE1995] 4279 Robertson, R., "FAQ: Overview database / NOV General 4280 Information", January 1995. 4282 [SALZ1992] 4283 Salz, R., "Manual Page for wildmat(3) from the INN 1.4 4284 distribution, Revision 1.10", April 1992. 4286 Author's Address 4288 Clive D.W. Feather 4289 Thus plc 4290 322 Regents Park Road 4291 London N3 2QQ 4292 GB 4294 Phone: +44 20 8495 6138 4295 Fax: +44 870 051 9937 4296 EMail: clive@demon.net 4297 URI: http://www.davros.org/ 4299 Appendix A. Future Directions 4301 It has been proposed that the response code range 6xx be used for 4302 multiline responses. While existing commands and extensions do not 4303 use this, it would at least limit the problem clients would face in 4304 dealing with an unknown response. 4306 Appendix B. Interaction with other specifications 4308 NNTP is most often used for transferring articles that conform to RFC 4309 1036 [RFC1036] (such articles are called "Netnews articles" here). It 4310 is also sometimes used for transferring email messages that conform 4311 to RFC 2822 [RFC2822] (such articles are called "email articles" 4312 here). In this situation, articles must conform both to this 4313 specification and to that other one; this appendix describes some 4314 relevant issues. 4316 B.1 Header folding 4318 NNTP allows a header line to be folded (by inserting a CRLF pair) 4319 before any space or TAB character. 4321 Both email and Netnews articles are required to have at least one 4322 octet other than space or TAB on each header line. Thus folding can 4323 only happen at one point in each sequence of consecutive spaces or 4324 TABs. Netnews articles are further required to have the header name, 4325 colon, and following space all on the first line; folding may only 4326 happen beyond that space. Finally, some non-conforming software will 4327 remove trailing spaces and TABs from a line. Therefore it might be 4328 inadvisable to fold a header after a space or TAB. 4330 For maximum safety, header lines SHOULD conform to the following 4331 syntax rather than that in Section 9.4. 4333 header = header-name ":" SP [header-content] CRLF 4334 header-content = [WS] 1*P-CHAR *( [CRLF] WS 1*P-CHAR ) 4336 B.2 Message-IDs 4338 Every article handled by an NNTP server MUST have a unique 4339 message-id. For the purposes of this specification, a message-id is 4340 an arbitrary opaque string that merely needs to meet certain 4341 syntactic requirements and is just a way to refer to the article. 4343 Because there is a significant risk of old articles being reinjected 4344 into the global Usenet system, RFC 1036 [RFC1036] requires that 4345 message-ids are globally unique for all time. 4347 This specification states that message-ids are the same if and only 4348 if they consist of the same sequence of octets. Other specifications 4349 may define two different sequences as being equal because they are 4350 putting an interpretation on particular characters. RFC 2822 4351 [RFC2822] has a concept of "quoted" and "escaped" characters. It 4352 therefore considers the three message-ids: 4354 4355 <"abcd"@example.com> 4356 <"ab\cd"@example.com> 4358 as being identical. Therefore an NNTP implementation handing email 4359 articles must ensure that only one of these three appears in the 4360 protocol and the other two are converted to it as and when necessary, 4361 such as when a client checks the results of a NEWNEWS command against 4362 an internal database of message-ids. Note that RFC 1036 [RFC1036] 4363 never treats two different strings as being identical. Its draft 4364 successor restricts the syntax of message-ids so that, whenever RFC 4365 2822 would treat two strings as equivalent, only one of them is valid 4366 (in the above example only the first string is valid). 4368 This specification does not describe how the message-id of an article 4369 is determined; it may be deduced from the contents of the article or 4370 derived from some external source. If the server is also conforming 4371 to another specification that contains a definition of message-id 4372 compatible with this one, the server SHOULD use those message-ids. A 4373 common approach, and one that SHOULD be used for email and Netnews 4374 articles, is to extract the message-id from the contents of a header 4375 with name "Message-ID". This may not be as simple as copying the 4376 entire header contents; it may be necessary to strip off comments and 4377 undo quoting, or to reduce "equivalent" message-ids to a canonical 4378 form. 4380 If an article is obtained through the IHAVE command, there will be a 4381 message-id provided with the command. The server MAY either use it or 4382 determine one from the article contents. However, whichever it does 4383 it SHOULD ensure that, if the IHAVE command is repeated with the same 4384 argument and article, it will be recognized as a duplicate. 4386 If an article does not contain a message-id that the server can 4387 identify, it MUST synthesize one. This could, for example, be a 4388 simple sequence number or based on the date and time that the article 4389 arrived. When handling email or Netnews articles, a Message-ID header 4390 SHOULD be added to ensure global consistency and uniqueness. 4392 B.3 Article posting 4394 As far as NNTP is concerned, the POST and IHAVE commands provide the 4395 same basic facilities in a slightly different way. However they have 4396 rather different intentions. 4398 The IHAVE command is intended for transmitting conforming articles 4399 between a system of NNTP servers, with all articles perhaps also 4400 conforming to another specification (e.g. all articles are Netnews 4401 articles). It is expected that the client will have already done any 4402 necessary validation (or has in turn obtained the article from a 4403 third party which has done so); therefore the contents SHOULD be left 4404 unchanged. 4406 In contrast, the POST command is intended for use when an end-user is 4407 injecting a newly-created article into a such a system. The article 4408 being transferred might not be a conforming email or Netnews article, 4409 and the server is expected to validate it and, if necessary, convert 4410 it to the right form for onward distribution. It is often the case 4411 that this is done by a separate piece of software on the server 4412 installation. If so, the NNTP server SHOULD pass the incoming article 4413 to that software unaltered, making no attempt to filter characters, 4414 fold or limit lines, or otherwise process the incoming text. 4416 The POST command can fail in various ways and clients should be 4417 prepared to re-send an article. When doing so, however, it is often 4418 important to ensure - as far as possible - that the same message-id 4419 is allocated to both attempts so that the server, or other servers, 4420 can recognize the two articles as being duplicates. In the case of 4421 email or Netnews articles, therefore, the posted article SHOULD 4422 contain a header with name "Message-ID" and the contents of this 4423 header SHOULD be identical on each attempt. The server SHOULD ensure 4424 that two POSTed articles with the same contents for this header are 4425 recognized as identical and the same message-id allocated, whether or 4426 not those contents are suitable for use as the message-id. 4428 Appendix C. Summary of Response Codes 4430 This section contains a list of every response code defined in this 4431 document, whether it is multi-line, which commands can generate it, 4432 what arguments it has, and what its meaning is. 4434 Response code 100 (multi-line) 4435 Generated by: HELP 4436 Meaning: help text follows. 4438 Response code 111 4439 Generated by: DATE 4440 1 argument: yyyymmddhhmmss 4441 Meaning: server date and time. 4443 Response code 200 4444 Generated by: initial connection, MODE READER 4445 Meaning: service available, posting allowed. 4447 Response code 201 4448 Generated by: initial connection, MODE READER 4449 Meaning: service available, posting prohibited. 4451 Response code 202 (multi-line) 4452 Generated by: LIST EXTENSIONS 4453 Meaning: extension list follows. 4455 Response code 205 4456 Generated by: QUIT 4457 Meaning: connection closing (the server immediately closes the 4458 connection). 4460 Response code 211 4461 The 211 response code has two completely different forms depending 4462 on which command generated it: 4464 Generated by: GROUP 4465 4 arguments: number low high group 4466 Meaning: group selected. 4468 (multi-line) 4469 Generated by: LISTGROUP 4470 Meaning: article numbers follow. 4472 Response code 215 (multi-line) 4473 Generated by: LIST ACTIVE, LIST ACTIVE.TIMES, LIST DISTRIB.PATS, 4474 LIST DISTRIBUTIONS, LIST HEADERS, LIST NEWSGROUPS, 4475 LIST OVERVIEW.FMT 4476 Meaning: information follows. 4478 Response code 220 (multi-line) 4479 Generated by: ARTICLE 4480 2 arguments: n message-id 4481 Meaning: article follows. 4483 Response code 221 (multi-line) 4484 Generated by: HEAD 4485 2 arguments: n message-id 4486 Meaning: article headers follow. 4488 Response code 222 (multi-line) 4489 Generated by: BODY 4490 2 arguments: n message-id 4491 Meaning: article body follows. 4493 Response code 223 4494 Generated by: LAST, NEXT, STAT 4495 2 arguments: n message-id 4496 Meaning: article exists and selected. 4498 Response code 224 (multi-line) 4499 Generated by: OVER 4500 Meaning: overview information follows. 4502 Response code 225 (multi-line) 4503 Generated by: HDR 4504 Meaning: headers follow. 4506 Response code 230 (multi-line) 4507 Generated by: NEWNEWS 4508 Meaning: list of new articles follows. 4510 Response code 231 (multi-line) 4511 Generated by: NEWGROUPS 4512 Meaning: list of new newsgroups follows. 4514 Response code 235 4515 Generated by: IHAVE (second stage) 4516 Meaning: article transferred OK. 4518 Response code 240 4519 Generated by: POST (second stage) 4520 Meaning: article received OK. 4522 Response code 335 4523 Generated by: IHAVE (first stage) 4524 Meaning: send article to be transferred. 4526 Response code 340 4527 Generated by: POST (first stage) 4528 Meaning: send article to be posted. 4530 Response code 400 4531 Generic response and generated by initial connection 4532 Meaning: service not available or no longer available (the server 4533 immediately closes the connection). 4535 Response code 401 4536 Generic response 4537 1 argument: extension-label 4538 Meaning: the server is in the wrong mode; the indicated extension 4539 should be used to change the mode. 4541 Response code 402 4542 Generated by: LIST EXTENSIONS 4543 Meaning: server has no extensions. 4545 Response code 403 4546 Generic response 4547 Meaning: internal fault or problem preventing action being taken. 4549 Response code 411 4550 Generated by: GROUP, LISTGROUP 4551 Meaning: no such newsgroup. 4553 Response code 412 4554 Generated by: ARTICLE, BODY, HDR, HEAD, LAST, LISTGROUP, NEXT, 4555 OVER, STAT 4556 Meaning: no newsgroup selected. 4558 Response code 420 4559 Generated by: ARTICLE, BODY, HDR, HEAD, LAST, NEXT, OVER, STAT 4560 Meaning: current article number is invalid. 4562 Response code 421 4563 Generated by: NEXT 4564 Meaning: no next article in this group. 4566 Response code 422 4567 Generated by: LAST 4568 Meaning: no previous article in this group. 4570 Response code 423 4571 Generated by: ARTICLE, BODY, HDR, HEAD, OVER, STAT 4572 Meaning: no articles in that range. 4574 Response code 430 4575 Generated by: ARTICLE, BODY, HDR, HEAD, OVER, STAT 4576 Meaning: no article with that message-id. 4578 Response code 435 4579 Generated by: IHAVE (first stage) 4580 Meaning: article not wanted. 4582 Response code 436 4583 Generated by: IHAVE (either stage) 4584 Meaning: transfer not possible (first stage) or failed (second 4585 stage); try again later. 4587 Response code 437 4588 Generated by: IHAVE (second stage) 4589 Meaning: transfer rejected; do not retry. 4591 Response code 440 4592 Generated by: POST (first stage) 4593 Meaning: posting not permitted. 4595 Response code 441 4596 Generated by: POST (second stage) 4597 Meaning: posting failed. 4599 Response code 480 4600 Generic response 4601 Meaning: command unavailable until the client has authenticated 4602 itself. 4604 Response code 483 4605 Generic response 4606 Meaning: command unavailable until suitable privacy has been 4607 arranged. 4609 Response code 500 4610 Generic response 4611 Meaning: unknown command. 4613 Response code 501 4614 Generic response 4615 Meaning: syntax error in command. 4617 Response code 502 4618 Generic response and generated by initial connection 4619 Meaning for the initial connection and the MODE READER command: 4620 service permanently unavailable (the server immediately closes the 4621 connection). 4622 Meaning for all other commands: command not permitted (and there 4623 is no way for the client to change this). 4625 Response code 503 4626 Generic response 4627 Meaning: feature not supported. 4629 Appendix D. Formal specification of the standard extensions 4631 This section gives a formal definition of each of the extensions in 4632 Section 8.2 as required by Section 8 for the IANA registry. 4634 D.1 The LISTGROUP extension 4636 o This extension provides information about specific article 4637 numbers. 4639 o The extension-label is "LISTGROUP". 4641 o The extension-label has no arguments. 4643 o The extension defines one new command: LISTGROUP, whose behaviour, 4644 arguments, and responses are defined in Section 8.3. 4646 o The extension does not associate any new responses with 4647 pre-existing NNTP commands. 4649 o The extension does not affect the behaviour of a server or client 4650 other than via the new command. 4652 o The extension does not affect the maximum length of commands and 4653 initial response lines. 4655 o The extension does not alter pipelining, and the LISTGROUP command 4656 can be pipelined. 4658 o Use of this extension does not alter the output from LIST 4659 EXTENSIONS. 4661 o The extension does not cause any pre-existing command to produce a 4662 401, 480, or 483 response. 4664 o The LISTGROUP command can only be used after the MODE READER 4665 command. 4667 D.2 The OVER extension 4669 o This extension provides support for an overview of newsgroups. 4671 o The extension-label is "OVER". 4673 o The extension-label has the optional argument "MSGID", indicating 4674 that the message-id variant of the OVER command is supported. 4676 o The extension defines two new commands: OVER and LIST 4677 OVERVIEW.FMT, whose behaviour, arguments, and responses are 4678 defined in Section 8.5. 4680 o The extension does not associate any new responses with 4681 pre-existing NNTP commands. 4683 o The extension requires the server to maintain an overview database 4684 and article metadata, as described in Section 8.4. 4686 o The extension does not affect the maximum length of commands and 4687 initial response lines. 4689 o The extension does not alter pipelining, and the OVER and LIST 4690 OVERVIEW.FMT commands can be pipelined. 4692 o Use of this extension does not alter the output from LIST 4693 EXTENSIONS. 4695 o The extension does not cause any pre-existing command to produce a 4696 401, 480, or 483 response. 4698 o The OVER and LIST OVERVIEW.FMT commands can only be used after the 4699 MODE READER command. 4701 D.3 The HDR extension 4703 o This extension provides batched header retrieval. 4705 o The extension-label is "HDR". 4707 o The extension-label has no arguments. 4709 o The extension defines two new commands: HDR and LIST HEADERS, 4710 whose behaviour, arguments, and responses are defined in Section 4711 8.6. 4713 o The extension does not associate any new responses with 4714 pre-existing NNTP commands. 4716 o The extension requires the server to maintain article metadata, as 4717 described in Section 8.4. 4719 o The extension does not affect the maximum length of commands and 4720 initial response lines. 4722 o The extension does not alter pipelining, and the HDR and LIST 4723 HEADERS commands can be pipelined. 4725 o Use of this extension does not alter the output from LIST 4726 EXTENSIONS. 4728 o The extension does not cause any pre-existing command to produce a 4729 401, 480, or 483 response. 4731 o The HDR and LIST HEADERS commands can only be used after the MODE 4732 READER command. 4734 Intellectual Property Statement 4736 The IETF takes no position regarding the validity or scope of any 4737 Intellectual Property Rights or other rights that might be claimed to 4738 pertain to the implementation or use of the technology described in 4739 this document or the extent to which any license under such rights 4740 might or might not be available; nor does it represent that it has 4741 made any independent effort to identify any such rights. Information 4742 on the IETF's procedures with respect to rights in IETF Documents can 4743 be found in BCP 78 and BCP 79. 4745 Copies of IPR disclosures made to the IETF Secretariat and any 4746 assurances of licenses to be made available, or the result of an 4747 attempt made to obtain a general license or permission for the use of 4748 such proprietary rights by implementers or users of this 4749 specification can be obtained from the IETF on-line IPR repository at 4750 http://www.ietf.org/ipr. 4752 The IETF invites any interested party to bring to its attention any 4753 copyrights, patents or patent applications, or other proprietary 4754 rights that may cover technology that may be required to implement 4755 this standard. Please address the information to the IETF at 4756 ietf-ipr@ietf.org. 4758 Disclaimer of Validity 4760 This document and the information contained herein are provided on an 4761 "AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS 4762 OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY AND THE INTERNET 4763 ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS OR IMPLIED, 4764 INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE 4765 INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED 4766 WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 4768 Copyright Statement 4770 Copyright (C) The Internet Society (2004). This document is subject 4771 to the rights, licenses and restrictions contained in BCP 78, and 4772 except as set forth therein, the authors retain all their rights. 4774 Acknowledgment 4776 Funding for the RFC Editor function is currently provided by the 4777 Internet Society.