Skip to main content

HTSlib EUVDEUVD-2026-130306

| CVE-2026-62258 HIGH
Stack-based Buffer Overflow (CWE-121)
2026-11-19 GitHub_M
8.8
CVSS 4.0 · Vendor: GitHub_M
View

Attack ChainAIDerived

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

  1. Access
    Craft CRAM record with overlong query name
  2. Delivery
    Deliver file to victim pipeline or tool
  3. Exploit
    Victim opens file in HTSlib
  4. Execution
    Name decoded into 1024-byte stack buffer
  5. Persist
    Overflow occurs before length validation
  6. Impact
    Process crash or arbitrary code execution

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Stack buffer bounds checking
MITRE ATT&CK

1 technique across 1 tactic: Execution

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

Exploitation Conditions

Requires that an HTSlib-based application (e.g. samtools/bcftools or any downstream consumer) open and decode an attacker-controlled CRAM file containing a record with a query name longer than the 254-character specification limit; all CRAM format versions are affected and no special configuration or feature toggle is needed. The limiting factor is delivery and victim action: an attacker must get the target to parse a maliciously crafted CRAM file, so this is not autonomous network exploitation despite the supplied AV:N/UI:N vector. There is no workaround per the vendor - only upgrading to 1.21.2, 1.22.3, 1.23.2, or 1.24 removes the flaw.

Impact

This is a CWE-121 stack write overflow in HTSlib's CRAM decoder, rated CVSS 4.0 8.8 (VI:H/VA:L). Weighing all signals: there is NO CISA KEV listing, NO EPSS score supplied, and NO verified public exploit - the issue was found through fuzzing by Claude and Ada Logics and reported responsibly via GitHub advisory, so there is no public exploit identified at time of analysis. The vuln.today Decision label is 'this_week' (priority, but not act_now/emergency), consistent with a serious memory-safety bug lacking evidence of active exploitation. A key signal conflict must be stated: the supplied CVSS 4.0 vector is AV:N/PR:N/UI:N, yet the advisory text says exploitation occurs when 'a user opens a file crafted to exploit this issue' - that is effectively attacker-delivered data plus a victim action, so the UI:N / pure-network framing overstates how autonomous the attack is; realistic exploitation depends on getting a target to parse an attacker-controlled CRAM record. Net: a genuine, high-severity memory-corruption flaw in a widely-used genomics library, but real-world urgency is moderated by the absence of KEV/EPSS/PoC evidence and the requirement that a victim process a malicious file. Treat as patch-this-week, not an emergency, matching the Decision label.

Exploit ScenarioDerived

An attacker crafts a malicious CRAM file whose record carries a query name far exceeding the 254-character specification limit, then delivers it as a shared sequencing dataset or pipeline input. When a researcher or an automated bioinformatics pipeline opens the file with an HTSlib-based tool, the overlong name is decoded into a fixed 1024-byte stack array before the length check runs, overflowing the stack and crashing the process or corrupting stack data, potentially allowing arbitrary code execution. No public exploit code was identified; the flaw was discovered via fuzzing.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.8% exploitation probability (EPSS)

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

Alert me

AnalysisAIv1 – Nov 19, 2026

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 crafted CRAM record whose query name exceeds the 254-character specification limit is decoded into a 1024-byte stack array before the length check runs, so an overlong name is written past that buffer. Successful exploitation crashes the process or corrupts stack data and may allow arbitrary code execution, though the vendor rates integrity impact high and availability impact low. Reaching the flaw requires that an HTSlib-based application such as samtools or bcftools, or any downstream consumer, open and decode an attacker-supplied CRAM file, so delivery depends on victim interaction; no public exploit code has been identified at time of analysis and the vendor states there is no workaround, only upgrading to a fixed release.

RemediationAI

