T08 · Insecure Dependencies
Warning
- Location
- SKILL.md:17
- Finding
- Unpinned Third-Party Package and Source Installation## Vulnerability Details **File Locations**: - `SKILL.md:17-26` - `CONTRIBUTING.md:23-26` **Vulnerability Type**: Unpinned and mutable third-party dependencies **Risk Level**: Medium ### Vulnerable Code `SKILL.md:17-26` ```bash npm install -g agent-browser agent-browser install agent-browser install --with-deps ``` ```bash git clone https://github.com/vercel-labs/agent-browser cd agent-browser pnpm install pnpm build agent-browser install ``` `CONTRIBUTING.md:23-26` ```bash 1. Install the latest version ```bash npm install -g agent-browser@latest ``` ``` ### Technical Analysis The installation instructions retrieve and execute mutable third-party content without pinning an audited package version, source commit, or dependency integrity value. `npm install -g agent-browser` resolves the package version according to the npm registry's current state, while `agent-browser@latest` explicitly follows a mutable distribution tag. Consequently, the installed artifact can change after this Skill has been reviewed. npm package installation may also execute lifecycle scripts with the privileges of the invoking user. The source installation procedure clones the repository's default branch rather than a specific audited commit or signed release. It then runs `pnpm install` and `pnpm build`, allowing the current upstream source and its transitive dependency graph to execute build or lifecycle logic. No lockfile, frozen dependency resolution, checksum, signature, or provenance verification is required by the instructions. The subsequent `agent-browser install --with-deps` command may install additional browser or system dependencies, increasing the amount of externally sourced code and potentially requiring elevated permissions depending on the host configuration. ### Attack Path 1. An attacker compromises the npm package, its mutable `latest` release, the upstream repository, a maintainer ac ...[truncated 1666 chars]
- Remediation
- ## Remediation Suggestions 1. Pin `agent-browser` to a specifically reviewed version rather than using an implicit version or `@latest`, for example: ```bash npm install --global agent-browser@<audited-version> ``` 2. Record and verify the expected npm package integrity digest and package provenance before installation. Document the trusted publisher and official package identity to reduce dependency-confusion and package-substitution risk. 3. For source installation, check out a specific audited commit or signed release: ```bash git clone https://github.com/vercel-labs/agent-browser cd agent-browser git checkout --detach <audited-commit-sha> ``` Verify the commit or release signature where upstream signing is available. 4. Require a committed lockfile and use frozen dependency resolution, such as: ```bash pnpm install --frozen-lockfile ``` Review dependency changes before updating the pinned source revision or package version. 5. Avoid global installation where possible. Prefer an isolated project environment, container, or restricted execution account with access only to the files and network destinations required for browser automation. 6. Do not run npm, pnpm, build scripts, or `agent-browser install --with-deps` with administrative privileges unless explicitly necessary. Separate operating-system dependency installation from package installation and review the exact system changes first. 7. Document expected lifecycle and installer behavior. Where practical, initially inspect packages with lifecycle scripts disabled, review the scripts, and only then permit required installation actions. 8. Replace the recommendation in `CONTRIBUTING.md` to install `@latest` with the same audited version used by the Skill, and update that version only after a new security review.
