[Python-bugs-list] [Bug #124344] smtplib quoteaddr() has problems with RFC821 source routing

noreply@sourceforge.net noreply@sourceforge.net
Thu, 01 Feb 2001 10:06:38 -0800


Bug #124344, was updated on 2000-Dec-04 02:50
Here is a current snapshot of the bug.

Project: Python
Category: Python Library
Status: Closed
Resolution: Later
Bug Group: None
Priority: 2
Submitted by: carey
Assigned to : bwarsaw
Summary: smtplib quoteaddr() has problems with RFC821 source routing

Details: RFC821 defines source routed SMTP addresses of the form
<@USC-ISIE.ARPA:JQP@MIT-AI.ARPA>.  RFC1123 (STD3) deprecates these kinds of
addresses, but does not forbid them.

If an address like this is passed to smtplib.quoteaddr(), the result is
'<@USC-ISIE.ARPA>', which is useless, and illegal according to RFC821. 
smtplib should probably leave the source routing there, assuming anyone
using an address like this knows what they're doing, and since any SMTP
server "MUST" still accept this syntax.

Alternatively, smtplib could just refuse to deliver to an address like
this, with some justification.  (RFC1123 section 5.2.19.)

In any case, this isn't very important at all.  I'll probably write a patch
when I have some time, using one of the two solutions outlined above.


Follow-Ups:

Date: 2001-Feb-01 10:06
By: bwarsaw

Comment:
While I can appreciate the bug, I don't think it's important enough for us
to spend time working out a fix.  However, I will be more than happy to
review a patch contribution.

I'm going to close this with a resolution of "Later" so we can re-address
it when/if a patch is submitted.
-------------------------------------------------------

Date: 2000-Dec-15 13:36
By: nobody

Comment:
it's not just source routed addresses -- it's any address with more than
one @ sign.  here's another case that needs fixing.

>>> quoteaddr('"/dd.NOTES=CN$=Claudio
Alves$/OU$=RioJaneiro$/O$=ErnstYoung$/C$=BR@EYI-AMERICAS/"@ah01.uk.eyi.com')

'</dd.NOTES=CN$=Claudio
Alves$/OU$=RioJaneiro$/O$=ErnstYoung$/C$=BR@EYI-AMERICAS/@ah01.uk.eyi.com>'

>>> quoteaddr(quoteaddr('"/dd.NOTES=CN$=Claudio
Alves$/OU$=RioJaneiro$/O$=ErnstYoung$/C$=BR@EYI-AMERICAS/"@ah01.uk.eyi.com'))

'</dd.NOTES=CN$=ClaudioAlves$/OU$=RioJaneiro$/O$=ErnstYoung$/C$=BR@EYI-AMERICAS/>'

-------------------------------------------------------

Date: 2000-Dec-06 11:58
By: fdrake

Comment:
Assigned to the mail guy.
-------------------------------------------------------

For detailed info, follow this link:
http://sourceforge.net/bugs/?func=detailbug&bug_id=124344&group_id=5470