CVE-2025-46333

z2d OOB composition could lead to invalid memory access and corruption

HIGH
7.3
CVSS Score
Published: April 25, 2025 at 08:20 PM UTC
Updated: June 17, 2026 at 09:26 AM UTC
1 product affected across 1 vendorZ2D

Using z2d by vancluever?

Get instant alerts when new vulnerabilities affect z2d - before attackers find them.

Real-time alertsTrack your software stackFree plan available
Severity
HIGH7.3
Exploit prediction
EPSS 0.2%
SSVC
No known exploit

Description

z2d is a pure Zig 2D graphics library. Versions of z2d after `0.5.1` and up to and including `0.6.0`, when writing from one surface to another using `z2d.compositor.StrideCompositor.run`, and higher-level operations when the anti-aliasing mode is set to `.default` (such as `Context.fill`, `Context.stroke`, `painter.fill`, and `painter.stroke`), the source surface can be completely out-of-bounds on the x-axis, but not on the y-axis, by way of a negative offset. This results in an overflow of the value controlling the length of the stride. In non-safe optimization modes (consumers compiling with `ReleaseFast` or `ReleaseSmall`), this could potentially lead to invalid memory accesses or corruption. This issue is patched in version `0.6.1`. Users on an untagged version after `v0.5.1` and before `v0.6.1` are advised to update to address the vulnerability. Those still on Zig `0.13.0` are recommended to downgrade to `v0.5.1`.

Affected

Our own answer: ranges merged, affected separated from platform-only, with confidence and review flags.

v ≤ 0.6.0

Remediation

No guide yet

No remediation guidance has been written for this CVE yet, and no fixed version or vendor advisory is recorded against it.

SSVC — Action Prioritization

SSVCNo known exploitNot automatableTotal impact

SSVC signals action urgency (what to patch first), separate from CVSS which measures severity.

CVSS

7.3HIGHGitHub_M
Vector?

Quick Info

StatusDEFERRED
CWE
CWE-119CWE-122CWE-190

Get alerted

Stop reading CVE feeds looking for your own stack

Track the products you run and VulnTracker tells you when a new CVE affects them — with what is known about fixing it, and nothing about the rest.

Free plan, no card