# CVE-2024-39312: Botan has an Authorization Error due to Name Constraint Decoding Bug

- Severity: Medium 5.3 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.27%, higher than 20% of CVEs (2026-12-01)
- Published: 2024-07-08T16:30:25.044Z
- Modified: 2026-06-17T07:41:41.610Z
- Weaknesses: CWE-295
- SSVC (CISA-ADP): exploitation none, automatable yes, technical impact partial
- Assigned by: GitHub_M

## Description

Botan is a C++ cryptography library. X.509 certificates can identify elliptic curves using either an object identifier or using explicit encoding of the parameters. A bug in the parsing of name constraint extensions in X.509 certificates meant that if the extension included both permitted subtrees and excluded subtrees, only the permitted subtree would be checked. If a certificate included a name which was permitted by the permitted subtree but also excluded by excluded subtree, it would be accepted. Fixed in versions 3.5.0 and 2.19.5.

(As written by CVE List.)

## Affected

- randombit botan: < 2.19.5; >= 3.0.0, < 3.5.0; before 2.19.5; from 3.0.0 before 3.5.0
- botan_project botan: before 2.19.5; from 3.0.0 before 3.5.0

## Every score

- GitHub_M: CVSS:3.1 5.3 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N`
- NVD: CVSS:3.1 5.3 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N`

## References

- <https://github.com/randombit/botan/security/advisories/GHSA-jp24-56jm-gg86> (third-party-advisory)

## Sources

- CVE List: [CVE-2024-39312](https://www.cve.org/CVERecord?id=CVE-2024-39312), CVE Terms of Use, modified 2024-08-02
- NVD: [CVE-2024-39312](https://nvd.nist.gov/vuln/detail/CVE-2024-39312), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2024-39312 · Whole record: https://cve.day/CVE-2024-39312.json · Rebuilt by cve.day 2026-11-25T22:58:42.560Z
