Skip to content

Driver does not set SSL certificate authentication header #554

@ekpdt

Description

@ekpdt

Describe the bug

It should be possible to use SSL certificate authentication with ClickHouse via the odbc driver. If the PrivateKeyFile and CertificateFile parameters (or just the PrivateKey field on Windows) are set (and/or some new parameter SSLAuth is set), then the driver should signal to ClickHouse that SSL certificate authentication is desired.

The ClickHouse HTTP server interface requires X-ClickHouse-SSL-Certificate-Auth to be set for certificate authentication to be enabled.

Steps to reproduce

  1. Create an ODBC DSN with PrivateKeyFile (and CertificateFile) parameters set
  2. Attempt a connection
  3. Get the error Authentication failed: password is incorrect, or there is no user with such name. (AUTHENTICATION_FAILED) or similar because the ClickHouse server did not attempt certificate authentication.

Expected behaviour

Certificate authentication is performed.

Configuration

Environment

  • Driver version: 1.5.0
  • OS: Windows
  • ODBC Driver manager: ODBC Administrator

ClickHouse server

  • ClickHouse Server version: 26.1.2

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions