[Top] [All Lists]

Re: 2821bis: three-digit-and-crlf replies

2007-06-12 13:30:15

Peter J. Holzer writes:
I don't think so. Section 4.2 says:

|                    Formally, a reply is defined to be the sequence: a
|  three-digit code, <SP>, one line of text, and <CRLF>, or a multiline
|  reply (as defined in section 4.2.1).  Since, in violation of this
|  specification, the text is sometimes not sent, clients which do not
|  receive it SHOULD be prepared to process the code alone (with or
|  without a trailing space character).

To me that means that "250"CRLF is not permitted, but a frequent bug which clients should handle gracefully.

2821 has this grammar:

      Reply-line = Reply-code [ SP text ] CRLF

draft-klensin has this:

   Reply-line     = *( Reply-code "-" [ text ] CRLF )
                  Reply-code [ SP text ] CRLF

The text you quite indicates "Reply-code SP [ text ] CRLF", at least when I read it, but the grammar puts the SP inside the optional part in both cases.