CVE-2026-3408: Open Babel CDXML File atom.cpp GetExplicitValence null pointer dereference
Summary
A memory-safety vulnerability in Open Babel's CDXML file format parser caused a NULL pointer dereference when reading a crafted input file.
Details
The flaw was in OBAtom::GetExplicitValence as called from the CDXML parser. A malformed fragment caused the parser to invoke the method on a NULL atom pointer.
Impact
Open Babel is a C++ library and CLI used to read and write chemistry file formats; it is shipped by Linux distributions and embedded in services that may parse untrusted input. Triggering this vulnerability requires the victim to open a malicious CDXML file with the obabel tool, the OBConversion API, or any of the language bindings (Python, Ruby, Java, R, Perl, C#, PHP).
Affected versions
All releases up to and including 3.1.1.
Patched version
3.2.0 (released 2026-05-26).
Patch
Fix commit: https://github.com/openbabel/openbabel/commit/e23a224b Tracked in #2862.
A minimized reproducer for this CVE is checked in under test/files/fuzzregress/ and is exercised on every CI build under ASAN+UBSAN by the fuzzregresstest harness.
Credit
Reported by Vedant Madane (@VedantMadane) via VulDB.
Other sources
A vulnerability was identified in Open Babel up to 3.1.1. This impacts the function OBAtom::GetExplicitValence of the file isrc/atom.cpp of the component CDXML File Handler. Such manipulation leads to null pointer dereference. The attack can be launched remotely. The exploit is publicly available and might be used. The name of the patch is e23a224b8fd9d7c2a7cde9ef4ec6afb4c05aa08a. It is best practice to apply a patch to resolve this issue.
— MITRE
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
pip/openbabelto a version that resolves this vulnerability.Fixed in 3.2.0 - Upgrade
Upgrade
debian/openbabelto a version that resolves this vulnerability.Fixed in 3.2.0+dfsg-1 - Upgrade
Upgrade
debian/openbabelto a version that resolves this vulnerability.Fixed in 3.2.0+dfsg-2 - Upgrade
Upgrade
Open Babelto a version that resolves this vulnerability.Fixed in 3.2.0 (released 2026-05-26)Patch e23a224b8fd9d7c2a7cde9ef4ec6afb4c05aa08a - Compensating control
Do not open or process untrusted/malicious CDXML files with the `obabel` tool, the `OBConversion` API, or any language bindings; this vulnerability allows a remote-triggered NULL pointer dereference when a crafted CDXML file is parsed.
Event History
Frequently Asked Questions
What is the severity of CVE-2026-3408?
CVE-2026-3408 is considered a moderate severity vulnerability due to the potential for a null pointer dereference leading to application crashes.
How do I fix CVE-2026-3408?
To fix CVE-2026-3408, upgrade OpenBabel to version 3.1.2 or higher.
What software is affected by CVE-2026-3408?
CVE-2026-3408 affects OpenBabel versions up to and including 3.1.1.
What is the impact of CVE-2026-3408?
The impact of CVE-2026-3408 is that it can cause a null pointer dereference in the OBAtom::GetExplicitValence function.
Who discovered CVE-2026-3408?
CVE-2026-3408 was identified through security research focused on vulnerabilities in software handling CDXML files.