The Vigil@nce team watches public vulnerabilities impacting your computers, and then offers security solutions, a vigilance database and tools to fix them.

Vulnerability of Python: bypassing of X.509 subjectAltName check

Synthesis of the vulnerability 

An attacker can send an X.509 certificate containing a null byte to a client written in Python in order to spoof another server.
Impacted systems: Debian, VNX Operating Environment, VNX Series, BIG-IP Hardware, TMOS, Fedora, LibreOffice, openSUSE, openSUSE Leap, Solaris, Python, RHEL, SLES, ESXi, VMware vSphere, VMware vSphere Hypervisor.
Severity of this alert: 2/4.
Creation date: 13/08/2013.
Références of this alert: 18709, BID-61738, CERTA-2013-AVI-590, CERTFR-2014-AVI-112, CERTFR-2014-AVI-244, CVE-2013-4238, DSA-2019-197, DSA-2880-1, FEDORA-2013-15146, FEDORA-2013-15254, MDVSA-2013:214, openSUSE-SU-2013:1437-1, openSUSE-SU-2013:1438-1, openSUSE-SU-2013:1439-1, openSUSE-SU-2013:1440-1, openSUSE-SU-2013:1462-1, openSUSE-SU-2013:1463-1, openSUSE-SU-2014:0380-1, openSUSE-SU-2014:0498-1, openSUSE-SU-2020:0086-1, RHSA-2013:1527-01, RHSA-2013:1582-02, SOL15638, SUSE-SU-2020:0114-1, SUSE-SU-2020:0234-1, VIGILANCE-VUL-13247, VMSA-2014-0008.2, VMSA-2014-0012.

Description of the vulnerability 

An SSL client must check that the host name included in the certificate received from the server is the one of the targeted server.

The ssl.match_hostname() function of the SSL module of Python performs this check, by calling the OpenSSL library. However, OpenSSL uses functions like sprintf(), which uses the null byte as a string terminator, which is the C convention. The X.509 subjectAltName comparison is thus restricted to the left substring before the null byte.

An attacker can therefore send an X.509 certificate containing a null byte to a client written in Python in order to spoof another server.
Full bulletin, software filtering, emails, fixes, ... (Request your free trial)

This computer weakness alert impacts software or systems such as Debian, VNX Operating Environment, VNX Series, BIG-IP Hardware, TMOS, Fedora, LibreOffice, openSUSE, openSUSE Leap, Solaris, Python, RHEL, SLES, ESXi, VMware vSphere, VMware vSphere Hypervisor.

Our Vigil@nce team determined that the severity of this weakness note is medium.

The trust level is of type confirmed by the editor, with an origin of internet server.

A proof of concept or an attack tool is available, so your teams have to process this alert. An attacker with a technician ability can exploit this weakness bulletin.

Solutions for this threat 

Python: patch for X.509 subjectAltName.
A patch is available in information sources.

LibreOffice: version 4.1.5.
The version 4.1.5 is fixed:
  http://www.libreoffice.org/download/

Debian: new python2.7 packages.
New packages are available:
  Debian 7: python2.7 2.7.3-6+deb7u2

Dell EMC VNXe: version MR4 Service Pack 5.
The version MR4 Service Pack 5 is fixed:
  https://www.dell.com/support/

F5 BIG-IP: solution for Python.
The solution is indicated in information sources.

Fedora 19: new python3 packages.
New packages are available:
  python3-3.3.2-6.fc19

Fedora 19: new python packages.
New packages are available:
  python-2.7.5-4.fc19

Mandriva: new python packages.
New packages are available:
  python-2.7.3-4.4.mbs1

openSUSE 13.1: new python3 packages.
New packages are available:
  openSUSE 13.1: python3 3.3.5-5.4.1

openSUSE 13.1: new python packages.
New packages are available:
  openSUSE 13.1: python 2.7.6-8.6.1

openSUSE Leap 15.1: new python3 packages (22/01/2020).
New packages are available:
  openSUSE Leap 15.1: python3 3.6.10-lp151.6.7.1

openSUSE: new python packages.
New packages are available:
  openSUSE 11.4 : python-2.7-8.48.1, python3-3.1.3-9.1
  openSUSE 12.2 : python-2.7.3-3.9.1, python3-3.2.3-1.4.1
  openSUSE 12.3 : python-2.7.3-10.8.1, python3-3.3.0-6.11.1

RHEL 6.5: new rhev-hypervisor6 packages.
New packages are available:
  rhev-hypervisor6-6.5-20131115.0.3.2.el6_5

RHEL 6: new python packages.
New packages are available:
  python-2.6.6-51.el6

Solaris 10: patch for Python.
A patch is available:
  SPARC: 143506-07
  X86: 143507-07

Solaris: version 11.1.12.5.0.
The version 11.1.12.5.0 is fixed:
  https://support.oracle.com/rs?type=doc&id=1592126.1

SUSE LE 15: new python3 packages (16/01/2020).
New packages are available:
  SUSE LE 15 RTM: python3 3.6.10-3.42.2
  SUSE LE 15 SP1: python3 3.6.10-3.42.2

SUSE LE 15: new python packages (27/01/2020).
New packages are available:
  SUSE LE 15 RTM: python 2.7.17-7.32.2
  SUSE LE 15 SP1: python 2.7.17-7.32.2

VMware ESXi 5.1: patch ESXi510-201412101-SG.
A patch is available:
  ESXi510-201412101-SG
  https://www.vmware.com/patchmgr/findPatch.portal
Full bulletin, software filtering, emails, fixes, ... (Request your free trial)

Computer vulnerabilities tracking service 

Vigil@nce provides system vulnerability alerts. The Vigil@nce team tracks computer vulnerabilities impacting systems and applications.