Bug 928962

Summary: VUL-2: CVE-2015-3152: mysql mariadb: MySQL/MariaDB lack of SSL enforcement
Product: [Novell Products] SUSE Security Incidents Reporter: Marcus Meissner <meissner>
Component: IncidentsAssignee: Kristyna Streitova <kstreitova>
Status: RESOLVED DUPLICATE QA Contact: Security Team bot <security-team>
Severity: Normal    
Priority: P4 - Low CC: astieger, mrueckert
Version: unspecified   
Target Milestone: ---   
Hardware: Other   
OS: Other   
Whiteboard: CVSSv2:RedHat:CVE-2015-3152:4.3:(AV:N/AC:M/Au:N/C:P/I:N/A:N) CVSSv3:RedHat:CVE-2015-3152:6.8:(AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:N) CVSSv2:NVD:CVE-2015-3152:4.3:(AV:N/AC:M/Au:N/C:N/I:P/A:N)
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Comment 1 Swamp Workflow Management 2015-04-28 22:00:40 UTC
bugbot adjusting priority
Comment 4 Andreas Stieger 2015-05-01 18:27:14 UTC
public on http://www.ocert.org/advisories/ocert-2015-003.html and http://seclists.org/oss-sec/2015/q2/308

#2015-003 MySQL SSL/TLS downgrade

Description:

The MySQL project is an open source relational database management system.

A vulnerability has been reported concerning the impossibility for MySQL users
(with any major stable version) to enforce an effective SSL/TLS connection
that would be immune from man-in-the-middle (MITM) attacks performing a
malicious downgrade.

While the issue has been addressed in MySQL preview release 5.7.3 in December
2013, it is perceived that the majority of MySQL users are not aware of this
limitation and that the issue should be treated as a vulnerability.

The vulnerability lies within the behaviour of the '--ssl' client option,
which on affected versions it is being treated as "advisory". Therefore while
the option would attempt an SSL/TLS connection to be initiated towards a
server, it would not actually require it. This allows a MITM attack to
transparently "strip" the SSL/TLS protection.

The issue affects the ssl client option whether used directly or triggered
automatically by the use of other ssl options ('--ssl-xxx') that imply
'--ssl'.

Such behavior is clearly indicated in MySQL reference manual as follows:

  For the server, this option specifies that the server permits but does not require
  SSL connections.

  For a client program, this option permits but does not require the client to
  connect to the server using SSL. Therefore, this option is not sufficient in
  itself to cause an SSL connection to be used. For example, if you specify this
  option for a client program but the server has not been configured to permit
  SSL connections, an unencrypted connection is used.

In a similar manner to the new '--ssl' option behaviour, users of the MySQL
client library (Connector/C, libmysqlclient), as of MySQL 5.7.3, can take
advantage of the MYSQL_OPT_SSL_ENFORCE option to enforce SSL/TLS connections.

The vulnerability also affects the MySQL forks MariaDB and Percona Server, as
the relevant 5.7.3 patch has not been pulled, at the time of this advisory, in
their respective stable versions.

Affected version:

MySQL <= 5.7.2

MySQl Connector/C (libmysqlclient) < 6.1.3

Percona Server, all versions

MariaDB, all versions

Fixed version:

MySQL >= 5.7.3

MySQl Connector/C (libmysqlclient) >= 6.1.3

Percona Server, N/A

MariaDB, N/A

Credit: vulnerability report from Adam Goodman, Principal Security Architect
at Duo Security.

CVE: CVE-2015-3152 (MariaDB, Percona)

Timeline:

2015-03-20: vulnerability report received
2015-03-23: contacted Oracle Security
2015-04-04: oCERT sets embargo date to April 29th
2015-04-20: reporter confirms MariaDB is affected
2015-04-22: contacted MariaDB and affected vendors, assigned CVEs
2015-04-23: contacted Percona
2015-04-29: advisory release

References:
https://github.com/mysql/mysql-server/commit/3bd5589e1a5a93f9c224badf983cd65c45215390
http://mysqlblog.fivefarmers.com/2014/04/02/redefining-ssl-option
http://dev.mysql.com/doc/relnotes/mysql/5.7/en/news-5-7-3.html
https://mariadb.atlassian.net/browse/MDEV-7937
https://bugs.launchpad.net/percona-server/+bug/1447527

