T09 · Insecure Skill Coding Practices
- Location
scripts/browser_search.js:89- Finding
Chromium Browser Sandbox Is Explicitly Disabled
- Content
View full analysis
Vulnerability Details
File Location:
scripts/browser_search.js:89-94
Vulnerability Type: Chromium sandbox disabled while processing untrusted websites
Risk Level: HighComplete Code Snippet:
javascript const browser = await puppeteer.launch({ headless: true, executablePath: "/usr/bin/chromium", args: ["--no-sandbox", "--disable-gpu", "--disable-dev-shm-usage"], });Technical Analysis
The browser automation launches Chromium with the
--no-sandboxargument. Browser search visits public websites and processes remotely controlled HTML, JavaScript, media, and other content. Chromium's sandbox is a major defense-in-depth boundary intended to contain a compromised renderer or browser process.Disabling this boundary is not necessary for the declared search functionality. It materially increases the consequences of a Chromium or Puppeteer vulnerability because malicious web content may be able to escape the browser process and access resources available to the operating-system account running the Skill.
The use of a fixed user agent does not provide a security boundary. Running Chromium in headless mode also does not compensate for disabling the sandbox.
Attack Path
- A user invokes the Skill with the optional
--use_browsermode. - The Python entry point starts this Puppeteer script.
- Chromium visits Xiaohongshu and X/Twitter and processes content controlled by those platforms, advertisers, embedded third parties, or compromised accounts.
- Malicious content exploits a Chromium vulnerability.
- Because Chromium was launched with
--no-sandbox, an important containment layer is unavailable. - The attacker may execute code or access data with the permissions of the Skill's operating-system account.
Impact Assessment
Successful exploitation could expose files, environment variables, API credentials, network access, and other resources available to the Skill pr ...[truncated 210 chars]
- A user invokes the Skill with the optional
- Remediation
View remediation
Remediation Suggestions
- Remove the
--no-sandboxargument and run Chromium with its normal sandbox enabled. - Execute browser automation as a dedicated, unprivileged operating-system user.
- Do not run the browser as root.
- If the Chromium sandbox cannot be enabled, run browser automation inside a disposable, hardened container or virtual machine.
- Give that isolation environment a read-only filesystem where possible, no host-sensitive mounts, no inherited credentials, limited memory and CPU, and a restricted outbound network policy.
- Keep Chromium and Puppeteer patched and use compatible, reviewed versions.
- Treat all browser results as untrusted data and avoid executing or interpreting returned content as code.
- Remove the
