Skip to content
Incident response · Template

Poisoned Dependency Lab

A hijacked npm package ran a postinstall script in your CI and sent the job's environment variables to an outside server. Decide which builds are in scope, which secrets to rotate first, what to rebuild and who to tell — then export a scored debrief.

Template & sample only — a structured starting point with sample content, not legal, audit, certification or investment advice.

Template & sample scenario. A fictional rehearsal built on common real-world patterns, not a record of any real organisation, audit or deal. Generated from a PlayCISO template as a starting point: it is not legal, audit, certification, investment or professional advice. Review, adapt and validate it for your organisation before you rely on it.

A popular npm package that Quillstack Software uses deep in its dependency tree was hijacked for six hours. The malicious version ran a postinstall script that sent environment variables to an outside server. Work out which builds ran it, which secrets went with it, what order to rotate them in, which artefacts to rebuild and who to tell — and get a scored debrief.

This is the guided version: a yellow flash shows where to click and a bar says what to do. Switch to Free play any time.

GuidedPress the highlighted Start button. You can edit the names above first, or keep the samples.

Make it yours

Replace the sample names so the scenario and the debrief you export are about your organisation.

Loading…

Sample report · illustrative data

Sample result: Poisoned Dependency Lab debrief

Example run of the rehearsal for an invented software company whose build pipeline pulled a hijacked npm package for six hours; each step is a decision scored out of 10.

Where points were won and lost

StepYour callPointsBest call
The advisoryRemove the package from every repository, starting with direct dependents4 / 10Open an incident, pause release pipelines and find every build that resolved the bad version
Which builds ran it?All jobs that ran install scripts, the build host and the laptops, with the secrets each could read10 / 10Same
Rotation orderOrder by power and reach, fix the trust policy, verify before revoking10 / 10Same
Did the keys reach data?Treat it as a personal data breach and involve counsel and the DPO now10 / 10Same

Score bands

85 and above
Chain broken
65 to 84
Mostly contained
40 to 64
Still exposed
Below 40
Next link in the chain

How the percentage works

The percentage is your points divided by the maximum along the path you took, since some choices branch past later steps. A step's feedback explains why the other options cost points, for example that a quiet version bump leaves already-installed copies running.

Made-up example data. Your own run uses your inputs. Downloads of the full report need Pro.

TL;DR

What this template gives you

4 points
  • A realistic npm supply chain incident: a registry advisory, proxy download logs, a secrets list per job, a cron backdoor on a self-hosted runner and CloudTrail evidence of data access.
  • The story branches: a quiet version bump leads to your own package being published by the attacker; a revoke-everything script causes a self-inflicted outage.
  • Each decision is scored 0–10 with feedback on why, what it costs and what it means for the evidence and the notification clocks.
  • Rename the organisation, your package and CI platform to fit your environment, then export the debrief (Pro).

Frequently asked questions

Is tiny-env-loader a real package?

No. The package, versions, host names and IPs are fictional (hosts use the reserved .example domain and IPs from documentation ranges). The pattern — a hijacked maintainer account publishing a version with a postinstall script that sends environment variables away — has happened many times across package registries.

If we do not depend on the package directly, are we affected?

Possibly. Transitive dependencies install and run their install scripts the same way direct ones do. Check your lockfiles and, better, your registry proxy or CI logs for the bad version during the window it was live.

Which secrets should we rotate first?

The most powerful and most reachable: anything that lets an attacker ship code as you (registry publish tokens, signing keys), then credentials that reach production or customer data, then everything else. Verify each new credential works before you revoke the old one. The Secret Rotation Order Planner builds that order for you.

Is this a finished document I can rely on?

No. Every tool in this suite is a template with sample content. It gives you a structured, editable starting point and generates a document from your own answers, but it is not legal, audit, certification, investment or professional advice. Review and adapt the output, and have it checked by the appropriate specialist before you rely on it.

Who can use it?

The page and sample are public. Customising the template is Pro; a free account gets 3 runs in total, shared across every Pro tool, and the generated document is free to view on the page. Download is Pro: downloading or copying the document (Word, PDF, Markdown, CSV) is never part of the free runs. Pro is $5/month or $40/year. Your work is saved in your own browser.

The tools people use most on PlayCISO.

All tools