Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 1287048

Summary: MySQL is limited to using security protocols from last century
Product: Red Hat Enterprise Linux 6 Reporter: Alicja Kario <hkario>
Component: mysqlAssignee: Jakub Dorňák <jdornak>
Status: CLOSED ERRATA QA Contact: Karel Volný <kvolny>
Severity: high Docs Contact:
Priority: high    
Version: 6.7CC: byte, cperry, databases-maint, hhorak, jdornak, mpoole, psklenar, thoger, tlavigne
Target Milestone: pre-dev-freeze   
Target Release: 6.8   
Hardware: All   
OS: All   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-05-11 01:34:25 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1057564, 1253743, 1310222    
Attachments:
Description Flags
Proposed patch from upstream bug which is not yet accepted in 5.6 and lower
none
Program to test SSL/TLS versions supported by MySQL/MariaDB server none

Description Alicja Kario 2015-12-01 11:51:24 UTC
Description of problem:
As described on https://access.redhat.com/articles/1471513 and https://access.redhat.com/articles/1472623 mysql clients and servers cannot be made to negotiate protocol versions higher than TLSv1.0.

This protocol version has had multiple weaknesses discovered since it was published last century. Both the general recommendation[1] and our own[2] is that implementations SHOULD NOT negotiate TLS version 1.0.

Version-Release number of selected component (if applicable):
5.1.73-5.el6_6

How reproducible:
always

Steps to Reproduce:
1. Try to enable support for TLS v1.2

Actual results:
No setting available

Expected results:
TLS v1.2 available by default and negotiated if supported by both sides.

Additional info:
 1 - https://tools.ietf.org/html/bcp195#section-3.1
 2 - https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/7/html-single/Security_Guide/index.html#sec-Choosing_Algorithms_to_Enable

Comment 1 Honza Horak 2015-12-02 09:46:35 UTC
Jakub, how is it in mysql/mariadb 5.5 and 5.6/10.0 that we have shipped in Red Hat Software Collections?

Comment 2 Honza Horak 2015-12-09 18:33:07 UTC
There is a related discussion in PostgreSQL bug #1287053.
Also, there is already upstream bug, which is not resolved yet: https://bugs.mysql.com/bug.php?id=75239
Btw. it says MySQL 5.7 supports TLS 1.1 and 1.2.

Comment 3 Honza Horak 2015-12-09 18:43:43 UTC
Created attachment 1104085 [details]
Proposed patch from upstream bug which is not yet accepted in 5.6 and lower

In the bug https://bugs.mysql.com/bug.php?id=75239 there is also a proposed patch, so just attaching it here. However, since it is not back-ported to older, but still supported versions 5.5 and 5.6, I'm not much willing to back-port to 5.1 either.

Comment 4 Honza Horak 2015-12-09 18:46:14 UTC
5.7 also added tls_version variable:
https://dev.mysql.com/doc/refman/5.7/en/server-system-variables.html#sysvar_tls_version

Comment 5 Honza Horak 2015-12-11 09:09:27 UTC
There is a blog about TLS support in MySQL 5.7:
http://mysqlblog.fivefarmers.com/2015/12/10/ssltls-improvements-in-mysql-5-7-10/

Also, based on:
https://mariadb.atlassian.net/browse/MDEV-6975

..which resulted in commit:
http://bazaar.launchpad.net/~maria-captains/maria/5.5/revision/4365

..we can see that MariaDB supports TLS 1.2 since 5.5, so the recommendation for customers who require TLS 1.2 is to use MariaDB from Red Hat Software Collections.

Comment 6 Honza Horak 2015-12-14 07:03:55 UTC
This is a full patch that came to 5.7:
https://github.com/mysql/mysql-server/commit/ef4fcf760a2d3b098a475323e289a6cab57020ab

Comment 7 Tomas Hoger 2016-01-07 11:28:25 UTC
(In reply to Honza Horak from comment #5)
> Also, based on:
> https://mariadb.atlassian.net/browse/MDEV-6975
> 
> ..which resulted in commit:
> http://bazaar.launchpad.net/~maria-captains/maria/5.5/revision/4365
> 
> ..we can see that MariaDB supports TLS 1.2 since 5.5,

Note that as discussed in MDEV-6975, rev 4369 should also be included if backporting the above change to ensure that SSLv3 and SSLv2 are not also enabled by the change.

http://bazaar.launchpad.net/~maria-captains/maria/5.5/revision/4369

Comment 8 Tomas Hoger 2016-01-07 12:22:47 UTC
(In reply to Tomas Hoger from comment #7)
> http://bazaar.launchpad.net/~maria-captains/maria/5.5/revision/4369

This change was later replaced by an equivalent change merged from MySQL:

https://github.com/MariaDB/server/commit/fe4c4ab914d82af1a1cb2e1bca78c8dcfbc57d4d

(In reply to Honza Horak from comment #1)
> Jakub, how is it in mysql/mariadb 5.5 and 5.6/10.0 that we have shipped in
> Red Hat Software Collections?

The current RHSCL versions:

- mariadb 5.5.44 and 10.0.20 - include fixes from comment 5, comment 6, and comment 7, so enables the highest protocol version supported by the underlying OpenSSL

- mysql 5.5.45 and 5.6.26 - only include the above commit fe4c4ab9, but still use TLSv1_*_method.  Hence TLS 1.0 is the only version enabled, and the fe4c4ab9 change is redundant.

MDEV-6975 includes a testing program that should allow checking which protocol versions are supported by a MySQL / MariaDB server:

https://mariadb.atlassian.net/secure/attachment/36210/mysql-tls-ver-test.c

Comment 9 Tomas Hoger 2016-01-07 12:24:39 UTC
Created attachment 1112434 [details]
Program to test SSL/TLS versions supported by MySQL/MariaDB server

(Local copy of the https://mariadb.atlassian.net/secure/attachment/36210/mysql-tls-ver-test.c )

Comment 10 Tomas Hoger 2016-01-07 12:26:48 UTC
(In reply to Tomas Hoger from comment #8)
> - mariadb 5.5.44 and 10.0.20 - include fixes from comment 5, comment 6, and
> comment 7, so enables the highest protocol version supported by the
> underlying OpenSSL

Correction: the above should say comment 5 (rev 4365), comment 7 (rev 4369) and comment 8 (git fe4c4ab9).

Comment 23 errata-xmlrpc 2016-05-11 01:34:25 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2016-0979.html