Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessCraft malicious JPEG 2000 file
-
DeliveryDeliver to app using OpenHTJ2K
-
ExploitDecoder parses packet header
-
Executionnum_passes exceeds pass_length[128]
-
PersistOverflow corrupts adjacent memory
-
ImpactPotential arbitrary code execution
Vulnerability Assessment
| Weakness |
CWE
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 | Exploitation requires the target to parse an attacker-controlled JPEG 2000 / HTJ2K codestream with OpenHTJ2K 0.18.4 or earlier; specifically, the crafted packet header must declare a coding-pass total for a codeblock that exceeds the 128-entry pass_length[] array so that j2k_precinct_subband::parse_packet_header() accumulates block->num_passes beyond the bound. The limiting factor is that the vulnerable code only runs during decode, so an application or pipeline must actually ingest the malicious image - in interactive tools this implies user interaction (opening/submitting a file), while automated server-side conversion pipelines meet the no-interaction assumption in the published vector. No authentication is required by the code path itself (PR:N per CVSS), and no non-default configuration is needed - any use of the affected decode function on untrusted input is exposed. |
| Impact | The published CVSS 3.1 vector (AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H = 9.8 critical) treats this as a remote, unauthenticated, no-interaction network flaw, and CISA SSVC confirms the technical impact is total and the issue is automatable. However, these signals conflict with the nature of the code: this is an image/codestream parser, so real-world exploitation requires the victim application to actually process an attacker-supplied JPEG 2000 file - closer to UI:R (user opens/submits a file) unless the library sits behind an automated server-side ingestion pipeline, in which case UI:N is justified. That distinction is why the raw metrics look worse than the practical risk for most deployments. Counterbalancing the 9.8 score, EPSS is only 0.20% (10th percentile), there is no CISA KEV listing and no public exploit identified at time of analysis, and SSVC exploitation status is 'none.' Net: a genuinely high-severity memory-corruption bug worth patching, but not a confirmed in-the-wild priority - prioritize based on whether you auto-ingest untrusted JPEG 2000 content. |
| Exploit ScenarioDerived | An attacker crafts a malicious JPEG 2000 (HTJ2K) file whose packet headers declare a coding-pass count exceeding 128 for a codeblock. When a victim application built on OpenHTJ2K 0.18.4 or earlier decodes the file, parse_packet_header() writes past the pass_length[128] array, corrupting memory and enabling a crash or potential code execution. No public proof-of-concept is identified at this time, and attack complexity is low (AC:L) - a single malformed file triggers the bug. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Jul 22, 2026
Arbitrary code execution in OpenHTJ2K (an open-source High Throughput JPEG 2000 codec by osamu620) versions 0.18.4 and earlier stems from an unchecked coding-pass counter overflowing the fixed pass_length[128] array while parsing crafted JPEG 2000 packet headers. An attacker who supplies a malicious J2K/HTJ2K image to an application built on the library can corrupt adjacent memory and potentially execute code. No public exploit identified at time of analysis; EPSS is low (0.20%) and CISA SSVC rates current exploitation as none, though technical impact is total and the flaw is automatable.
RemediationAI
Update OpenHTJ2K past the fixed commit 0778b93, which adds a kMaxCodingPasses=128 bound and throws before num_passes can exceed the pass_length[] array; confirm the exact patched release on the project's releases page (https://github.com/osamu620/OpenHTJ2K/releases) and CHANGELOG (https://github.com/osamu620/OpenHTJ2K/blob/main/CHANGELOG), since a released patched version is not independently confirmed from the provided data - the fix is currently traceable to a commit rather than a tagged version. If you cannot rebuild immediately, the practical compensating control is to stop feeding untrusted JPEG 2000/HTJ2K input to the library: gate decoding behind validation or sandbox the decoder process (seccomp/container) so an overflow cannot escalate, and disable or restrict any automated/server-side ingestion of externally supplied .j2k/.jph files. These controls reduce exposure but block or slow legitimate JPEG 2000 processing, so scope them to untrusted sources. Verify your build includes the fix via https://github.com/osamu620/OpenHTJ2K/compare/0778b93...v0.18.4.
Affected VersionsENISA
Affects your stack
Find out whether the stacks and servers you run are on an affected version.
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
OpenHTJ2K implements the ISO/IEC 15444-15 High Throughput JPEG 2000 (HTJ2K) codestream format in C++. The defect is in j2k_precinct_subband::parse_packet_header() in source/core/coding/coding_units.cpp, which decodes the per-codeblock packet-header syntax of a JPEG 2000 tile. For each codeblock the parser reads a segment_passes value from the untrusted stream and accumulates it into block->num_passes, which indexes a fixed-size pass_length[128] array. Because the running total was cast straight into a uint8_t with no bounds check, an attacker-controlled pass count could exceed 128 (and wrap the 8-bit counter), driving writes past the end of the array. This is the CWE-121 stack-based buffer overflow class (write beyond a fixed-length buffer using an attacker-influenced length); note the vendor's own fix comment describes it as a heap buffer overflow in pass_length[128], so the exact memory region depends on how the codeblock object is allocated.
Know when the next one hits your stack
- 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
AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
File-parsing library, so decode of an attacker-supplied image is needed (UI:R); no auth on the code path (PR:N) and a single malformed file triggers it (AC:L), yielding full memory-corruption impact.
Primary rating from Vendor (mitre).
CVSS VectorVendor: mitre
Lifecycle Timeline
2DescriptionCVE.org
Buffer Overflow vulnerability in OpenHTJ2K v.0.18.4 and before allows an attacker to execute arbitrary code via the j2k_precinct_subband::parse_packet_header() in source/core/coding/coding_units.cpp
Executive ViewAI
Critical arbitrary code execution vulnerability in OpenHTJ2K JPEG 2000 codec (versions 0.18.4 and earlier) enables complete system compromise when processing malicious image files-affecting document imaging, archival, medical imaging, and document processing systems. No vendor-released patch currently exists, forcing organizations to implement workarounds while managing ongoing exploitation risk. The vulnerability's high technical impact and automatable nature create sustained organizational risk until remediation is available.
No vendor-released patch identified at time of analysis. Interim mitigations: (1) restrict JPEG 2000 image sources to explicitly pre-approved internal suppliers, rejecting all untrusted files; (2) implement header validation to reject non-conforming J2K packet structures; (3) sandbox or containerize all image processing workloads to limit code execution blast radius; (4) deploy network segmentation to isolate systems running OpenHTJ2K from critical infrastructure; (5) disable JPEG 2000 support for non-business-critical workflows; (6) implement enhanced monitoring for heap corruption, abnormal process behavior, or unexpected code execution in affected systems.
Threat Intelligence Overview
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.
What every action level means
SSVC AssessmentENISA
Priority Score
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.
EUVD-2026-44580
GHSA-hr36-79f7-75x7
NVD
CVE.org
EPSS
Vulnrichment
VulDB
Exploit-DB