T08 · Insecure Dependencies
- Location
scripts/regenerate-pack.sh:10- Finding
Unpinned Third-Party Package Execution Through npx
- Content
View full analysis
Vulnerability Details
File Location:
scripts/regenerate-pack.sh, lines 10–12
Vulnerability Type: Supply-chain exposure through unpinned package execution
Risk Level: MediumVulnerable Code
bash npx openpersona create \ --config "skills/secondme-skill/persona.json" \ --output "skills/secondme-skill/generated"The same unpinned command is documented in
README.md, line 34, and is invoked indirectly byscripts/run-gates.sh, line 37.Technical Analysis
The regeneration script invokes
openpersonathroughnpxwithout specifying an exact package version or requiring a previously installed, lockfile-verified executable. If the package is unavailable locally,npxmay resolve, download, and execute package code from the configured npm registry.Consequently, the code executed during regeneration is not necessarily the code that was reviewed with this project. Its behavior can change when a package release, dependency tree, registry response, or local package-resolution environment changes. This creates a supply-chain trust boundary in a workflow that processes persona configuration and may run in a workspace containing private identity data and model artifacts.
No evidence demonstrates that the current
openpersonapackage is malicious. The vulnerability is the mutable and insufficiently verified execution mechanism.Attack Path
- An attacker compromises the
openpersonapackage, one of its transitive dependencies, its publisher account, or the registry resolution path. - The attacker publishes or causes resolution to a modified package version containing hostile lifecycle or runtime code.
- A developer follows the documented command or runs
scripts/run-gates.sh. scripts/regenerate-pack.shexecutesnpx openpersona createwithout an exact version or a no-install restriction.npxdownloads and runs the altered package under the developer's account.- The h ...[truncated 925 chars]
- An attacker compromises the
- Remediation
View remediation
Remediation Suggestions
-
Declare
openpersonaat an exact reviewed version in the project's package manifest; do not use a floating version or range. -
Commit the corresponding lockfile and require reproducible, integrity-checked installation in development and CI.
-
Invoke only the locked local executable, for example:
bash npx --no-install openpersona create \ --config "skills/secondme-skill/persona.json" \ --output "skills/secondme-skill/generated" -
Fail the script if the expected local binary or locked dependency is absent rather than downloading code during a gate run.
-
Use a clean, isolated build environment with minimal filesystem permissions, restricted credentials, and controlled network access.
-
Review and monitor the package's transitive dependency tree, integrity metadata, provenance, and publisher changes.
-
Update
README.mdso the documented command follows the same pinned, offline-safe execution policy.
-