Permalink:
http://www.ocert.org/advisories/ocert-2015-003.html
Comment 5 Marcus Meissner 2015-05-05 09:51:28 UTC
codenamed by researchers, although this page seems ironic/sarcastic a bit.

https://www.duosecurity.com/blog/backronym-mysql-vulnerability

http://backronym.fail/
Comment 6 Andreas Stieger 2015-06-22 09:52:01 UTC
(MariaDB Engineering from bug 924663 comment #9)
> This issue has been fixed in maria-5.5.44.
> 
> Patches:
> (1)
> https://github.com/MariaDB/server/commit/
> 4ef74979969ac9339d0d42c11a6f26632e6776f1.patch
> (2)
> https://github.com/MariaDB/server/commit/
> be5035b4f4e45806c55deac962e1e413e32289ef.patch
> (3)
> https://github.com/MariaDB/server/commit/
> 5d57e2d8cd02fd2dad3e798d89d14cbd03877cae.patch
> (4)
> https://github.com/MariaDB/server/commit/
> 5a44e1a4024f1760021e5c6fd65773584d60513a.patch
Comment 7 Marcus Meissner 2015-06-22 09:54:47 UTC
duplicate of other bug

*** This bug has been marked as a duplicate of bug 924663 ***
Comment 9 Swamp Workflow Management 2015-10-20 13:12:14 UTC
SUSE-SU-2015:1788-1: An update that fixes 19 vulnerabilities is now available.

Category: security (moderate)
Bug References: 924663,928962,934401,938412
CVE References: CVE-2015-2582,CVE-2015-2611,CVE-2015-2617,CVE-2015-2620,CVE-2015-2639,CVE-2015-2641,CVE-2015-2643,CVE-2015-2648,CVE-2015-2661,CVE-2015-3152,CVE-2015-4737,CVE-2015-4752,CVE-2015-4756,CVE-2015-4757,CVE-2015-4761,CVE-2015-4767,CVE-2015-4769,CVE-2015-4771,CVE-2015-4772
Sources used:
SUSE Linux Enterprise Software Development Kit 11-SP4 (src):    mysql-5.5.45-0.11.1
SUSE Linux Enterprise Software Development Kit 11-SP3 (src):    mysql-5.5.45-0.11.1
SUSE Linux Enterprise Server for VMWare 11-SP3 (src):    mysql-5.5.45-0.11.1
SUSE Linux Enterprise Server 11-SP4 (src):    mysql-5.5.45-0.11.1
SUSE Linux Enterprise Server 11-SP3 (src):    mysql-5.5.45-0.11.1
SUSE Linux Enterprise Desktop 11-SP4 (src):    mysql-5.5.45-0.11.1
SUSE Linux Enterprise Desktop 11-SP3 (src):    mysql-5.5.45-0.11.1
SUSE Linux Enterprise Debuginfo 11-SP4 (src):    mysql-5.5.45-0.11.1
SUSE Linux Enterprise Debuginfo 11-SP3 (src):    mysql-5.5.45-0.11.1
Comment 10 Swamp Workflow Management 2015-12-10 11:12:49 UTC
openSUSE-SU-2015:2243-1: An update that fixes 30 vulnerabilities is now available.

Category: security (important)
Bug References: 924663,928962,951391
CVE References: CVE-2015-0286,CVE-2015-0288,CVE-2015-1789,CVE-2015-1793,CVE-2015-3152,CVE-2015-4730,CVE-2015-4766,CVE-2015-4792,CVE-2015-4800,CVE-2015-4802,CVE-2015-4815,CVE-2015-4816,CVE-2015-4819,CVE-2015-4826,CVE-2015-4830,CVE-2015-4833,CVE-2015-4836,CVE-2015-4858,CVE-2015-4861,CVE-2015-4862,CVE-2015-4864,CVE-2015-4866,CVE-2015-4870,CVE-2015-4879,CVE-2015-4890,CVE-2015-4895,CVE-2015-4904,CVE-2015-4905,CVE-2015-4910,CVE-2015-4913
Sources used:
openSUSE Leap 42.1 (src):    mysql-community-server-5.6.27-8.1
openSUSE 13.2 (src):    mysql-community-server-5.6.27-2.12.1
openSUSE 13.1 (src):    mysql-community-server-5.6.27-7.13.1