Executive brief
Open Babel, a widely used chemistry data conversion library, contains a memory safety flaw in its MSI file format parser. If a user or automated service opens a specially crafted, malicious chemistry file, an attacker could potentially execute unauthorized code or cause the application to crash. This affects various software environments, including Linux distributions and web services that process chemistry data using Python, Java, or C++.
Technical details
An out-of-bounds (OOB) write vulnerability exists in Open Babel's MSI parser within the translationVectors[] array. The MSI reader utilizes a fixed-size stack array (3 elements) to store cell translation vectors; however, it fails to validate the number of vectors provided in the input file. A malformed MSI file can specify more vectors than the array has slots, leading to a buffer overflow. This vulnerability can be triggered via the obabel CLI tool, the OBConversion API, or any language bindings (Python, Ruby, Java, etc.). The issue is addressed in version 3.2.0 by adding bounds checking to ensure the number of translation vectors does not exceed the array size.
Affected products
- Open Babel Open Babel <= 3.1.1
Timeline
- 2023-07-21: advisory: NVD Published Date
- 2026-05-26: patched: Version 3.2.0 released
- 2026-07-01: disclosed: GitHub Advisory published
References
- https://github.com/openbabel/openbabel/security/advisories/GHSA-f8h2-c479-vqxf
- https://github.com/openbabel/openbabel/commit/40e852138f21d586b7ccdce6329e7b23a87168bb
- https://talosintelligence.com/vulnerability_reports/TALOS-2022-1666
- https://www.talosintelligence.com/vulnerability_reports/TALOS-2022-1666
- https://api.github.com/repos/openbabel/openbabel/security-advisories/GHSA-f8h2-c479-vqxf