summaryrefslogtreecommitdiffstats
path: root/Lib/ftplib.py
diff options
context:
space:
mode:
authorBenjamin Peterson <benjamin@python.org>2014-12-30 21:16:13 (GMT)
committerBenjamin Peterson <benjamin@python.org>2014-12-30 21:16:13 (GMT)
commitbfdec6263f7ad9965d3c15f0535a7a08ac805af1 (patch)
tree2bfb68e4bb78748863a0a0713a0e374637d1b143 /Lib/ftplib.py
parent5d4e27ecee12c2c2dc33b31a6128bcf4297574ac (diff)
parent36fe7926f888ba154b64904b91a5dd8c83e6c167 (diff)
downloadcpython-bfdec6263f7ad9965d3c15f0535a7a08ac805af1.zip
cpython-bfdec6263f7ad9965d3c15f0535a7a08ac805af1.tar.gz
cpython-bfdec6263f7ad9965d3c15f0535a7a08ac805af1.tar.bz2
merge 3.4 (#23111)
Diffstat (limited to 'Lib/ftplib.py')
-rw-r--r--Lib/ftplib.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/ftplib.py b/Lib/ftplib.py
index 2f084d0..135ec9c 100644
--- a/Lib/ftplib.py
+++ b/Lib/ftplib.py
@@ -713,7 +713,7 @@ else:
'221 Goodbye.'
>>>
'''
- ssl_version = ssl.PROTOCOL_TLSv1
+ ssl_version = ssl.PROTOCOL_SSLv23
def __init__(self, host='', user='', passwd='', acct='', keyfile=None,
certfile=None, context=None,
@@ -743,7 +743,7 @@ else:
'''Set up secure control connection by using TLS/SSL.'''
if isinstance(self.sock, ssl.SSLSocket):
raise ValueError("Already using TLS")
- if self.ssl_version == ssl.PROTOCOL_TLSv1:
+ if self.ssl_version >= ssl.PROTOCOL_SSLv23:
resp = self.voidcmd('AUTH TLS')
else:
resp = self.voidcmd('AUTH SSL')