NPM · SEPTEMBER 2026 · EARLY WARNING

Next.js Image Optimization Vulnerability: AVIF File Risk

EARLY WARNING · UNCONFIRMED. This page describes a developing threat that 0Day surfaced from early signals and has not yet independently confirmed. Details may change. Always verify against the primary sources before acting.
Severity
HIGH
Affected component
next.js (npm)
Patched version
Not yet available
GHSA-2XP9-VWFH-VXW4

An early warning has been issued regarding a potential vulnerability in the Next.js image optimization feature when AVIF files are used. This vulnerability, which is under investigation, could lead to remote code execution.

What happened

An early warning has been issued for a potential vulnerability in the Next.js image optimization feature. This vulnerability is reportedly linked to the underlying `libheif` library, which Next.js uses for image optimization. The issue appears to arise when AVIF files are optimized, potentially leading to remote code execution. Until a fix has propagated, optimization of AVIF files is disabled as a precautionary measure.

The vulnerability is tracked under GHSA-2xp9-vwfh-vxw4 and has been flagged since September 8, 2026. It is important to note that this is an early warning and the details are still under investigation. No authoritative version range has been published for the affected Next.js versions, and no exploitation in the wild has been reported yet.

What to do about it

How 0Day would have caught this

MATCHED TO YOUR ACTUAL DEPENDENCY GRAPH0Day matches every incoming threat signal against your GitHub organization’s full dependency graph, including transitive dependencies. If next.js is anywhere in your dependency tree, the engineers who own the affected repositories get a push alert the moment it is flagged — no manual audit to remember to run.

Read how this differs from waiting on a scanner to catch a known advisory, or see the exact, read-only access 0Day needs to do this for an organization.

Frequently asked questions

Am I affected?

If you are using Next.js for image optimization and processing AVIF files, you may be affected. However, no authoritative version range has been published yet, so it is advisable to monitor the situation closely.

What should I do right now?

Avoid using AVIF file optimization in Next.js until a fix is available. Monitor the primary sources for updates and consider using alternative image formats.

Has this been exploited in the wild?

No, there are no reports of this vulnerability being exploited in the wild at this time.

Where can I find more information?

Consult the GitHub advisories for GHSA-2xp9-vwfh-vxw4 and GHSA-p293-qw3h-jr36 for the latest information on this vulnerability.

Sources

Join the 0Day waitlist →

← Back to all threats