Keeping Up With Security Advisories Without Drowning in Them
Security news about open-source packages arrives constantly, and most of it will not affect you. The goal of this primer is to help you build a small, reliable feed: enough to hear about anything that touches the packages you publish or depend on, without spending your mornings reading every headline about supply-chain attacks.
Two different jobs
As a maintainer you follow security news for two reasons, and they need different sources.
- Your own package as a target or a cause. You need to hear when someone reports a vulnerability in your code, and when your package name is being imitated.
- Your dependencies. You need to hear when something you depend on, directly or transitively, has a published advisory, so you can update and possibly release a patch yourself.
Sources for your own package
Make it easy for people to tell you privately. Add a SECURITY.md to the repository with a contact method, and on GitHub enable private vulnerability reporting so reports arrive as draft advisories rather than public issues. Watch your registry account email: registries contact maintainers about suspected malware, policy changes and account issues through it, and a stale address means you will miss them. Occasionally search the registry for names close to yours.
Sources for your dependencies
Automated alerts do most of the work, as long as you route them somewhere you look:
| Ecosystem | Local check | Automated alerts |
|---|---|---|
| JavaScript | npm audit | Dependabot alerts from the GitHub Advisory Database |
| Python | pip-audit | Dependabot, or scheduled osv-scanner runs |
| Go | govulncheck ./... | Scheduled CI job running govulncheck |
| Rust | cargo audit | Scheduled CI job against the RustSec database |
A weekly scheduled CI job that runs the local check and fails loudly is a good baseline even if you also use a hosted alert service, because it covers ecosystems the service may handle poorly.
Human-written sources worth following
For context beyond individual advisories, follow a few primary sources rather than aggregators: the official blogs and status pages of the registries you publish to, the security announcements of your language runtime (Node.js, Python and Go all publish them), and OpenSSF publications on supply-chain practice. Our own registry policy primer explains the policy side.
Triage in five minutes
- Is the affected version range one you actually resolve? Check your lockfile, not your manifest.
- Is it a runtime dependency or a development tool?
- Does your code reach the vulnerable function? Go's tooling can answer this directly; elsewhere, read the advisory.
- Is a fixed version available within your current major?
- Do you need to release? If your package bundles or pins the vulnerable dependency, users need a new version from you.
More on the databases themselves is in our note on vulnerability data sources.