1mysql_get_ssl_cipher(3)       MariaDB Connector/C      mysql_get_ssl_cipher(3)
2
3
4
5   Name
6       mysql_get_ssl_cipher - returns the cipher suite in use
7
8   Synopsis
9              #include <mysql.h>
10
11              const char *mysql_get_ssl_cipher(MYSQL *mysql)
12
13   Description
14       Returns  the name of the currently used cipher suite of the secure con‐
15       nection, or NULL for non TLS connections.
16
17   Parameter
18       • mysql - a connection identifier, which was  previously  allocated  by
19         mysql_init(3) and connected by mysql_real_connect(3).
20
21   Notes
22       • For  using  mysql_get_ssl_cipher()  MariaDB Connector/C must be built
23         with TLS/SSL support, otherwise the function will return NULL.
24
25       • `mysql_get_ssl_cipher()’ can be used to determine if the client serv‐
26         er connection is secure.
27
28       • Depending  on  the  TLS  library  in  use (OpenSSL, GnuTLS or Windows
29         Schannel) the name of the cipher suites may differ.  For example  the
30         cipher  suite  0x002F  (TLS_RSA_WITH_AES_128_CBC_SHA)  has  different
31         names:    AES128-SHA     for     OpenSSL     and     Schannel     and
32         TLS_RSA_AES_128_CBC_SHA1 for GnuTLS.
33
34   Return value
35       Returns a zero terminated string containing the cipher suite used for a
36       secure connection, or NULL if connection doesn’t use TLS/SSL.
37
38   See also
39mysql_ssl_set(3)
40
41
42
43Version 3.2.2                                          mysql_get_ssl_cipher(3)
Impressum