Created
May 9, 2013 18:28
-
-
Save mfks17/5549477 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@@ -64,8 +64,8 @@ def _ValidateCertificateHostname(self, cert, hostname): | |
return False | |
def connect(self): | |
- sock = socket.create_connection((self.host, self.port)) | |
- self.sock = ssl.wrap_socket(sock, keyfile=self.key_file, | |
+ httplib.HTTPConnection.connect(self) | |
+ self.sock = ssl.wrap_socket(self.sock, keyfile=self.key_file, | |
certfile=self.cert_file, | |
cert_reqs=self.cert_reqs, | |
ca_certs=self.ca_certs) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment