Impact
FastGPT’s JavaScript sandbox worker contains a regex that blocks dynamic import statements using only ASCII whitespace. The regex fails to recognize a syntactically valid import statement that interleaves a block comment, allowing an attacker to load the child_process module and execute arbitrary shell commands as uid=100 inside the sandbox container. This results in remote code execution.
Affected Systems
The vulnerability applies to the FastGPT platform from labring, affecting all releases prior to 4.15.0-beta1. Users running the sandbox component in these versions are exposed.
Risk and Exploitability
With a CVSS score of 6.3 the risk is moderate, and no EPSS data is currently available. The vulnerability is not listed in the CISA KEV catalog. The likely attack vector is the injection of crafted JavaScript code into the code-sandbox where the import statement is parsed. Successful exploitation would allow an attacker to run arbitrary commands inside the sandbox container.
OpenCVE Enrichment