Threat dossier · P1
Malicious packages and install scripts
Agents can autonomously choose, install, or execute dependencies, turning package selection into an action boundary rather than a purely human review step.
Direct answer
What is malicious packages and install scripts?
A malicious package can execute code during install or runtime, abuse trusted names or publishers, and steal credentials before the application ever imports it.
Coverage statements below are limited to the current HOL Guard support contract and do not imply universal model or harness protection.
Representative attack path
Defensive model only. This sequence omits weaponized payloads and is not attributed to a specific incident unless a source explicitly says so.
Step 1
Malicious or compromised package is selected.
Step 2
Lifecycle/install script or imported code executes.
Step 3
Filesystem, environment, network, or credentials are accessed.
Step 4
Stolen credentials or modified state can propagate the compromise.
Coverage boundary
What this control can cover
- Supported package/artifact inspection and package-manager intent boundaries.
- Runtime policy after installation on supported action surfaces.
What it does not prove or prevent
- Replacement for SCA/dependency vulnerability databases.
- Unsupported package managers or out-of-band install paths.
Policy pattern
Policy pattern for malicious packages and install scripts
Keep untrusted context or overbroad autonomy from becoming unconditional execution authority on supported action surfaces.
Use when: Agents can autonomously choose, install, or execute dependencies, turning package selection into an action boundary rather than a purely human review step.
Decision pattern
- Identify the trust boundary and consequential action class.
- Apply least privilege and the narrowest supported policy.
- Require review for sensitive or ambiguous actions.
- Preserve only redacted, versioned evidence needed to reproduce the decision.
Limitations
- Replacement for SCA/dependency vulnerability databases.
- Unsupported package managers or out-of-band install paths.
If you suspect prompt injection
Step 1
Response 1
Stop installs and pin known-good versions.
Step 2
Response 2
Rotate possibly exposed credentials.
Step 3
Response 3
Remove malicious artifacts and inspect lock/config changes.
Step 4
Response 4
Rescan and retest in isolation.