Incident response
Scenarios: what happens, and what you do
Real incidents walked through step by step.
1. A popular npm package publishes a malicious version
- Automatic: in whitelist mode with pinned ranges, the new version is not covered by any rule and never installs. With cooling off on, it is hidden for the waiting period. With malware scanning, a MALICIOUS verdict rejects it and emails admins. If the attacker replaces a version you already hold, an integrity alert holds it and the original bytes keep being served.
- You: kill the bad versions with a reason that names a safe version. Use who pulled it and Consumers to find affected builds. Raise the registry mode to degraded if the whole ecosystem is under attack.
2. A developer mistypes a package name
- Automatic: in whitelist mode the unknown name is refused as not on the whitelist and a request opens. In blacklist mode the lookalike check warns or blocks.
- You: block the request with a reason naming the real package. Consider Typosquat checks: block.
3. Docker Hub is down
- Automatic: cached layers are served, and tags confirmed in the last 7 days keep working. Uncached layers fail with a 502.
- You: switch to lockdown, or turn off Upstream registry enabled, to serve kept images at any age until Docker Hub is back.
4. A critical CVE is published for a version you allow
- Automatic: the next scan records the finding, npm warns during installs,
npm auditreports it, and downloads are logged. With safe version resolution on, installs move to the newest safe version in range and exact downloads are refused. - You: check Vulnerabilities and Consumers. If teams need time, grant scoped waivers with an end date. For an actively exploited advisory, kill it by advisory id.
5. Someone publishes your internal package name on public npm
- Automatic: if the name is reserved, the public copy is never fetched. Otherwise the public package could be installed.
- You: reserve the scope or prefix now, keep fall back off on internal registries, and search Consumers for the public name.
6. A token leaks in a public repository
- You: revoke it on Tokens, then filter Traffic by its application and look for unfamiliar addresses. Consider the client allow list with Let a valid token through from any network off.