T08 · Insecure Dependencies
- Location
SKILL.md:15- Finding
Unpinned Third-Party SDK Installation Creates Supply-Chain Risk
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md:15andSKILL.md:41
Vulnerability Type: Unpinned npm dependency
Risk Level: MediumVulnerable Code
yaml install: npm install snap-solana-sdktext ## Setup npm install snap-solana-sdkTechnical Analysis
The installation instructions retrieve
snap-solana-sdkwithout specifying an exact reviewed version. The supplied project also contains no package manifest or lockfile that constrains the resolved version or verifies its integrity.Consequently, the code installed by this command may change after the Skill has been reviewed. If the package, its publishing account, or one of its transitive dependencies is compromised, a later installation could retrieve malicious code. npm packages can also define lifecycle scripts that execute during installation.
This finding does not establish that the current
snap-solana-sdkpackage is malicious. It identifies an unsafe dependency-resolution practice that exposes users to a mutable supply-chain component.Attack Path
- An attacker compromises the npm package, its maintainer account, or a transitive dependency.
- The attacker publishes a malicious version under the same package name.
- A user follows the documented
npm install snap-solana-sdkinstruction. - npm resolves the unconstrained package to the attacker-controlled release.
- Malicious lifecycle scripts or imported runtime code execute in the installation or agent process.
Impact Assessment
Successful exploitation could execute arbitrary code with the privileges of the user running npm or the agent. Depending on that account's access, the malicious dependency could read environment variables, wallet-related material available to the process, local files, or network credentials, and could alter transactions handled by the Skill.
The affected scope is limited by the operating-system permissions and secrets avail ...[truncated 46 chars]
- Remediation
View remediation
Remediation Suggestions
- Pin the SDK to an exact reviewed version, such as
snap-solana-sdk@x.y.z, rather than using an unconstrained package name. - Add a package manifest and commit a lockfile containing npm integrity hashes.
- Use
npm ciin deployment and installation workflows so dependency resolution cannot silently change. - Review both direct and transitive dependencies before updating the lockfile.
- Use automated dependency scanning and package provenance verification.
- Disable npm lifecycle scripts with
--ignore-scriptswhen the SDK does not require them. - Run installation and the agent under a dedicated, least-privileged account without unnecessary access to wallet keys or unrelated secrets.
- Pin the SDK to an exact reviewed version, such as
