Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessAuthenticate with low-privileged FastGPT account
-
DeliveryAccess JavaScript code sandbox execution feature
-
ExploitSubmit import/**/("child_process") payload
-
ExecutionRegex blocklist fails to match comment-obfuscated import
-
PersistNode.js runtime resolves dynamic import() outside safeRequire Proxy
-
ImpactCall execSync for arbitrary OS commands as uid=100(sandbox)
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Code injection prevention, sandbox exec
MITRE ATT&CK
2 techniques across 2 tactics: Execution, Initial Access The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Exploitation requires a valid, low-privileged FastGPT user account (confirmed by CVSS PR:L) with access to the platform's JavaScript code sandbox execution feature. The sandbox must be running a Node.js version that supports native ES dynamic import() - modern Node.js versions (12+) satisfy this. The attacker submits JavaScript containing import//("child_process") where the block comment // sits between the import keyword and the opening parenthesis; no other configuration or setup is needed. Exploitation is bounded by the sandbox container: post-exploitation access is as uid=100(sandbox), and CVSS S:U confirms the exploit does not inherently escape the container boundary. Limiting factors are: (1) the requirement for an authenticated platform account, and (2) the JavaScript sandbox feature must be accessible to that account - installations where sandbox access is restricted to internal/admin roles have meaningfully reduced exposure. |
| Impact | CVSS 6.3 (Medium) with vector AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:L. The network attack vector and low complexity reflect that exploitation is straightforward once authenticated access is obtained - the bypass is a single-token substitution documented verbatim in the advisory. The PR:L (low-privilege) requirement is the primary limiting factor: the attacker must hold a valid FastGPT account with access to the code sandbox feature. Scope:Unchanged (S:U) and the CIA impact ratings of Low each indicate that post-exploitation impact is bounded by the sandbox container's privileges (uid=100), not the host system - lateral movement risk depends on the specific container network and privilege configuration, which is outside the CVE's scope. No CISA KEV listing and no EPSS data were provided; active exploitation cannot be confirmed. However, the trivial reproducibility of the bypass (inserting /**/ between import and the parenthesis) means the effective exploitation complexity is lower than AC:L already implies for anyone reading the advisory. The CVSS score underrepresents the ease of exploitation while appropriately capturing the contained blast radius. |
| Exploit ScenarioDerived | An authenticated FastGPT user navigates to the code execution sandbox feature and submits the payload: import/**/("child_process"). The sandbox worker's regex fails to match the comment-obfuscated import, the Node.js runtime resolves the dynamic import successfully, and the user calls execSync('id') or any other OS command, achieving arbitrary command execution as uid=100(sandbox) inside the container. No separately published POC code exists beyond the bypass technique described in the vendor advisory, but the technique requires no specialized tooling. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – May 29, 2026
Sandbox escape in FastGPT's JavaScript code execution worker allows authenticated remote attackers to execute arbitrary OS commands inside the sandbox container by bypassing a regex-based blocklist. The sandbox at projects/code-sandbox/src/pool/worker.ts:356 blocks dynamic import() using a regex that matches only ASCII whitespace between 'import' and '(', failing to account for JavaScript's syntactically valid block comment syntax - the payload import/**/("child_process") parses correctly by the JS engine but evades the regex entirely. Because the safeRequire Proxy only intercepts require() and not native ES import(), the attacker gains direct access to child_process and execSync as uid=100(sandbox). No public exploit identified at time of analysis, but the bypass technique is fully documented in the vendor advisory and is trivially reproducible by any authenticated user.
RemediationAI
Upgrade FastGPT to version 4.15.0-beta1 or later, which addresses the regex bypass in the sandbox worker per the vendor advisory at https://github.com/labring/FastGPT/security/advisories/GHSA-f5mq-qxm4-5mvc. The upstream fix should replace or augment the regex-based blocklist with comment-stripping preprocessing or an AST-based analysis before blocklist evaluation - regex-based sandboxing of a full programming language is inherently fragile. As an immediate compensating control prior to patching, restrict access to FastGPT's code sandbox execution feature to only highly trusted, internal users by adjusting platform-level permissions, since exploitation requires authenticated access (PR:L). Additionally, audit sandbox container egress rules and drop unnecessary Linux capabilities to limit the scope of any successful exploitation to the container boundary. Note that restricting sandbox access may degrade core platform functionality for end users.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
FastGPT (CPE: cpe:2.3:a:labring:fastgpt:*:*:*:*:*:*:*:*) is a Node.js-based AI Agent platform that exposes a JavaScript sandbox for executing user-supplied code. The sandbox worker implements a regex blocklist (/\bimport\s*\() to prevent Node.js's native dynamic import() - an ES module feature that allows runtime module loading. However, the ECMAScript specification permits block comments (/* ... */) syntactically between import and its argument list, and the \s character class does not match the bytes comprising /* */. The sandbox's module access control relies on a safeRequire Proxy to intercept CommonJS require() calls, but this Proxy does not wrap native import(), leaving a gap when the regex guard fails. CWE-94 (Improper Control of Generation of Code - Code Injection) accurately describes the root cause: input code is evaluated without sufficient syntactic normalization (e.g., comment stripping or AST parsing) prior to blocklist enforcement.
Know when Fastgpt gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:L
Primary rating from Vendor (GitHub_M) · only source for this CVE.
CVSS VectorVendor: GitHub_M
Lifecycle Timeline
1DescriptionCVE.org
FastGPT is an AI Agent building platform. Prior to 4.15.0-beta1, the JavaScript sandbox worker at projects/code-sandbox/src/pool/worker.ts:356 blocks dynamic import() with the regex /\bimport\s*\(/.test(code). JavaScript syntax accepts a block comment between import and (; the regex matches only ASCII whitespace, and the bytes /, *, *, / are not in the \s character class. The payload import/**/("child_process") parses as a syntactically valid dynamic import that the regex does not detect. Because import() is not wrapped by the safeRequire Proxy (which only proxies require), the attacker loads child_process and calls execSync - arbitrary command execution as uid=100(sandbox) inside the sandbox container. This vulnerability is fixed in 4.15.0-beta1.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Code injection occurs when an application accepts user input and passes it directly into a language interpreter or evaluator without proper sanitization.
Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.
FastGPT is an AI Agent building platform. Prior to version 4.9.12, the LastRoute Parameter on login page is vulnerable t
Unauthenticated HTTP proxy abuse in FastGPT (AI Agent platform) prior to v4.14.9.5 allows remote attackers to relay arbi
Remote code execution in FastGPT's agent-sandbox component (versions 4.14.10 through 4.14.12) lets any network-adjacent,
NoSQL injection in FastGPT <4.14.9.5 password authentication allows unauthenticated remote attackers to bypass login con
Channel hijack and denial of service in FastGPT (labring/FastGPT) before 4.15.2 lets an unauthenticated remote attacker
GitHub Actions artifact-poisoning (pwn request) in labring/FastGPT allows an external attacker who opens a pull request
Authentication bypass in FastGPT 4.15.0-beta4 lets unauthenticated remote attackers forge JWTs and access internal plugi
NoSQL injection in FastGPT versions before 4.14.9.5 allows authenticated attackers to bypass password verification on th
FastGPT versions 4.14.8.3 and below contain a critical arbitrary code execution vulnerability in the fastgpt-preview-ima
Cross-tenant file disclosure in FastGPT prior to v4.15.0-beta5 allows an attacker to read another team's stored files by
Cross-tenant data disclosure in FastGPT 4.14.17 through 4.15.0-beta5 lets a low-privileged tenant user read another tena
Server-side request forgery in FastGPT before 4.15.0-beta4 lets an authenticated team member abuse the HTTP-tool OpenAPI
EUVD-2026-33431
NVD
CVE.org
EPSS
Vulnrichment
GitHub
VulDB
Exploit-DB