Upgrade to the fixed release for your branch: 1.21.2, 1.22.3, 1.23.2, or 1.24 (release tags at https://github.com/samtools/htslib/releases/tag/1.21.2, /1.22.3, /1.23.2, and /1.24); the fix commits are 25278797c251a9af789382ecf5aa0c86f417bdf5, df93e245f1b517aec86c69684fcb2faf5942c5c2, and f1d1bf835aaafa1e511996dcd49760c36f683b17, merged via https://github.com/samtools/htslib/pull/2046. The vendor advisory explicitly states there is no workaround, so upgrading is the only complete fix; because the assessed precondition is that a user opens and decodes an attacker-controlled CRAM file, the only partial exposure reduction available until patched is to avoid decoding CRAM input from untrusted or unverified sources, which constrains legitimate workflow flexibility without removing the underlying defect. Applications statically linking or vendoring HTSlib, including samtools/bcftools builds, must be rebuilt against a patched HTSlib to be protected.

Affected VersionsENISA

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

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 a compressed bioinformatics format for DNA sequence alignment data, implemented in HTSlib and consumed by tools such as samtools and bcftools. The CRAM specification caps the read query name at 254 characters, but in the affected code the decoded name is written into a fixed 1024-byte stack buffer, char name_a[1024], inside the slice decoding path (cram_decode_slice / cram_to_bam) and the length limitation was validated only afterwards, producing a CWE-121 stack write overflow (also classified CWE-787). Because the overflow is driven by attacker-controlled record data interpreted during normal file parsing, all CRAM format versions are affected and no special configuration or feature toggle is needed. The upstream fix adds a BAM_MAX_QNAME_LEN (254) check in cram_decode_slice before the name is copied, shrinks the temporary name buffer to BAM_MAX_QNAME_LEN + 64, rejects over-long mate names, and additionally widens size/bit-count arithmetic in the beta codec helpers (int to uint32_t/uint64_t) in cram_codecs.c and cram_not_enough_bits.

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 8.8 HIGH
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:H/VA:L/SC:N/SI:N/SA:N
vuln.today AI 7.1 HIGH

File is attacker-delivered but a victim must open it, so UI:R; stack overflow enables memory corruption/possible code execution (I:H) and crashes (A:L), with no data disclosure (C:N).

3.1 AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:L
4.0 AV:N/AC:L/AT:N/PR:N/UI:A/VC:N/VI:H/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
None
Vulnerable system: Integrity
High
Vulnerable system: Availability
Low
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

2
Patch available
Nov 19, 2026 - 17:03 EUVD
CVE Published
Nov 19, 2026 - 15:50 cve.org
HIGH 8.8

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 CRAM decoder validates the 254-character query-name limit only after decoding the name into a 1024-byte stack array. An attacker-controlled CRAM record can provide an overlong query name and overflow the local stack buffer before the later validation runs; all CRAM format versions are affected. Opening such a file can crash the process, corrupt stack data, and may permit arbitrary code execution. This issue is fixed in versions 1.21.2, 1.22.3, 1.23.2, and 1.24.

Technical POC Analysis

CWE-121 (stack-based buffer overflow), also classified CWE-787.

Full technical POC analysis - root cause, step-by-step exploitation and patch breakdown - is part of the Pro and Business plans.

Executive ViewAI

Why It Matters

A high-severity stack-based buffer overflow in HTSlib's CRAM decoder affects all releases prior to the fixed versions. Any application using HTSlib to process attacker-supplied CRAM files, such as samtools or bcftools, is at risk. Successful exploitation could crash the process, corrupt data, or potentially allow arbitrary code execution, though the attacker must convince a user to open a malicious file. Given the widespread use of HTSlib in bioinformatics pipelines, leadership should prioritize remediation to prevent disruption to research workflows and protect data integrity.

Business Impact: High
Compensating Controls

No vendor-released patch identified at time of analysis; vendor states no workaround, only upgrading. Interim mitigations include restricting CRAM file processing to trusted sources and enforcing file validation.

Threat Intelligence Overview

EPSS Score
0.8%
Top 42% exploitable
Prevalence
Low
foundational bioinformatics library, but industry-specific to genomics tooling
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 HIGH
CISA KEV No
Public POC No
EPSS 0.8%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.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
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
Yes
Human Impact
High
Technical Impact
Partial

Priority Score

45
Low Medium High Critical
KEV: 0
EPSS: +1
CVSS: +44
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.

A stack-based buffer overflow occurs when a program writes more data to a buffer located on the stack than it was allocated to hold.

Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.

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-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

CVE-2026-31969 HIGH
7.1 Mar 18

HTSlib versions prior to 1.21.1, 1.22.2, and 1.23.1 contain an out-by-one error in the CRAM decoder's `cram_byte_array_s

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