Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Not a Bug
-
3.4.5
-
None
Description
If the server is started with --disable-ssl , the latest Connector/C is not able to connect with ssl=0 unless MARIADB_TLS_DISABLE_PEER_VERIFICATION is set to 1
(pelase note I use perl-DBD-MariaDB just for simplicity of testing Connector/C - I think the problem is in C code).
# perl test.pl
|
DBI connect('database=test;mariadb_socket=/home/an/MirrorCache/mc1/ma/.sock;mariadb_ssl=0;mariadb_ssl_verify_server_cert=0','mirrorcache',...) failed: TLS/SSL error: SSL is required, but the server does not support it at test.pl line 5. |
couldnt connect at test.pl line 7. |
#
|
#
|
# MARIADB_TLS_DISABLE_PEER_VERIFICATION=1 perl test.pl
|
1 rows found.
|
#
|
#
|
# cat test.pl
|
use strict;
|
use warnings;
|
use DBI;
|
my $dsn = "DBI:MariaDB:database=test;mariadb_socket=/home/an/MirrorCache/mc1/ma/.sock;mariadb_ssl=0;mariadb_ssl_verify_server_cert=0"; |
my $dbh = DBI->connect($dsn, 'mirrorcache', ''); |
|
$dbh or die 'couldnt connect'; |
|
my $sth = $dbh->prepare(
|
'SELECT version()') |
or die "prepare statement failed: $dbh->errstr()"; |
$sth->execute() or die "execution failed: $dbh->errstr()"; |
print (( $sth->rows // "0" ) . " rows found.\n"); |
$sth->finish;
|
|