Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessCraft color-by-plane DICOM, rows>columns
-
DeliveryDeliver file into DCMTK encoding pipeline
-
ExploitVictim re-encodes with true-lossless JPEG codec
-
ExecutiontogglePlanarConfiguration miscomputes row offset
-
PersistHeap buffer overflow write
-
ImpactCrash or potential code execution
Vulnerability Assessment
| Weakness |
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Bounds checking, write limits
MITRE ATT&CK
2 techniques across 2 tactics: Execution, Privilege Escalation The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Exploitation requires that DCMTK 3.7.1 be used to COMPRESS/ENCODE (not merely view) a DICOM image using the true-lossless JPEG codec, that the input pixel data use color-by-plane layout (Planar Configuration = 1, triggering togglePlanarConfiguration8/16), and that the image geometry has more rows than columns so the rows*rows offset miscalculation reaches beyond the buffer. Limiting factors: this is a LOCAL encoder-path bug (AV:L) that needs passive user interaction (UI:P) - a human or automated job must initiate the lossless-JPEG encoding of the attacker's file; it is not reachable by simply sending data to a network listener, and it does not fire on plain parsing/display or on non-planar (interleaved) or square/landscape images. No special privileges are required (PR:N) once the victim processes the file. |
| Impact | This is a genuine memory-corruption bug (CWE-787 out-of-bounds heap write) whose real-world urgency is moderate rather than critical, and the input signals are largely consistent. The CVSS 4.0 vector (AV:L/AC:L/AT:N/PR:N/UI:P) correctly characterizes this as a LOCAL, passive-user-interaction flaw, not a remotely reachable network service bug: the defective code lives in DCMTK's JPEG encoder (djcodece.cc), so a victim must actively run a compression/encoding operation on an attacker-supplied DICOM object. That encoder-side, user-interaction requirement is the single biggest factor limiting real-world risk and is why the 8.5 base score should not be read as 'drop-everything' severity. No EPSS score is supplied and the CVE is NOT in CISA KEV, so there is no evidence of active exploitation; exploitation status is best described as no public exploit identified at time of analysis, though VulnCheck (the reporter) has published an advisory describing the flaw. The vendor decision label is 'this_week', consistent with a patched, credible-but-not-actively-exploited memory-corruption issue rather than an emergency. 'Potential code execution' is plausible given a controlled heap out-of-bounds write, but the sources establish a crash/heap corruption primitive; reliable RCE is not demonstrated in the provided evidence and should be treated as a theoretical upper bound. |
| Exploit ScenarioDerived | An attacker crafts a malicious color-by-plane (planar configuration 1) DICOM image whose pixel grid has more rows than columns, then gets it into a workflow where DCMTK re-encodes it with the true-lossless JPEG codec (for example an archive/PACS ingestion or conversion pipeline that transcodes incoming studies). During planar configuration conversion, togglePlanarConfiguration8/16 computes offsets with rows*rows instead of columns*rows, writing past the allocated heap buffer and corrupting memory, causing a crash and potentially code execution. No weaponized public exploit is identified; only the VulnCheck advisory describing the bug is available. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Nov 19, 2026
Heap out-of-bounds write in the DICOM toolkit DCMTK's JPEG encoder helpers togglePlanarConfiguration8 and togglePlanarConfiguration16 (dcmjpeg/libsrc/djcodece.cc), reached when a color-by-plane (Planar Configuration = 1) image is compressed with the true-lossless JPEG codec. Because the row offset is computed as rows*rows rather than rows*columns, a crafted image whose geometry has more rows than columns drives writes past the end of the heap buffer, crashing the process and potentially enabling code execution in the context of the encoding application. The flaw is local to the encoder path and requires a user or automated job to actively compress the attacker's file (CVSS 4.0 8.5, AV:L/UI:P, PR:N); no public exploit code and no CISA KEV entry were identified at time of analysis, and a vendor patch is available via the referenced upstream commit.
RemediationAI
Apply the upstream fix commit c22836c449bb81834fee5d883e9ebd9d7dab90b9 (referenced by the vendor issue at https://support.dcmtk.org/redmine/issues/1298) to dcmjpeg/libsrc/djcodece.cc, rebuild the dcmjpeg module and relink every DICOM application, gateway or batch converter that links DCMTK; the change rejects undersized buffers and computes offsets from columns, so it is a drop-in replacement for the vulnerable encoder helpers. Because no tagged release version is identified in the available data, track the DCMTK project for the release containing this commit and confirm the shipped version before closing the finding. If rebuilding immediately is not possible, restrict exposure at the encoder boundary: refuse to lossless-JPEG-compress untrusted files whose Planar Configuration is 1, or pre-convert them to interleaved layout, accepting the extra conversion cost and CPU overhead; validate that incoming image geometry has columns >= rows before dispatch to the true-lossless codec, accepting that this rejects or delays legitimate portrait-oriented studies; and run compression jobs for externally sourced DICOM objects under a low-privilege account, container or sandbox so a corrupted heap and crash cannot escalate to host-level code execution, accepting the operational overhead of isolation and constrained resources.
Affected VersionsENISA
Affected Packages
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
DCMTK is the OFFIS reference implementation of DICOM; its dcmjpeg module wraps the IJG JPEG library and, before handing pixel data to the compressor, normalises the sample layout. DICOM Planar Configuration 0 stores pixels interleaved (RGBRGB...), while Planar Configuration 1 stores them color-by-plane (RRR...GGG...BBB...). The functions togglePlanarConfiguration8/16 in dcmjpeg/libsrc/djcodece.cc perform that conversion on the encode path. The root cause is CWE-787 (out-of-bounds write): the inner loops derived the per-row base as 'r_x_rows = r * rows' instead of 'r * columns', and the destination buffer was sized from the caller-supplied numValues rather than from the true pixel count. Whenever rows > columns the computed index exceeds the frame size, so outPtr writes and the final memcpy run past the heap allocation sized new Uint8[numValues] / new Uint16[numValues]; when rows <= columns the same arithmetic merely scrambles the pixel order, which is why the defect stayed latent. The upstream fix at commit c22836c449bb81834fee5d883e9ebd9d7dab90b9 replaces the row/column double loop with a flat index loop over pxPerFrame, computes totalValues = columns * rows * samplesPerPixel * numberOfFrames with size_t promotion, rejects calls where numValues < totalValues, sizes the heap buffer from totalValues, and fixes the memcpy length to totalValues * sizeof(Uint16) for the 16-bit path. The affected code region is visible in the DCMTK-3.7.1 tag at djcodece.cc lines 1503-1540.
Know when Dcmtk 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
CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
Flaw is in the local encoder path requiring a user to initiate lossless-JPEG compression of an attacker file (AV:L, UI:R) with no privileges (PR:N); a controlled heap out-of-bounds write yields high C/I/A.
Primary rating from Vendor (VulnCheck).
CVSS VectorVendor: VulnCheck
DescriptionCVE.org
OFFIS DCMTK 3.7.1 contains a heap buffer overflow vulnerability in togglePlanarConfiguration8 and togglePlanarConfiguration16 in djcodece.cc, which compute row offsets using rows instead of columns. Attackers can supply a crafted color-by-plane DICOM image with more rows than columns that is compressed with the true-lossless JPEG codec to corrupt heap memory, causing crashes and potentially code execution.
Executive ViewAI
A high-severity heap overflow in DCMTK's JPEG encoder could allow code execution when processing maliciously crafted color-by-plane DICOM images, impacting any organization using DCMTK to compress medical imaging data. This poses a risk to patient data confidentiality and system integrity, particularly in clinical or research settings where automated image processing occurs. Leadership should prioritize patching to prevent potential disruptions and data breaches.
Apply vendor patch.
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.
Memory corruption occurs when a program writes data beyond the boundaries of allocated memory regions or accesses memory in unintended ways, violating the integrity of the process's address space.
Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.
OFFIS.de DCMTK 3.6.3 and below is affected by: Buffer Overflow. Rated critical severity (CVSS 9.8), this vulnerability i
Stack-based buffer overflow in the parsePresentationContext function in storescp in DICOM dcmtk-3.6.0 and earlier allows
Buffer Overflow vulnerability in DCMTK v.3.6.8 allows an attacker to execute arbitrary code via the EctEnhancedCT method
An incorrect type conversion vulnerability exists in the DVPSSoftcopyVOI_PList::createFromImage functionality of OFFIS D
DCMTK v3.6.7 was discovered to contain a memory leak via the T_ASC_Association object. Rated high severity (CVSS 7.5), t
(1) movescu.cc and (2) storescp.cc in dcmnet/apps/, (3) dcmnet/libsrc/scp.cc, (4) dcmwlm/libsrc/wlmactmg.cc, (5) dcmprsc
OFFIS DCMTK's (All versions prior to 3.6.7) service class user (SCU) is vulnerable to relative path traversal, allowing
OFFIS DCMTK's (All versions prior to 3.6.7) service class provider (SCP) is vulnerable to path traversal, allowing an at
dcmdata in DCMTK before 3.6.9 has a segmentation fault via an invalid DIMSE message. Rated medium severity (CVSS 5.3), t
Heap over-read in DCMTK through 3.7.0 allows unauthenticated remote attackers to crash applications or leak adjacent hea
Deeply nested DICOM sequence (SQ) elements delivered to a DCMTK 3.7.0-based service drive the parser into unbounded recu
dcmnet in DCMTK before 3.6.9 has a segmentation fault via an invalid DIMSE message. Rated medium severity (CVSS 4.3), th
EUVD-2026-130211
GHSA-vhjh-fq99-4gmr
NVD
CVE.org
EPSS
Exploit-DB