# CVE-2023-6237: Excessive time spent checking invalid RSA public keys

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** MEDIUM 5.9
- **CVSS:** 5.9 (v3.1, CNA) `CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H`
- **CVSS metrics:** Attack vector: Network; Attack complexity: High; Privileges required: None; User interaction: None; Scope: Unchanged; Confidentiality impact: None; Integrity impact: None; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Remote, no login needed
- **EPSS:** 2.36% (percentile 84, 2026-11-26)
- **CWE:** CWE-606
- **Published:** 2024-04-25T06:27:26.990Z
- **Modified:** 2026-11-10T14:05:10.233Z

## Who should check

- Anyone running OpenSSL \>= 3.0.0, \< 3.0.13; \>= 3.1.0, \< 3.1.5; \>= 3.2.0, \< 3.2.1

## Description

Issue summary: Checking excessively long invalid RSA public keys may take
a long time.

Impact summary: Applications that use the function EVP\_PKEY\_public\_check()
to check RSA public keys may experience long delays. Where the key that
is being checked has been obtained from an untrusted source this may lead
to a Denial of Service.

When function EVP\_PKEY\_public\_check() is called on RSA public keys,
a computation is done to confirm that the RSA modulus, n, is composite.
For valid RSA keys, n is a product of two or more large primes and this
computation completes quickly. However, if n is an overly large prime,
then this computation would take a long time.

An application that calls EVP\_PKEY\_public\_check() and supplies an RSA key
obtained from an untrusted source could be vulnerable to a Denial of Service
attack.

The function EVP\_PKEY\_public\_check() is not called from other OpenSSL
functions however it is called from the OpenSSL pkey command line
application. For that reason that application is also vulnerable if used
with the '-pubin' and '-check' options on untrusted data.

The OpenSSL SSL/TLS implementation is not affected by this issue.

The OpenSSL 3.0 and 3.1 FIPS providers are affected by this issue.

## Affected and fixed versions

- OpenSSL: \>= 3.0.0, \< 3.0.13; \>= 3.1.0, \< 3.1.5; \>= 3.2.0, \< 3.2.1 (cvelist)

## Mitigation

- Upgrade OpenSSL to 3.2.1 or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2023-6237. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2023-6237.md
Affected: OpenSSL >= 3.0.0, < 3.0.13; >= 3.1.0, < 3.1.5; >= 3.2.0, < 3.2.1
Fixed in: OpenSSL 3.0.13, OpenSSL 3.1.5, OpenSSL 3.2.1

Steps:
1. Search this machine and project for OpenSSL: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2023-6237 being exploited?

There is no confirmed exploitation: CVE-2023-6237 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 2.36% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2023-6237?

Medium: CVSS 5.9 (v3.1, scored by CNA). Remote, no login needed. The attack needs conditions outside the attacker's control, which makes it harder.

### Which versions are affected by CVE-2023-6237?

OpenSSL \>= 3.0.0, \< 3.0.13; \>= 3.1.0, \< 3.1.5; \>= 3.2.0, \< 3.2.1.

### Is there a fix for CVE-2023-6237?

Yes. Fixed in OpenSSL 3.0.13, OpenSSL 3.1.5, OpenSSL 3.2.1. Upgrade OpenSSL to 3.2.1 or later.

### How do I check if I'm affected by CVE-2023-6237?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- vendor: <https://www.openssl.org/news/secadv/20240115.txt>
- patch: <https://github.com/openssl/openssl/commit/18c02492138d1eb8b6548cb26e7b625fb2414a2a>
- patch: <https://github.com/openssl/openssl/commit/a830f551557d3d66a84bbb18a5b889c640c36294>
- patch: <https://github.com/openssl/openssl/commit/0b0f7abfb37350794a4b8960fafc292cd5d1b84d>
- other: <http://www.openwall.com/lists/oss-security/2024/03/11/1>
- other: <https://security.netapp.com/advisory/ntap-20240531-0007/>
- other: <https://cert-portal.siemens.com/productcert/html/ssa-265688.html>
- other: <https://cert-portal.siemens.com/productcert/html/ssa-331112.html>
- other: <https://cert-portal.siemens.com/productcert/html/ssa-915275.html>
- other: <https://cert-portal.siemens.com/productcert/html/ssa-769027.html>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2023-6237>

HTML: <https://flawdb.com/CVE-2023-6237> · JSON: <https://flawdb.com/api/v1/entries/CVE-2023-6237>
