1
0
mirror of https://github.com/mariadb-corporation/mariadb-connector-c.git synced 2025-08-08 14:02:17 +03:00

110 Commits

Author SHA1 Message Date
Georg Richter
54afa039df Fix build with deprecated OpenSSL API:
Err_remove_state is deprecated since OpenSSL 1.0.0 - we use now ERR_remove_thread_state instead.
Kudos to Rosen Penev for providing this patch.
2019-02-03 21:14:49 +01:00
Georg Richter
418e3381a7 Fix for CONC-375: SSL handshake fails
Since new TLSv1.3 cipher suites differ from older cipher suites they can't me mixed and need
to be set by a different API call, we disable the settings for TLSv1.3 cipher suites.
2018-11-27 08:14:33 +01:00
Vladislav Vaintroub
17d0e53176 Fix broken build with Windows OpenSSL. 2018-09-08 15:47:17 +01:00
Sergei Golubchik
0e0bf9aa49 Merge tag 'v3.0.6' into 10.3-server 2018-08-10 15:01:16 +02:00
Sergei Golubchik
3db62d628d Merge branch '10.2-server' into 10.3-serg 2018-08-10 14:24:53 +02:00
Sergei Golubchik
d0f201451d SLES11 OpenSSL 0.9.8 support 2018-08-09 11:27:36 +02:00
Georg Richter
f1fd014a15 Fixed leak in ma_tls_read/write 2018-07-31 09:39:03 +02:00
Georg Richter
df07debedd Support for -Wlogical-op flag and warning fixes (Patch provided by Monty) 2018-05-12 10:48:26 +02:00
Georg Richter
7775af75b4 Fix for CONC-326:
ssl_thread_init() uses wrong openssl threadid callback
2018-05-12 10:48:26 +02:00
Georg Richter
f8ea603fca CONC-321:
Added support for OpenSSL 1.1.1
Tested with OpenSSL 1.1.1 beta 5. For testing TLS v13 the server needs to be patched with patch attached to MDEV-15996.
2018-04-24 18:26:07 +02:00
Georg Richter
1c194bd78f Support for -Wlogical-op flag and warning fixes (Patch provided by Monty) 2018-04-24 17:18:31 +02:00
Georg Richter
966ad42cee Fix for CONC-326:
ssl_thread_init() uses wrong openssl threadid callback
2018-04-24 12:21:07 +02:00
Georg Richter
f226c3b257 Fix for CONC-320:
Non blocking/asynchronous support for OpenSSL and GnuTLS.
Please note that Schannel in asynchronous mode is not supported yet.
2018-04-17 10:35:49 +02:00
Georg Richter
929614903e Travis and Appveyor integration:
- added travis support
  - fixed appveyor settings
  - fixed some warnings (gcc 4.8)
  - removed sleep commands
  - disabled failing tests when running against MySQL server,
    mostly related to stored procedures and binary protocol
  - reverted fix for MDEV_10361

Still open: TLS/SSL appveyor tests, since .msi installation on appveyor doesn't provide certificates.
2018-02-16 12:14:01 +01:00
Georg Richter
b241f8995f MDEV-14101: tls-version
Client part of MDEV-14101: Add support for tls-version, via
mysql_options(mysql, MARIADB_OPT_TLS_VERSION, value)
Accepted values are "TLSv1.1", "TLSv1.2" and "TLSv1.3".

Fixed testcase openssl_1 for schannel
2017-10-23 11:09:54 +02:00
Georg Richter
abf4bf8024 Provide details about TLS/SSL library in use
When calling mariadb_get_infov with option MARIADB_TLS_LIBRARY
the functioni now returns the correct version number and name
of the tls/ssl library in use.
2017-10-17 15:57:42 +02:00
Georg Richter
3b297e08c9 Revert "MDEV-14027: Determine TLS/SSL library version"
This reverts commit 7b02cbb721.
2017-10-15 09:30:24 +02:00
Georg Richter
7b02cbb721 MDEV-14027: Determine TLS/SSL library version 2017-10-15 06:07:54 +02:00
Georg Richter
273ea1fc6d Fix for MDEV-13317: PHP5 crashes
Added check if callback functions for crypto locking were already registered.
2017-07-18 16:19:28 +02:00
Georg Richter
4db860e82a Fix for MDEV-12763: Don't use deprecated API calls with OpenSSL 1.1 2017-05-10 13:28:25 +02:00
Georg Richter
d2aec415d7 Minor fixes:
fixed compiler warnings in openssl.c and dialog.c
  fixed timeout setting (was wrong in a previous commit)
  disabled session tracking test
