5.9medium
Null pointer deref in X509_issuer_and_serial_hash()
- Severity
- 5.9medium CVSS:3.1 by NVD
- Exploit likelihood
- 7.49% (higher than 94% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- openssl
- Also known as
- GHSA-84rm-qf37-fgc2RUSTSEC-2021-0058
Description
The OpenSSL public API function X509_issuer_and_serial_hash() attempts to create a unique hash value based on the issuer and serial number data contained within an X509 certificate. However it fails to correctly handle any errors that may occur while parsing the issuer field (which might occur if the issuer field is maliciously constructed). This may subsequently result in a NULL pointer deref and a crash leading to a potential denial of service attack. The function X509_issuer_and_serial_hash() is never directly called by OpenSSL itself so applications are only vulnerable if they use this function directly and they use it on certificates that may have been obtained from untrusted sources. OpenSSL versions 1.1.1i and below are affected by this issue. Users of these versions should upgrade to OpenSSL 1.1.1j. OpenSSL versions 1.0.2x and below are affected by this issue. However OpenSSL 1.0.2 is out of support and no longer receiving public updates. Premium support customers of OpenSSL 1.0.2 should upgrade to 1.0.2y. Other users should upgrade to 1.1.1j. Fixed in OpenSSL 1.1.1j (Affected 1.1.1-1.1.1i). Fixed in OpenSSL 1.0.2y (Affected 1.0.2-1.0.2x).
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| OpenSSL OpenSSL | Fixed in OpenSSL 1.1.1j (Affected 1.1.1-1.1.1i), Fixed in OpenSSL 1.0.2y (Affected 1.0.2-1.0.2x), from 1.0.2 before 1.0.2y, from 1.1.1 before 1.1.1j | CVE List, NVD |
| openssl-src (crates.io) | before 111.14.0, from 0.0.0-0 before 111.14.0 | GitHub Advisory Database, RustSec Advisory Database |
| debian debian_linux | 10.0 | NVD |
| tenable nessus_network_monitor | 5.11.0, 5.11.1, 5.12.0, 5.12.1, 5.13.0 | NVD |
| tenable tenable.sc | from 5.13.0 up to 5.17.0 | NVD |
| apple safari | before 14.1.1 | NVD |
| apple ipados | before 14.6 | NVD |
| apple iphone_os | before 14.6 | NVD |
| apple macos | from 11.1 before 11.4 | NVD |
| netapp oncommand_insight | Not specified | NVD |
| netapp oncommand_workflow_automation | Not specified | NVD |
| netapp snapcenter | Not specified | NVD |
| oracle business_intelligence | 5.5.0.0.0, 5.9.0.0.0, 12.2.1.3.0, 12.2.1.4.0 | NVD |
| oracle communications_cloud_native_core_policy | 1.15.0 | NVD |
| oracle enterprise_manager_for_storage_management | 13.4.0.0 | NVD |
| oracle enterprise_manager_ops_center | 12.4.0.0 | NVD |
| oracle essbase | 21.2 | NVD |
| oracle graalvm | 19.3.5, 20.3.1.2, 21.0.0.2 | NVD |
| oracle jd_edwards_world_security | a9.4 | NVD |
| oracle mysql_enterprise_monitor | before 8.0.23 | NVD |
| oracle mysql_server | before 5.7.33, from 8.0.15 before 8.0.23 | NVD |
| oracle peoplesoft_enterprise_peopletools | 8.57, 8.58, 8.59 | NVD |
| oracle zfs_storage_appliance_kit | 8.8 | NVD |
| siemens sinec_ins | before 1.0, 1.0 | NVD |
All scores
| GitHub | 5.9medium CVSS:3.1 | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H |
| RustSec Advisory Database | 5.9medium CVSS:3.1 | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H |
| NVD | 5.9medium CVSS:3.1 | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H |
| NVD | 4.3medium CVSS:2.0 | AV:N/AC:M/Au:N/C:N/I:N/A:P |
Classification
What each source says
CVE List
The OpenSSL public API function X509_issuer_and_serial_hash() attempts to create a unique hash value based on the issuer and serial number data contained within an X509 certificate. However it fails to correctly handle any errors that may occur while parsing the issuer field (which might occur if the issuer field is maliciously constructed). This may subsequently result in a NULL pointer deref and a crash leading to a potential denial of service attack. The function X509_issuer_and_serial_hash() is never directly called by OpenSSL itself so applications are only vulnerable if they use this function directly and they use it on certificates that may have been obtained from untrusted sources. OpenSSL versions 1.1.1i and below are affected by this issue. Users of these versions should upgrade to OpenSSL 1.1.1j. OpenSSL versions 1.0.2x and below are affected by this issue. However OpenSSL 1.0.2 is out of support and no longer receiving public updates. Premium support customers of OpenSSL 1.0.2 should upgrade to 1.0.2y. Other users should upgrade to 1.1.1j. Fixed in OpenSSL 1.1.1j (Affected 1.1.1-1.1.1i). Fixed in OpenSSL 1.0.2y (Affected 1.0.2-1.0.2x).
GitHub Advisory Database
Calls to EVP_CipherUpdate, EVP_EncryptUpdate and EVP_DecryptUpdate may overflow the output length argument in some cases where the input length is close to the maximum permissable length for an integer on the platform. In such cases the return value from the function call will be 1 (indicating success), but the output length value will be negative. This could cause applications to behave incorrectly or crash. OpenSSL versions 1.1.1i and below are affected by this issue. Users of these versions should upgrade to OpenSSL 1.1.1j. OpenSSL versions 1.0.2x and below are affected by this issue. However OpenSSL 1.0.2 is out of support and no longer receiving public updates. Premium support customers of OpenSSL 1.0.2 should upgrade to 1.0.2y. Other users should upgrade to 1.1.1j. Fixed in OpenSSL 1.1.1j (Affected 1.1.1-1.1.1i). Fixed in OpenSSL 1.0.2y (Affected 1.0.2-1.0.2x).
RustSec Advisory Database
The OpenSSL public API function X509_issuer_and_serial_hash() attempts to
create a unique hash value based on the issuer and serial number data contained
within an X509 certificate. However it fails to correctly handle any errors
that may occur while parsing the issuer field (which might occur if the issuer
field is maliciously constructed). This may subsequently result in a NULL
pointer deref and a crash leading to a potential denial of service attack.
The function X509_issuer_and_serial_hash() is never directly called by OpenSSL
itself so applications are only vulnerable if they use this function directly
and they use it on certificates that may have been obtained from untrusted
sources.
NVD (es)
La función de la API pública de OpenSSL X509_issuer_and_serial_hash() intenta crear un valor hash único basado en los datos del emisor y del número de serie contenidos en un certificado X509. Sin embargo, no gestiona correctamente los errores que puedan producirse al analizar el campo del emisor (lo que podría ocurrir si el campo del emisor se construye de forma maliciosa). Esto puede dar lugar a un desvío de puntero NULL y a un fallo que conduzca a un posible ataque de denegación de servicio. La función X509_issuer_and_serial_hash() nunca es llamada directamente por OpenSSL, por lo que las aplicaciones sólo son vulnerables si utilizan esta función directamente y lo hacen con certificados que pueden haber sido obtenidos de fuentes no fiables. Las versiones de OpenSSL 1.1.1i y posteriores están afectadas por este problema. Los usuarios de estas versiones deberían actualizar a OpenSSL 1.1.1j. Las versiones de OpenSSL 1.0.2x e inferiores se ven afectadas por este problema. Sin embargo, OpenSSL 1.0.2 está fuera de soporte y ya no recibe actualizaciones públicas. Los clientes con soporte Premium de OpenSSL 1.0.2 deben actualizar a la versión 1.0.2y. Los demás usuarios deben actualizar a la versión 1.1.1j. Corregido en OpenSSL 1.1.1j (Afectado 1.1.1-1.1.1i). Corregido en OpenSSL 1.0.2y (Afectado 1.0.2-1.0.2x)
References
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2021-23841 changed 2024-09-16 | CVE Terms of Use |
| GitHub Advisory Database | GHSA-84rm-qf37-fgc2 changed 2023-11-08 | CC-BY-4.0 |
| RustSec Advisory Database | RUSTSEC-2021-0058 changed 2023-11-08 | CC0-1.0 |
| NVD | CVE-2021-23841 changed 2026-06-17 | Public domain |