# CVE-2013-4314: PyOpenSSL Mishandles NUL Byte In Certificate Subject Alternative Name

Source: https://junglewise.ai/threats/cve-2013-4314-pyopenssl-mishandles-nul-byte-in-certificate-subject-alternative  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2013-09-30  
License: CC BY 4.0 with a link back

CVE-2013-4314 · Severity: low · CVSS 3.1 · Published 2013-09-30

The X509Extension in pyOpenSSL before 0.13.1 does not properly handle a '\0' character in a domain name in the Subject Alternative Name field of an X.509 certificate, which allows man-in-the-middle attackers to spoof arbitrary SSL servers via a crafted certificate issued by a legitimate Certification Authority.

Technologies: [pyopenssl (PyPI)](https://junglewise.ai/threats/technologies/pypi-pyopenssl). Vendors: [PyPI](https://junglewise.ai/threats/vendors/pypi).

## Quick answers

**Is CVE-2013-4314 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2013-4314 being exploited in the wild.

**How severe is CVE-2013-4314?** Low severity, with a CVSS score of 3.1, published 30 September 2013.

**Which products and versions are affected?** pyopenssl (PyPI) ECOSYSTEM:introduced=0,fixed=0.13.1.

**Is there a fix for CVE-2013-4314?** Yes. pyopenssl (PyPI): upgrade to 0.13.1 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**Am I affected by CVE-2013-4314?** Check whether you run pyopenssl (PyPI) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- pyopenssl (PyPI): upgrade to 0.13.1 or later

  ```sh
  pip install "pyopenssl>=0.13.1"
  ```


## Affected products

- pyopenssl (PyPI) ECOSYSTEM:introduced=0,fixed=0.13.1

## Identifiers

- CVE-2013-4314
- GHSA-6748-36qp-fx6r
- PYSEC-2013-31

## Related threats

- [pyOpenSSL buffer overflow in DTLS cookie generation callback](https://junglewise.ai/threats/cve-2026-27459-pyopenssl-buffer-overflow-in-dtls-cookie-generation-callback)
- [pyOpenSSL allows TLS connection bypass via unhandled callback exception in set_tlsext_servername_callback](https://junglewise.ai/threats/cve-2026-27448-pyopenssl-allows-tls-connection-bypass-via-unhandled-callback)
- [PyOpenSSL Use-After-Free vulnerability](https://junglewise.ai/threats/cve-2018-1000807-pyopenssl-use-after-free-vulnerability)
- [pyOpenSSL incorrect memory management in PKCS #12 handling](https://junglewise.ai/threats/cve-2018-1000808-pyopenssl-incorrect-memory-management-in-pkcs-12-handling)
