Fix issue #9711: raise ValueError is SSLConnection constructor is invoked with keyfile and not certfile.
diff --git a/Lib/ssl.py b/Lib/ssl.py
index a634442..e83d889 100644
--- a/Lib/ssl.py
+++ b/Lib/ssl.py
@@ -125,6 +125,8 @@
             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)