Opened 8 years ago

Closed 8 years ago

#5769 enhancement closed duplicate (duplicate)

IMessage.eomReceived cannot determine the response code of the SMTP server

Reported by: Itamar Turner-Trauring Owned by:
Priority: normal Milestone:
Component: mail Keywords:
Cc: Branch:


I would like to return a custom error response code from the SMTP server at the end of message processing (i.e. the final '.'). However, the SMTP server code (SMTP._messageHandled) does not look at the contents of response from eomReceived, it simply checks if there were any errors and if so returns a hard-coded 550 error. It would be nice if SMTPServerError errors returned from eomReceived would be transmitted back to the client (or at least, the first one).

Change History (2)

comment:1 Changed 8 years ago by Jean-Paul Calderone

Note that "or at least, the first one" is an important part of the current behavior. The opportunity exists for the application to generate multiple errors, but the protocol only supports one response. So the current behavior really is intentional. An attempt to change this should address the mismatch between the API and the protocol in a more sophisticated way than just "use the first, discard the rest".

comment:2 Changed 8 years ago by Jean-Paul Calderone

Resolution: duplicate
Status: newclosed

Duplicate of #4904.

Note: See TracTickets for help on using tickets.