2017-05-09 16:40:09 +02:00
Georg Richter
a86b36d08f CONC-250: SSL hostname verification for SubjectAltNames
Add hostname verification for SAN (OpenSSL)
2017-05-08 13:55:21 +02:00
Georg Richter
4a55a6d461 Fixes for LibreSSL 2017-02-12 20:19:18 +01:00
Georg Richter
6655a8194e Remove unused include file
remove link to mariadbclient library
2017-01-21 19:36:16 +01:00
Georg Richter
097cd8415d removed MY_MUTEX_INIT_FAST due to build errors 2017-01-12 17:44:28 +01:00
Georg Richter
65d2c41921 CONC-224: Allow to build Connector/C without TLS/SSL support.
- CMake option -DWITH_SSL=OFF disables TLS/SSL support for connector/c
- Fixed warning when building with OpenSSL 1.1.0c
2017-01-11 15:17:53 +01:00
Georg Richter
413b8bcba2 Build fix for OpenSSL_1.1
Fixed connection error message on windows (deliver correct error code)
2016-12-13 12:39:32 +01:00
Georg Richter
7a1e3a699d - Fixed crash in prepared statement: Indicator variable should be checked only if we are in bulk operation mode (=stmt->array_size > 0 and bulk is supported by server
- Added new api function mysql_get_server_status, so client applications no longer need to access members of the mysql structure
2016-12-10 14:09:53 +01:00
Georg Richter
967b2830d8 renamed ma_errmsg.h back to errmsg.h 2016-11-16 18:13:59 +01:00
Georg Richter
468cda3cfb Fixed compilation errors introduced by 629ec646303.. 2016-10-18 10:53:31 +02:00
Georg Richter
c20974b039 - removed global context for tls, so code can be used also with no yassl branch in 10.2
- added new gnutls cipher mapping
- fixed ssl test case: skip hostname verification if both server and client run on localhost
- added server certificates
2016-10-17 16:02:51 +02:00
Georg Richter
9b436eaaf7 TLS fixes:
- don't use password in global context
  - load keys and certs via callback functions
  - don't use gnutls_bye since server is not able to detect dead socket
  - fixed valgrind errors in gnutls
2016-09-13 16:12:34 +02:00
Georg Richter
9f88e25fd6 Compiler warning fixes 2016-09-03 12:46:50 +02:00
Georg Richter
256dc4b511 Disable BIO methods for read/write by default 2016-08-09 14:15:37 +02:00
Georg Richter
dd9ebcf56a - Fixed license header
- More OpenSSL 1.1 fixes
2016-08-05 07:39:10 +02:00
Georg Richter
ba0ed073fd Implemented read/write bio functions, so we don't need sigpipe handler anymore. 2016-07-07 14:44:19 +02:00
Georg Richter
da38af3d61 Fixes for OpenSSL 1.1.0 2016-07-04 09:11:30 +02:00
Georg Richter
45a635dead Fixed compiler warnings
removed latest test for ssl threads (test.c)
2016-06-29 15:22:01 +02:00
Georg Richter
26d31929d4 several fixes for mariadb_stmt_execute_direct:
- allow param binding via mysql_stmt_attr_set:
  mysql_stmt_attr_set(stmt, STMT_ATTR_PREBIND_PARAMS, &param_count);
- If a prepared statement will be reexecuted, we send COM_STMT_CLOSE
  together with COM_STMT_PREPARE and COM_STMT_EXECUTE
2016-06-18 14:07:28 +02:00
Georg Richter
4fd0ad4cbd Fix for CONC-190 (ported from 2.2 branch) 2016-06-04 09:00:20 +02:00
Vladislav Vaintroub
7496789f10 Fix openssl sigpipe correctly, move signal handler to openssl.c 2016-05-31 14:24:55 +02:00
Georg Richter
bea035a72b - Unittests: link static library instead of dynamic
- TLS/SSL: renamed HAVE_SSL to HAVE_TLS to avoid trouble in
  10.2-integration
- Fixed wrong timeout in non-blocking mode
- Fixed valgrind error in prepared statement
2016-03-28 10:29:55 +02:00
Georg Richter
d78cba3013 Merge branch 'master' of https://github.com/MariaDB/mariadb-connector-c 2016-03-16 18:21:09 +01:00
Georg Richter
4b1e94bccc Since we use TLS and not SSL functions and structures were renamed
from SSL to TLS
2016-03-16 18:20:08 +01:00
Vladislav Vaintroub
8bf85da380 Fix build errors on Solaris 10 with gcc 3.4.3 2016-03-15 18:52:29 +01:00
Georg Richter
cc0c34554d - Fixes for 10.2-integration
- As requested by Wlad we use connect timeout for read/write unless
    the connection was established.
- Added experimental session cache support for OpenSSL. It's currently
  disabled
2016-03-08 17:08:01 +01:00
Vladislav Vaintroub
c67bb51c8d Fix openssl detection and compile errors for old openssl versions 2016-03-01 15:27:22 +01:00
Georg Richter
c433c30271 Added session ticket support for OpenSSL (experimental)
Build fixes:
  - Build requires OpenSSL v. 1.0.1 or higher
  - Fixed win64 build (missing target properties for static lib)
2016-03-01 13:37:55 +01:00
Georg Richter
8620b754ea Added missing error messages for wrong protocol
moved connection handler into net->extension (ABI break)
2016-02-23 13:50:14 +01:00
Georg Richter
85525c2ba7 Merge remote-tracking branch 'origin/3.1' 2016-02-16 17:40:03 +01:00