This issue tracker has been migrated to GitHub ,
and is currently read-only.
For more information,
see the GitHub FAQs in the Python's Developer Guide.
Created on 2008年07月28日 22:08 by dmorr, last changed 2022年04月11日 14:56 by admin.
| Files | ||||
|---|---|---|---|---|
| File name | Uploaded | Description | Edit | |
| python_smtplib.patch | dmorr, 2008年07月28日 22:08 | review | ||
| smtplib.patch | dmorr, 2010年07月05日 02:27 | review | ||
| Messages (7) | |||
|---|---|---|---|
| msg70372 - (view) | Author: Derek Morr (dmorr) | Date: 2008年07月28日 22:08 | |
On an IPv6-only machine, smtplib does not send an IPv6 address in the EHLO. It sends "EHLO [0.0.0.0]" instead. For example, on a v6-only network with stateless autoconfiguration enabled (a common configuration), smtplib will show this error. Further, SMTP's __init__() method tries to determine the value of EHLO parameter before the socket is established. But it can't know what value to use before the socket is setup (e.g., should it use a hostname, a v4 address literal, or a v6 address literal). The attached patch moves the self.local_hostname processing into the connect() method, and updates it to use IPv6-aware resolver interfaces. |
|||
| msg109271 - (view) | Author: Mark Lawrence (BreamoreBoy) * | Date: 2010年07月04日 22:22 | |
I intended testing this but the patch file appears to have a dangling else at the bottom, or am I missing something? |
|||
| msg109288 - (view) | Author: Derek Morr (dmorr) | Date: 2010年07月05日 02:27 | |
You're right. My mistake when I made the patch. I've attached a new one without the trailing else |
|||
| msg109414 - (view) | Author: Mark Lawrence (BreamoreBoy) * | Date: 2010年07月06日 18:15 | |
Ran test_smtplib.py for Python 2.7 and 3.1.2 on Windows Vista all tests passed. |
|||
| msg109422 - (view) | Author: R. David Murray (r.david.murray) * (Python committer) | Date: 2010年07月06日 20:32 | |
The patch still needs unit tests. |
|||
| msg110133 - (view) | Author: Derek Morr (dmorr) | Date: 2010年07月12日 20:23 | |
I'm not sure how to best write a unit test for this. The patch should only be invoked if the client doesn't have a name-served hostname and has IPv6 enabled. Also, there are several IPv4-isms in the smtplib tests. |
|||
| msg110137 - (view) | Author: Giampaolo Rodola' (giampaolo.rodola) * (Python committer) | Date: 2010年07月12日 20:52 | |
You might want to take a look at Lib/test/test_ftplib.py which contains IPv6 tests including the necessary logic to decide whether or not running them. |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:56:37 | admin | set | github: 47711 |
| 2020年11月11日 00:41:13 | iritkatriel | set | versions: + Python 3.8, Python 3.9, Python 3.10, - Python 3.1, Python 2.7, Python 3.2 |
| 2014年02月03日 18:41:59 | BreamoreBoy | set | nosy:
- BreamoreBoy |
| 2013年01月23日 15:09:04 | r.david.murray | set | nosy:
+ barry components: + email |
| 2010年07月12日 20:52:10 | giampaolo.rodola | set | messages: + msg110137 |
| 2010年07月12日 20:23:29 | dmorr | set | messages: + msg110133 |
| 2010年07月09日 00:29:12 | pitrou | set | nosy:
+ giampaolo.rodola |
| 2010年07月06日 20:32:31 | r.david.murray | set | nosy:
+ r.david.murray messages: + msg109422 stage: commit review -> test needed |
| 2010年07月06日 18:15:39 | BreamoreBoy | set | messages:
+ msg109414 stage: test needed -> commit review |
| 2010年07月05日 14:44:39 | r.david.murray | set | versions: + Python 2.7 |
| 2010年07月05日 14:44:30 | r.david.murray | set | versions: + Python 3.2 |
| 2010年07月05日 14:38:35 | r.david.murray | set | stage: test needed |
| 2010年07月05日 02:27:12 | dmorr | set | files:
+ smtplib.patch messages: + msg109288 |
| 2010年07月04日 22:22:35 | BreamoreBoy | set | nosy:
+ BreamoreBoy messages: + msg109271 |
| 2008年07月28日 22:08:44 | dmorr | create | |