Impact
HTSlib’s CRAM decoding routine, specifically the cram_decode_seq() function, incorrectly validates the sequence of features that describe differences relative to an external reference. The routine copies portions of the reference into output buffers without properly checking boundaries, causing out‑of‑bounds reads into memory preceding or following the reference data. This flaw allows a malicious or malformed CRAM file to leak arbitrary data from process memory into the returned sequence or the SAM MD tag, or to trigger a crash via invalid memory access. The vulnerability aligns with CWE‑125 (Out‑of‑Bounds Read) and CWE‑129 (Improper Validation of Array Index).
Affected Systems
Product: HTSlib (samtools:htslib). Affected releases include 1.23.1, 1.22.2, and 1.21.1. All CPEs listed in the public data refer to these releases. Users running any of these specific versions are impacted and must update to a patched version.
Risk and Exploitability
The CVSS score is 6.9, indicating moderate severity. EPSS is reported as less than 1%, suggesting low current exploitation probability, and the vulnerability is not listed in CISA’s Known Exploited Vulnerabilities catalog. The attack vector is inferred to be local or remote if an attacker can supply a crafted CRAM file to an application using HTSlib. Exploitation requires no special privileges beyond the normal execution context of the application.
OpenCVE Enrichment