T08 · Insecure Dependencies
- Location
install.sh:54- Finding
Mutable Dependencies and Browser Artifacts Are Installed Without a Lockfile or Integrity Verification
- Content
View full analysis
Vulnerability Details
File Location:
install.sh:54-62; related dependency declarations atpackage.json:12-15and installation instructions atSKILL.md:53
Vulnerability Type: Supply-chain exposure through mutable dependency resolution
Risk Level: MediumVulnerable code (
install.sh:54-62):bash # 3. Install npm packages locally in the skill directory echo "==> Installing npm dependencies..." cd "$SCRIPT_DIR" [ ! -f package.json ] && npm init -y --silent npm install --save playwright-extra puppeteer-extra-plugin-stealth 2>&1 | tail -3 # 4. Install Chromium browser echo "==> Downloading Chromium..." npx playwright install chromium 2>&1 | tail -5Related dependency declarations (
package.json:12-15):json "dependencies": { "playwright-extra": "^4.3.6", "puppeteer-extra-plugin-stealth": "^2.11.2" }Technical Analysis
The project does not include a package lockfile, and its dependencies use caret version ranges. Consequently, each installation can resolve package versions that differ from those reviewed during the audit. The installation script also invokes
npm installdirectly and executesnpx playwright install chromium, retrieving packages and browser artifacts from external infrastructure at installation time.npm packages may execute lifecycle scripts during installation. If an allowed dependency release, transitive dependency, npm account, registry response, or downloaded browser artifact is compromised, attacker-controlled content could execute under the privileges of the user running
install.sh.The script invokes
apt-get,apk, oryumwithout privilege dropping. In container or administrative environments, it may therefore be run as root, increasing the impact of a supply-chain compromise. No evidence was found that the currently declared packages are malicious; the vulnerability is the mutable and insufficiently verified in ...[truncated 1398 chars]- Remediation
View remediation
Remediation Suggestions
- Pin all direct dependencies to reviewed exact versions rather than caret ranges.
- Generate, review, and commit a
package-lock.json, then replacenpm installwithnpm ci. - Explicitly declare every package used by
npx, including the appropriate Playwright package, and invoke its local binary instead of allowingnpxto resolve missing packages dynamically. - Use
npm ci --ignore-scriptswhere dependency functionality permits it. If lifecycle scripts are required, explicitly audit and allow only the necessary scripts. - Verify downloaded browser artifacts using publisher-provided cryptographic checksums or signatures.
- Run dependency and browser installation as a dedicated unprivileged account. Separate privileged operating-system package installation into a reviewed administrative step.
- Add automated dependency review, vulnerability scanning, and lockfile-integrity checks to the release process.
- Avoid modifying dependency declarations during installation by removing
--savefrom runtime setup scripts.
