summaryrefslogtreecommitdiffstats
path: root/Lib/smtplib.py
diff options
context:
space:
mode:
authorGregory P. Smith <greg@mad-scientist.com>2008-01-17 07:43:20 (GMT)
committerGregory P. Smith <greg@mad-scientist.com>2008-01-17 07:43:20 (GMT)
commit63bfc1d19fa1abe7d1b7d3e25a17083f8077f6fa (patch)
tree382f169cef22f95f7d005a3b59ad0d7bb0232721 /Lib/smtplib.py
parent473170908e11e347aca4adf23738a82162b981e3 (diff)
downloadcpython-63bfc1d19fa1abe7d1b7d3e25a17083f8077f6fa.zip
cpython-63bfc1d19fa1abe7d1b7d3e25a17083f8077f6fa.tar.gz
cpython-63bfc1d19fa1abe7d1b7d3e25a17083f8077f6fa.tar.bz2
Comply with RFC 3207.
Fixes issue 829951 - http://bugs.python.org/issue829951
Diffstat (limited to 'Lib/smtplib.py')
-rwxr-xr-xLib/smtplib.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/Lib/smtplib.py b/Lib/smtplib.py
index 5604241..97b1e20 100755
--- a/Lib/smtplib.py
+++ b/Lib/smtplib.py
@@ -589,6 +589,14 @@ class SMTP:
raise RuntimeError("No SSL support included in this Python")
self.sock = ssl.wrap_socket(self.sock, keyfile, certfile)
self.file = SSLFakeFile(self.sock)
+ # RFC 3207:
+ # The client MUST discard any knowledge obtained from
+ # the server, such as the list of SMTP service extensions,
+ # which was not obtained from the TLS negotiation itself.
+ self.helo_resp = None
+ self.ehlo_resp = None
+ self.esmtp_features = {}
+ self.does_esmtp = 0
return (resp, reply)
def sendmail(self, from_addr, to_addrs, msg, mail_options=[],