Re: [Exim] Return code from EXPN

Góra strony
Delete this message
Reply to this message
Autor: Philip Hazel
Data:  
Dla: Anjan Sen
CC: exim-users
Temat: Re: [Exim] Return code from EXPN
On Mon, 15 Jul 2002, Anjan Sen wrote:

> When Exim 4.05 refuses an EXPN, it returns a 550 code. Since 550 usually
> means something like 'mailbox not found', is 550 the most appropriate code?
> Sendmail, qmail and postfix all seem to return 502. Should Exim do the same?


From RFC 2821:

      550 Requested action not taken: mailbox unavailable
         (e.g., mailbox not found, no access, or command rejected
         for policy reasons)


"Command rejected for policy reasons" is exactly right, it seems to me.
On the other hand

      502 Command not implemented (see section 4.2.4)


isn't right, because the command *is* implemented. The RFC goes on to say

4.2.4 Reply Code 502

Questions have been raised as to when reply code 502 (Command not
implemented) SHOULD be returned in preference to other codes. 502
SHOULD be used when the command is actually recognized by the SMTP
server, but not implemented. If the command is not recognized, code
500 SHOULD be returned. Extended SMTP systems MUST NOT list
capabilities in response to EHLO for which they will return 502 (or
500) replies.

I conclude that 550 is the correct code for Exim to return.


--
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.