CVE-2025-54782
JavaScript vulnerability analysis and mitigation

Overview

A critical Remote Code Execution (RCE) vulnerability (CVE-2025-54782) was discovered in the @nestjs/devtools-integration package affecting versions 0.2.0 and below. The vulnerability, disclosed on August 1, 2025, allows arbitrary code execution on a developer's local machine when the package exposes a local development HTTP server with an API endpoint that uses an unsafe JavaScript sandbox implementation. Due to improper sandboxing and missing cross-origin protections, any malicious website visited by a developer can execute arbitrary code on their local machine (GitHub Advisory, Socket Blog).

Technical details

The vulnerability exists in the /inspector/graph/interact endpoint which accepts JSON input containing a code field and executes it using Node.js vm.runInNewContext sandbox. The implementation closely resembles the abandoned safe-eval library, making it vulnerable to sandbox escape techniques. The server was configured with inadequate CORS protections, setting Access-Control-Allow-Origin to a fixed domain without validating the request's actual origin. The vulnerability carries a CVSS v4.0 score of 9.4 (Critical) with vector string CVSS:4.0/AV:A/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H (GitHub Advisory, SecurityOnline).

Impact

This vulnerability allows attackers to execute arbitrary code on a developer's machine simply by having them visit a malicious website. The attack requires no user interaction and can be triggered through malvertising or phishing attacks. The impact is particularly severe as it provides full remote code execution capabilities on the developer's local system (Socket Blog, SecurityOnline).

Mitigation and workarounds

The vulnerability has been patched in version 0.2.1 of @nestjs/devtools-integration. The fix includes replacing the unsafe sandbox implementation with @nyariv/sandboxjs, adding strict origin and content-type validation, and introducing authentication for the devtools connection. Users are strongly encouraged to upgrade to the patched version immediately (GitHub Advisory, ASEC).

Community reactions

The security community has praised the quick response and thorough remediation by the NestJS team. The vulnerability was discovered through Socket's AI-based malware detection system and responsibly disclosed. The maintainers implemented a defense-in-depth strategy with multiple layers of protection against similar vulnerabilities in the future (Socket Blog).

Additional resources


SourceThis report was generated using AI

Related JavaScript vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

GHSA-365g-vjw2-grx8HIGH8.8
  • JavaScriptJavaScript
  • n8n
NoNoOct 09, 2025
GHSA-j44m-5v8f-gc9cHIGH7.7
  • JavaScriptJavaScript
  • flowise
NoYesOct 10, 2025
CVE-2025-11569HIGH7.7
  • JavaScriptJavaScript
  • cross-zip
NoNoOct 10, 2025
CVE-2025-61927HIGH7.2
  • JavaScriptJavaScript
  • happy-dom
NoYesOct 10, 2025
CVE-2025-61925MEDIUM6.5
  • JavaScriptJavaScript
  • astro
NoYesOct 10, 2025

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management