T08 · Insecure Dependencies
- Location
SKILL.md:65- Finding
Runtime Execution of an Unpinned Marp CLI Dependency
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 65–72
Vulnerability Type: Unpinned third-party package execution
Risk Level: MediumVulnerable Code
bash # Convert to PDF npx @marp-team/marp-cli@latest presentation.md --pdf -o out.pdf # Convert to PowerPoint npx @marp-team/marp-cli@latest presentation.md --pptx -o out.pptx # Convert to HTML npx @marp-team/marp-cli@latest presentation.md -o out.htmlTechnical Analysis
The documented compilation workflow instructs the agent to execute
@marp-team/marp-cli@latestthroughnpx. Thelatesttag is mutable and does not identify a specific, previously reviewed package version. If the package, its publishing account, or an upstream dependency is compromised, subsequent skill executions can retrieve and run different code without any change to this audited project.npxmay download the selected package and execute its entry point and package lifecycle behavior locally. Consequently, this is a third-party supply-chain execution boundary rather than a reproducible local build process.Attack Path
- An attacker compromises the package publisher, registry account, release pipeline, or a relevant upstream dependency.
- The attacker publishes a malicious release and causes the mutable
latesttag to resolve to it. - A user or agent follows the compilation instructions in
SKILL.md. npxretrieves the currently tagged package from the registry.- The downloaded package executes under the privileges of the user or agent running the skill.
- Malicious package code can access resources available to that process, including presentation files, other readable local files, environment variables, and permitted network services.
Impact Assessment
Successful exploitation can result in arbitrary code execution with the privileges of the invoking user or agent. The practical scope may include reading or modifying files acc ...[truncated 260 chars]
- Remediation
View remediation
Remediation Suggestions
- Replace
@latestwith an exact, reviewed Marp CLI version. - Declare the dependency in a package manifest and commit a lockfile so all transitive versions are reproducible.
- Install dependencies in a controlled installation step and invoke the locally installed binary rather than allowing ad hoc runtime resolution.
- Enforce package integrity verification through the lockfile and trusted-registry configuration.
- Review dependency updates before changing the pinned version, preferably using automated supply-chain scanning.
- Run presentation compilation in a sandbox with minimum filesystem access, restricted network connectivity, and no unnecessary credentials in the environment.
Example hardened workflow:
bash npm ci --ignore-scripts npx --no-install marp presentation.md --pdf -o out.pdf npx --no-install marp presentation.md --pptx -o out.pptx npx --no-install marp presentation.md -o out.htmlThe exact reviewed version of
@marp-team/marp-clishould be declared inpackage.jsonand resolved by a committed lockfile.- Replace
