T08 · Insecure Dependencies
Warning
- Location
- SKILL.md:19
- Finding
- Unpinned Global Installation of a Mutable Third-Party Dependency<![CDATA[ ## Vulnerability Details **File Location**: `SKILL.md:19-23`; additional occurrence at `CONTRIBUTING.md:23-26` **Vulnerability Type**: Unpinned third-party dependency and mutable package tag **Risk Level**: Medium The installation documentation instructs users to install the `agent-browser` npm package globally without pinning an audited version. The contribution guide additionally recommends the mutable `latest` tag. ### Vulnerable Code `SKILL.md:19-23`: ```bash npm install -g agent-browser agent-browser install agent-browser install --with-deps ``` `CONTRIBUTING.md:23-26`: ```markdown 1. Install the latest version ```bash npm install -g agent-browser@latest ``` ``` ### Technical Analysis The effective code installed by these commands is determined by the npm registry at installation time rather than by a version reviewed with this Skill. The `latest` tag is explicitly mutable, while omitting a version normally resolves through the same mutable distribution tag. Global npm installation may execute package lifecycle scripts with the permissions of the invoking user. The subsequent `agent-browser install` commands also delegate browser and, when `--with-deps` is used, system-dependency installation to that newly downloaded tool. Consequently, a compromised npm account, malicious package release, compromised distribution tag, or unexpected upstream change could cause code not represented in the audited project to execute locally. The package and repository names shown in the documentation are consistent with the declared browser-automation purpose; the reviewed files contain no evidence that the current upstream package is malicious. The risk arises from the mutable, unverified supply-chain installation process. ### Attack Path 1. An attacker compromises the upstream package publisher, npm account, release pipeline, or mutable `latest` distribution tag. 2. The attacker publishes a modified `agent-browser` release containing a malicio ...[truncated 1291 chars]
- Remediation
- <![CDATA[ ## Remediation Suggestions 1. Pin `agent-browser` to a specific version that has been reviewed and tested: ```bash npm install -g agent-browser@<audited-version> ``` 2. Remove `@latest` from troubleshooting and contribution instructions. Update the pinned version through an explicit review process rather than resolving a mutable tag at installation time. 3. Document verification of package provenance and integrity, such as checking npm provenance attestations, expected package metadata, and published integrity hashes before installation. 4. Prefer a project-local dependency with a lockfile over a global installation where practical. Commit and review the lockfile so transitive dependency changes are visible. 5. Advise users not to run npm or `agent-browser install --with-deps` as root unless system dependencies genuinely require elevation. Separate privileged operating-system package installation from unprivileged npm package execution. 6. In automated environments, use a restricted container or sandbox with minimal filesystem access, no unrelated credentials, and constrained network permissions. 7. Review installer behavior and upstream release changes before updating the pinned version, including npm lifecycle scripts and any resources downloaded by `agent-browser install`. ]]>
