[CONC-639] Unable to connect to SSL using client certificates SEC_E_ALGORITHM_MISMATCH Created: 2023-03-12  Updated: 2023-11-12

Status: Stalled
Project: MariaDB Connector/C
Component/s: TLS/SSL
Affects Version/s: None
Fix Version/s: 3.3

Type: Bug Priority: Major
Reporter: Lotendan Assignee: Georg Richter
Resolution: Unresolved Votes: 6
Labels: None

Attachments: Zip Archive wireshark_capture.zip    
Issue Links:
Relates
relates to CONC-527 Connect error "SEC_E_ALGORITHM_MISMAT... Closed
relates to CONC-653 TLS v1.3 support in Schannel Open

 Description   

Hello,

I have set up a secure SSL connection between a Mariadb client and a Mariadb server. I use HeidiSQL client (compiled with MariaDB Connector C).

When upgrading the server from OpenSSL 2.x to the latest version of OpenSSL 3.x, the client will refuse to connect and closes the connection with error: SEC_E_ALGORITHM_MISMATCH.

The logs of the server are not helpful either. The server only sees an aborted connection from the client.

Aborted connection 3 to db: 'unconnected' user: 'unauthenticated' host: '192.168.1.61' (This connection closed normally without authentication).

I initially submitted a ticket to HeidiSQL team, but the problem was not related:
https://github.com/HeidiSQL/HeidiSQL/issues/1426
Here another user complains for the same reasons and exact same symptoms, with a lot more details:
https://github.com/HeidiSQL/HeidiSQL/issues/1768
Note that HeidiSQL uses the version of MariaDB C Connector linked with SChannel.

I have submitted an issue to OpenSSL as well and explained the problems in great details here:
https://github.com/openssl/openssl/issues/20138
From there, it looks like for some reason the client is unable to find a common signature algorithm with the server. Can this be a misusage of SChannel?

Please find attached the Wireshark capture (same as Openssl GitHub issue above #20138)

Note: this is probably a duplicate from: CONC-527
And even though the solution proposed works, using a less secure cipher level in OpenSSL is not an acceptable solution.
With all the new evidences gathered in the investigations above, I hope we can finally find the culprit and fix once and for all

Thanks a lot, best regards



 Comments   
Comment by Lotendan [ 2023-05-28 ]

Hello, any news on this issue please?

Comment by Georg Richter [ 2023-06-23 ]

A possible reason might be the deprecation of SCHANNEL_CRED structure, which was deprecated since Windows 10 1809 and needs to be replaced by SCH_CREDENTIALS

I filed a new task CONC-653 (TLSv1.3 support in Schannel) which will hopefully also solve this issue.

Comment by Yoh [ 2023-11-12 ]

Hi,
with a c/connector based tool, is there any temporary solution to access via ssl from windows?

Generated at Thu Feb 08 03:06:45 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.