Description

A critical remote code execution (RCE) vulnerability, identified as CVE-2025-11953, has been discovered in the @react-native-community/cli NPM package, which powers the command-line interface for React Native a framework used by millions of developers for cross-platform app development. With nearly two million weekly downloads, this flaw poses a major risk. Rated CVSS 9.8, it allows unauthenticated attackers to execute arbitrary system commands remotely via the package’s development server due to unsafe handling of user input. The /open-url endpoint forwards input directly to the open NPM library’s function, which can spawn OS-level processes. JFrog researchers demonstrated that on Windows, attackers could execute arbitrary commands such as launching calc.exe or writing proof-of-concept files like pwned.txt. On macOS and Linux, the vulnerability is harder to exploit directly but can still be abused through malicious URI handlers or file schemes. The risk is further increased by a separate issue in the Metro bundler, which binds to all network interfaces (0.0.0.0) by default, despite console logs indicating localhost-only access. This exposes development servers to remote networks, transforming a local flaw into a potentially remote exploit vector. Developers using vulnerable versions of the CLI specifically @react-native-community/cli-server-api 4.8.0 through 20.0.0-alpha.2 are at risk, especially in environments where Metro is used for hot reloading or the CLI is globally installed. Meta’s security team swiftly released a fix in version 20.0.0, and all users should update immediately using npm install @react-native-community/cli@latest, verifying with npm list @react-native-community/cli-server-api. As a temporary safeguard, developers should start the server bound to localhost using npx react-native start --host 127.0.0.1. This incident underscores the dangers of unsafe third-party functions and highlights the need for secure default configurations in developer tools.