diff options
author | Giampaolo RodolĂ <g.rodola@gmail.com> | 2010-08-30 18:28:05 (GMT) |
---|---|---|
committer | Giampaolo RodolĂ <g.rodola@gmail.com> | 2010-08-30 18:28:05 (GMT) |
commit | 8b7da623ceb1e37d757cef95204c2384e1044a44 (patch) | |
tree | d6d5ac714496dd1f7d8042d9a6c9f43a6e264cb5 /Lib/ssl.py | |
parent | 40d9a4e854d71a9c307f4f92a1e8336b4714a3c8 (diff) | |
download | cpython-8b7da623ceb1e37d757cef95204c2384e1044a44.zip cpython-8b7da623ceb1e37d757cef95204c2384e1044a44.tar.gz cpython-8b7da623ceb1e37d757cef95204c2384e1044a44.tar.bz2 |
Fix issue #9711: raise ValueError is SSLConnection constructor is invoked with keyfile and not certfile.
Diffstat (limited to 'Lib/ssl.py')
-rw-r--r-- | Lib/ssl.py | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -125,6 +125,8 @@ class SSLSocket(socket): if server_side and not certfile: raise ValueError("certfile must be specified for server-side " "operations") + if keyfile and not certfile: + raise ValueError("certfile must be specified") if certfile and not keyfile: keyfile = certfile self.context = SSLContext(ssl_version) |