Skip to content

Commit

Permalink
Merge pull request #379 from adamleko/master
Browse files Browse the repository at this point in the history
Enable hostname verification with verify option
  • Loading branch information
xzkostyan committed May 24, 2023
2 parents 18f28c6 + 5b25ab3 commit 1896173
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions clickhouse_driver/connection.py
Original file line number Diff line number Diff line change
Expand Up @@ -303,6 +303,7 @@ def _create_ssl_context(self, ssl_options):

version = ssl_options.get('ssl_version', ssl.PROTOCOL_TLS)
context = ssl.SSLContext(version)
context.check_hostname = self.verify_cert

if 'ca_certs' in ssl_options:
context.load_verify_locations(ssl_options['ca_certs'])
Expand Down

0 comments on commit 1896173

Please sign in to comment.