CVE-2022-43607: Open Babel out-of-bounds write in MOL2 attribute/value parser

CVE-2022-43607 · Severity: high · CVSS 7.8 · Published 2026-07-01

Open Babel, a widely used library for converting chemistry and molecular data files, contains a memory safety flaw in its MOL2 file parser. If a user or automated service processes a specially crafted chemistry file, an attacker could potentially execute malicious code or crash the application. This affects researchers and organizations using Open Babel's command-line tools or its programming interfaces in Python, Java, and other languages.

Technologies: openbabel (PyPI). Vendors: PyPI.

Quick answers

Is CVE-2022-43607 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2022-43607 being exploited in the wild.
How severe is CVE-2022-43607?
High severity, with a CVSS score of 7.8, published 1 July 2026.
Which products and versions are affected?
openbabel (PyPI) < 3.2.0, ECOSYSTEM:introduced=0,fixed=3.2.0.
Is there a fix for CVE-2022-43607?
Yes. openbabel (PyPI): upgrade to 3.2.0 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
How is CVE-2022-43607 attacked?
It is attacked with local access, in a software library.
Am I affected by CVE-2022-43607?
Check whether you run openbabel (PyPI) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

How to fix

  • openbabel (PyPI): upgrade to 3.2.0 or later
    pip install "openbabel>=3.2.0"

Technical details

An out-of-bounds write vulnerability exists in Open Babel's MOL2 format parser within the `ReadMolecule` function in `mol2format.cpp`. The flaw is located in the attribute/value parsing logic where `sscanf` is used to read data into fixed-size 32-byte buffers (`attr` and `val`) without sufficient bounds checking. By providing a crafted MOL2 file with over-long attribute or value strings, an attacker can overflow these buffers. This can lead to memory corruption and arbitrary code execution. The vulnerability can be triggered via the `obabel` CLI tool, the `OBConversion` API, or any language bindings. A patch is available in version 3.2.0.

Affected products

  • Open Babel Open Babel <= 3.1.1

Identifiers

  • CVE-2022-43607
  • GHSA-vjg6-gm8m-v5g6
  • PYSEC-2026-2792

Timeline

  • 2022-10-24: other: Vulnerability discovered/assigned
  • 2023-07-21: disclosed: Initial Talos report published
  • 2026-05-26: patched: Version 3.2.0 released
  • 2026-07-01: advisory: GitHub Advisory published

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.