Skip to main content

Next.js: Unauthenticated Remote Code Execution in Image Optimization API when SVG files are used

0
Critical
Published: 10/22/2026 (10/22/2026, 15:52:53 UTC)
Source: GCVE Database
Product: next

Description

A memory-related vulnerability in an upstream library used by Next.js for Image Optimization can lead to unauthenticated remote code execution (RCE) when processing SVG files on glibc-based Linux systems. This affects Next.js versions from 10.0.0 up to but excluding 15.5.28, and from 16.0.0 up to but excluding 16.4.1. The vulnerability is critical and can be mitigated by upgrading the 'sharp' library to version 0.35.5 or later, which is included in patched Next.js releases.

CVSS v4.0

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
Present
Privileges Required
None
User Interaction
None
Vuln. Confidentiality
High
Vuln. Integrity
High
Vuln. Availability
High
Subsq. Confidentiality
High
Subsq. Integrity
High
Subsq. Availability
High
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H

Affected software

npmghsa
next
Affected versions
>=10.0.0 <15.5.28
npmghsa
next
Affected versions
>=16.0.0 <16.4.1

Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 10/22/2026, 17:17:24 UTC

Technical Analysis

Next.js uses an upstream library called 'sharp' for image optimization. A memory-related vulnerability in this library can be exploited to achieve remote code execution without authentication when SVG files are processed on glibc-based Linux environments. The issue affects Next.js versions >=10.0.0 <15.5.28 and >=16.0.0 <16.4.1. Upgrading 'sharp' to version 0.35.5 or higher mitigates the vulnerability. Fresh installs of Next.js automatically include the fixed 'sharp' version. The vulnerability has a CVSS 4.0 vector indicating critical severity with network attack vector, low attack complexity, no privileges required, and no user interaction needed.

Potential Impact

Successful exploitation allows unauthenticated remote code execution on servers running vulnerable Next.js versions on glibc-based Linux. This can lead to full system compromise. There are no known exploits in the wild at this time.

Mitigation Recommendations

Upgrade the 'sharp' library used by Next.js to version 0.35.5 or later. Upgrading Next.js to patched versions (>=15.5.28 and >=16.4.1) ensures that package managers automatically provide the fixed 'sharp' version. Fresh installs of Next.js also include the fixed version. No other workarounds are indicated.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Gcve Source
db.gcve.eu
Osv Id
GHSA-2464-fhr4-w9xw
Osv Schema Version
1.4.0
Ecosystems
["npm"]
Database Specific Severity
CRITICAL
Cvss Version
4.0

Threat ID: 6ada44ae4d27ba8daa6a2f8c

Added to database: 10/22/2026, 17:15:26 UTC

Last enriched: 10/22/2026, 17:17:24 UTC

Last updated: 10/22/2026, 17:17:24 UTC

Views: 3

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses