mirror of https://github.com/python/cpython.git
merge 3.4 (#23111)
This commit is contained in:
commit
bfdec6263f
|
@ -713,7 +713,7 @@ class FTP_TLS(FTP):
|
||||||
'221 Goodbye.'
|
'221 Goodbye.'
|
||||||
>>>
|
>>>
|
||||||
'''
|
'''
|
||||||
ssl_version = ssl.PROTOCOL_TLSv1
|
ssl_version = ssl.PROTOCOL_SSLv23
|
||||||
|
|
||||||
def __init__(self, host='', user='', passwd='', acct='', keyfile=None,
|
def __init__(self, host='', user='', passwd='', acct='', keyfile=None,
|
||||||
certfile=None, context=None,
|
certfile=None, context=None,
|
||||||
|
@ -743,7 +743,7 @@ def auth(self):
|
||||||
'''Set up secure control connection by using TLS/SSL.'''
|
'''Set up secure control connection by using TLS/SSL.'''
|
||||||
if isinstance(self.sock, ssl.SSLSocket):
|
if isinstance(self.sock, ssl.SSLSocket):
|
||||||
raise ValueError("Already using TLS")
|
raise ValueError("Already using TLS")
|
||||||
if self.ssl_version == ssl.PROTOCOL_TLSv1:
|
if self.ssl_version >= ssl.PROTOCOL_SSLv23:
|
||||||
resp = self.voidcmd('AUTH TLS')
|
resp = self.voidcmd('AUTH TLS')
|
||||||
else:
|
else:
|
||||||
resp = self.voidcmd('AUTH SSL')
|
resp = self.voidcmd('AUTH SSL')
|
||||||
|
|
|
@ -207,6 +207,9 @@ Library
|
||||||
- Issue #23093: In the io, module allow more operations to work on detached
|
- Issue #23093: In the io, module allow more operations to work on detached
|
||||||
streams.
|
streams.
|
||||||
|
|
||||||
|
- Issue #23111: In the ftplib, make ssl.PROTOCOL_SSLv23 the default protocol
|
||||||
|
version.
|
||||||
|
|
||||||
- Issue #22585: On OpenBSD 5.6 and newer, os.urandom() now calls getentropy(),
|
- Issue #22585: On OpenBSD 5.6 and newer, os.urandom() now calls getentropy(),
|
||||||
instead of reading /dev/urandom, to get pseudo-random bytes.
|
instead of reading /dev/urandom, to get pseudo-random bytes.
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue