Skip to main content

HTSlib CVE-2026-62259

| EUVDEUVD-2026-130351 MEDIUM
Out-of-bounds Read (CWE-125)
2026-11-19 GitHub_M
6.9
CVSS 4.0 · Vendor: GitHub_M
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Deliver crafted CRAM v4 file to HTSlib consumer
  2. Exploit
    Trigger unvalidated decode size in XPACK/XRLE decoder
  3. Impact
    Read beyond input buffer, leaking process memory or crashing

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Bounds checking, read limits
MITRE ATT&CK

1 technique across 1 tactic: Collection

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires the target to parse attacker-supplied CRAM data using HTSlib's EXPERIMENTAL CRAM v4 codecs - specifically the XPACK (cram_xpack_decode_char) and XRLE (cram_xrle_decode_char) decoders - where attacker-controlled decode sizes are not validated against the expanded input array. The practical limiting factor is that these are experimental CRAM v4 code paths not used by most current pipelines, so default/common CRAM v2/v3 workflows are not affected; the attacker must also get the crafted CRAM input to a process that decodes it. Per the CVSS vector (PR:N/UI:N) no authentication is required, and there is no workaround other than updating. Impact is bounded to information disclosure and denial of service (process crash), not code execution.

Impact

This is a medium-severity (CVSS 4.0 base 6.9) out-of-bounds read (CWE-125, with CWE-129 improper array-index validation noted in the GHSA advisory) in HTSlib's experimental CRAM v4 XPACK and XRLE decoders. The supplied CVSS 4.0 vector (AV:N/AC:L/AT:N/PR:N/UI:N) describes a low-complexity, no-privilege trigger with low confidentiality and low availability impact (VC:L/VA:L) and no integrity impact - consistent with memory disclosure or a crash rather than code execution. Signals are mostly moderate and non-urgent: no EPSS score was provided, there is no CISA KEV listing (not actively exploited), and no public exploit code was supplied - the references are the vendor advisory, fixing pull request, fixing commits, and release tags, not a PoC. The vuln.today decision label is 'this_month', not act_now or emergency, so this is a scheduled-patch priority rather than a drop-everything issue. A key mitigating factor the raw CVSS does not capture: the affected code paths are the EXPERIMENTAL CRAM v4 codecs, which most real-world pipelines do not yet use, further lowering practical exposure. Treat this as a genuine but bounded bug to remediate on a normal cycle, not a high-CVSS-but-overstated issue nor a critical emergency.

Exploit ScenarioDerived

An attacker crafts a malicious CRAM v4 file (or data stream) using the XPACK/XRLE encodings and gets a victim's bioinformatics tool or service built on HTSlib to parse it. When cram_xpack_decode_char or cram_xrle_decode_char processes the attacker-controlled decode sizes without range-checking, the decoder reads past the supplied input buffer, leaking adjacent process-state memory into output or crashing the process on an invalid access. No public exploit code was provided in the input; only vendor patch references exist.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.5% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Nov 19, 2026

An out-of-bounds read in HTSlib's experimental CRAM v4 XPACK and XRLE decoders (cram_xpack_decode_char and cram_xrle_decode_char) lets crafted CRAM data drive decode sizes past the expanded input array, so a decoding process can read beyond the supplied buffer and either leak process-state information or crash on invalid memory access. All HTSlib releases up to and including 1.23.1, 1.22.2 and 1.21.1 are affected, with fixes published in 1.24, 1.23.2, 1.22.3 and 1.21.2; per the CVSS vector (AV:N/AC:L/PR:N/UI:N) no authentication or user interaction is required, but exploitation is gated on the target actually parsing attacker-supplied CRAM data through these experimental code paths. Impact is bounded to information disclosure and denial of service rather than code execution, and no public exploit was identified at the time of analysis; the vendor states there is no workaround other than updating.

RemediationAI

Upgrade to a fixed release: 1.24 for the main line, or the corresponding maintenance branch 1.23.2, 1.22.3 or 1.21.2. The upstream commits implementing the fix are a1f929da9f207b099bfc1f5a74aee94fc0eeba6a, 76147edc658e5c19cbae52ececf5e3af81e8998a and a3e8dca14dcfdc6167281721ede6d6ecd3395bad, tracked in pull request https://github.com/samtools/htslib/pull/2046, and the vendor advisory is at https://github.com/samtools/htslib/security/advisories/GHSA-hg3g-v57p-459q. Since HTSlib is usually a linked dependency rather than an end-user application, patching the library alone is insufficient: downstream tools such as samtools must be recompiled or replaced with builds that bundle the fixed HTSlib, so verify the embedded library version in each consumer as well as the system package. The vendor explicitly states there is no workaround; the only practical compensating measure, given that exploitation requires parsing attacker-supplied CRAM input through the experimental CRAM v4 XPACK/XRLE decoders, is to avoid opening untrusted CRAM files with builds that enable those code paths and to sanitize or re-encode externally sourced alignment data before processing - a constraint that costs pipeline flexibility and still leaves the vulnerable library in place, so updating is the complete fix.

Affected VersionsENISA

htslib 1.23.0, < 1.23.2
htslib < 1.21.2
htslib 1.22.0, < 1.22.3

Affected Packages

euvd htslib fix: 1.21.2, 1.22.3, 1.23.2

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

CRAM is the compressed reference-based format used to store DNA sequence alignment data, and HTSlib is the reference C implementation used by samtools and a wide range of bioinformatics tools. The flaw is rooted in CWE-125 (out-of-bounds read) with CWE-129 (improper validation of array index) as noted in the upstream GHSA advisory: the experimental CRAM v4 XPACK and XRLE codecs, implemented in cram_xpack_decode_char and cram_xrle_decode_char inside cram/cram_codecs.c, do not verify that decoder sizes taken from user-controlled input stay within the bounds of the expanded input array. The upstream fix (pull request 2046) reworks the signedness of the size and bit-count arithmetic - changing the loop counters and decoded-size variables from int to uint32_t, and the cram_not_enough_bits helper to take a uint64_t bit count and drop a now-redundant negative check - so a large or overflowing size value can no longer slip past the remaining-input test and drive an over-read. The same patch set also adds BAM_MAX_QNAME_LEN (254) bounds enforcement in cram_decode.c, cram_decode_slice_mt, cram_to_bam and sam.c, truncating over-long read names instead of letting them overflow fixed-size stack buffers such as name_a, which points at related input-validation weaknesses in the same decoding path. Because the vulnerable routines live in library code, any downstream consumer compiled against an affected HTSlib inherits the bug; the buffers are read but never written, which is why the impact stays at disclosure and crash rather than memory corruption.

Know when Htslib gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (GitHub_M) PRIMARY 6.9 MEDIUM
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:N/VA:L/SC:N/SI:N/SA:N
vuln.today AI 6.5 MEDIUM

Parsing attacker-controlled CRAM input needs no privileges or special conditions beyond using CRAM v4 decoders; impact is limited to memory disclosure (C:L) and crash (A:L), no integrity effect.

3.1 AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:L
4.0 AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:N/VA:L/SC:N/SI:N/SA:N

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
None
Vulnerable system: Confidentiality
Low
Vulnerable system: Integrity
None
Vulnerable system: Availability
Low
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

1
Patch available
Nov 19, 2026 - 17:03 EUVD

DescriptionCVE.org

HTSlib is a library for reading and writing bioinformatics file formats. Prior to 1.21.2, 1.22.3, 1.23.2, and 1.24, the experimental CRAM v4 functions cram_xpack_decode_char and cram_xrle_decode_char do not validate that attacker-controlled decode sizes remain within their expanded input arrays. Crafted CRAM data can therefore make either decoder read beyond the supplied input buffer, potentially disclosing process-state information or crashing the process through invalid memory access. This issue is fixed in versions 1.21.2, 1.22.3, 1.23.2, and 1.24.

Threat Intelligence Overview

EPSS Score
0.5%
Top 54% exploitable
Prevalence
Low
bioinformatics library; widely used in that niche but industry-specific footprint
Data Quality
5 sources
Confidence: Medium

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.5%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
Yes
Human Impact· derived
Medium
Technical Impact
Partial

Priority Score

35
Low Medium High Critical
KEV: 0
EPSS: +1
CVSS: +34
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

A buffer overflow occurs when a program writes more data to a memory buffer than it was allocated to hold, causing the excess data to spill into adjacent memory regions.

Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.

More in Htslib

View all
CVE-2018-13843 HIGH POC
7.5 Jul 10

An issue has been found in HTSlib 1.8. Rated high severity (CVSS 7.5), this vulnerability is remotely exploitable, no au

CVE-2017-1000206 CRITICAL
9.8 Nov 17

samtools htslib library version 1.4.0 and earlier is vulnerable to buffer overflow in the CRAM rANS codec resulting in p

CVE-2018-13845 CRITICAL
9.8 Jul 10

An issue has been found in HTSlib 1.8. Rated critical severity (CVSS 9.8), this vulnerability is remotely exploitable, n

CVE-2026-31963 HIGH
8.8 Mar 18

HTSlib contains a heap buffer overflow vulnerability in its CRAM decoder caused by an out-by-one error when validating f

CVE-2026-31962 HIGH
8.8 Mar 18

HTSlib versions prior to 1.23.1, 1.22.2, and 1.21.1 contain a heap buffer overflow vulnerability in the cram_decode_seq(

CVE-2026-31968 HIGH
8.8 Mar 18

HTSlib contains a buffer overflow vulnerability in its CRAM format decoder affecting the VARINT and CONST encoding handl

CVE-2026-62258 HIGH
8.8 Nov 19

Stack-based buffer overflow in HTSlib's CRAM decoder affects all releases before 1.21.2, 1.22.3, 1.23.2, and 1.24: a cra

CVE-2026-62257 HIGH
8.8 Nov 19

Heap out-of-bounds read and write in HTSlib's experimental CRAM v4 XPACK and XRLE decoders allows a remote, unauthentica

CVE-2026-63390 HIGH
8.8 Nov 19

Heap buffer overflow in HTSlib's BCF reader allows an attacker-crafted BCF file to corrupt heap memory when opened by an

CVE-2018-14329 MEDIUM POC
4.7 Jul 17

In HTSlib 1.8, a race condition in cram/cram_io.c might allow local users to overwrite arbitrary files via a symlink att

CVE-2018-13844 HIGH
7.5 Jul 10

An issue has been found in HTSlib 1.8. Rated high severity (CVSS 7.5), this vulnerability is remotely exploitable, no au

CVE-2026-31971 HIGH
7.1 Mar 18

HTSlib, a widely-used bioinformatics library for reading and writing sequence alignment formats, contains a critical buf

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy