Safeguard
Security Guides•

Could a vulnerability scanner have caught the xz backdoor?

A scanner matches known advisories, and the xz backdoor had none until it was found. Here is what scanning can and cannot catch, and what helps instead.

Safeguard Security Team
3 min read

No, a conventional vulnerability scanner could not have caught the xz backdoor before it was disclosed. Scanners compare components to published advisories, and there was no advisory for xz 5.6.0 or 5.6.1 until Andres Freund reported the backdoor on 29 March 2024.

What scanners are built to do

Software composition scanners build an inventory of packages and versions, then look each one up in vulnerability databases. A match means someone already described the flaw. This is valuable, because most breaches use old, known issues. It is also a hard limit: an unknown flaw has no entry to match.

What the disclosure says about the xz case

According to the oss-security post, the malicious build script was present in the release tarballs but not in the git source, and the payload was hidden in test files. The backdoor hooked a function in sshd through a library dependency. Nothing in the version string or package metadata marked it as bad.

After disclosure, CVE-2024-3094 was assigned and CISA published an alert advising users to move to an uncompromised version. From that moment, scanners could and did flag the affected versions.

What could have helped earlier

These are general controls, not claims that any one would have stopped this attack.

  • Comparing release tarballs with the git tag they claim to come from, which can reveal files present in one and not the other.
  • Reviewing changes to build scripts and test fixtures, which are often ignored.
  • Behavioural monitoring, such as timing or CPU anomalies on login paths. Freund noticed a delay in SSH logins, roughly 0.30 seconds before and 0.81 seconds after, according to his post.
  • Project health signals such as review requirements and maintainer diversity.

What to ask of your scanner

Scanners remain necessary. Ask them to do what they can do well.

  • Speed: how fast after disclosure does a new advisory reach your results?
  • Coverage: does it include transitive dependencies and container layers?
  • Impact: can it tell you where the affected package runs and whether the vulnerable path is reachable?

Those answers decide whether the first hours after a disclosure are spent finding out or fixing.

Treat scanning as one layer

Pair scanning with build verification, health checks and runtime monitoring. Each covers a gap the others leave.

Safeguard covers the inventory and prioritisation parts of this with SBOM and dependency scanning and reachability analysis, and you can try a free scan at gold.safeguard.sh/scan. Autonomous remediation with fix PRs is off by default, and every category starts on Manual, so a person approves changes.

Quick check

Does a clean scan mean my dependencies were not backdoored?

No. It means they match no known advisory. A new or undisclosed compromise would not appear.

What is the first thing to do after a disclosure like xz?

Find where the package runs, using your inventory, then follow the maintainer and vendor advisories for the fixed version.

Sources

Last reviewed: 19 October 2026.

Never miss an update

Weekly insights on software supply chain security, delivered to your inbox.

Self-healing security runs on Safeguard.

Your first fix PR is minutes away.

No sales call required, even your agent can complete the purchase over MCP.