T09 · Insecure Skill Coding Practices
Error
- Location
- scripts/download_via_sss.mjs:27
- Finding
- Chromium Sandbox Disabled for Untrusted Third-Party Content<![CDATA[ ## Vulnerability Details **File Location**: `scripts/download_via_sss.mjs`, lines 27-31 **Vulnerability Type**: Browser sandbox disabled **Risk Level**: High ### Vulnerable Code ```js const browser = await chromium.launch({ executablePath, headless: true, args: ['--no-sandbox', '--disable-dev-shm-usage'] }); ``` ### Technical Analysis The script launches Chromium with the `--no-sandbox` argument and then navigates to the third-party website `sssinstagram.com`. The Chromium sandbox is a defense-in-depth boundary designed to restrict the filesystem, process, and operating-system access available to a compromised browser renderer. Disabling this protection substantially increases the consequences of a browser vulnerability triggered by malicious advertisements, compromised third-party resources, or a compromised downloader website. The `--disable-dev-shm-usage` option does not create the same security risk, but it does not compensate for the disabled sandbox. ### Attack Path 1. An attacker compromises `sssinstagram.com`, one of its dependencies, or third-party content rendered by the website. 2. The script starts Chromium with `--no-sandbox`. 3. Chromium loads the attacker-controlled browser content. 4. The attacker exploits a suitable Chromium or renderer vulnerability. 5. Because the process sandbox is disabled, the exploit has fewer containment barriers and may access resources available to the account running the downloader. ### Impact Assessment Successful exploitation would operate with the privileges of the user account running this Skill. Depending on the runtime configuration, this could expose the Agent workspace, downloaded media, environment variables accessible to the process, and other files readable or writable by that account. The code does not itself grant root privileges, so host-wide administrative compromise is not established. However, the missing sandbox significantly increases the potential scope of a browser compr ...[truncated 12 chars]
- Remediation
- <![CDATA[ ## Remediation Suggestions - Remove the `--no-sandbox` Chromium argument and retain Chromium's standard process sandbox. - Run the downloader as a dedicated, unprivileged operating-system account. - Do not expose secrets or unrelated workspace files to the browser process. - If the deployment environment cannot support Chromium sandboxing, execute the complete downloader in a separately isolated container or virtual machine with: - A read-only root filesystem. - A dedicated writable output directory. - No host filesystem mounts beyond those strictly required. - No credentials or sensitive environment variables. - Restricted outbound networking. - CPU, memory, process, and execution-time limits. - Keep Chromium patched because the workflow intentionally renders remote, untrusted web content. ]]>
