Summary
CVE-2024-3094 is not a programming mistake. It is a backdoor deliberately planted by someone who spent years earning maintainer trust in the XZ Utils project. The malicious code never appeared in the source repository — it was hidden inside test fixtures shipped in the release tarballs.
During the build, that code was extracted into liblzma, and on systemd-linked sshd processes it hijacked the key verification path through the IFUNC mechanism. The result: whoever held the attacker's private key could bypass authentication entirely.
The backdoor was caught before it reached stable distributions, because one developer went looking for an unexplained few hundred milliseconds of latency in sshd logins.
Advisory details
Root cause: the repository is not the tarball
A project's git repository and its released tarball are not always identical. The attacker modified only build-to-host.m4, a file that exists in the archive, adding a build step that unpacked a malicious object from what looked like binary test data.
This is why “I reviewed the repository and it is clean” is not a sufficient control: trust has to be verifiable all the way down to the build artefact.
Version and binary checks
The first check is trivial — is the installed version in the affected range?
analyst@ubuntu:~$ xz --version && dpkg -l xz-utils | tail -n 1 xz (XZ Utils) 5.6.1 liblzma 5.6.1 ii xz-utils 5.6.1-0.1 amd64 XZ-format compression utilities # 5.6.0 / 5.6.1 = affected range
Figure 1 — Identifying the installed XZ Utils version
The second check looks for the known function signature of the backdoor inside the library itself. On repackaged builds with altered version strings this is the more reliable method.
analyst@ubuntu:~$ hexdump -ve '1/1 "%.2x"' /usr/lib/x86_64-linux-gnu/liblzma.so.5 | grep -c f30f1efa554889f5 1 # 1 = suspicious signature found (a clean system returns 0) # host moved to quarantine
Figure 2 — Searching liblzma for the known backdoor signature
The third check establishes whether sshd actually links against liblzma; without that link the backdoor has no trigger.
analyst@ubuntu:~$ ldd $(which sshd) | grep -i lzma liblzma.so.5 => /lib/x86_64-linux-gnu/liblzma.so.5 (0x00007f2a9c1a0000) # sshd links against liblzma — a triggerable configuration
Figure 3 — Confirming the sshd to liblzma dependency
Rollback and verification
The remediation is to downgrade to a clean version and then treat the host as potentially compromised.
analyst@ubuntu:~$ sudo apt install --allow-downgrades xz-utils=5.4.5-0.3 && sudo systemctl restart ssh && xz --version | head -n 1 Setting up xz-utils (5.4.5-0.3) ... xz (XZ Utils) 5.4.5 # rolled back to a safe version, sshd restarted
Figure 4 — Rolling back to a clean version
A patch is not enough
If the affected version ran on an internet-facing host, downgrading alone does not close the incident: authorised keys, new user accounts, scheduled tasks and outbound connections must be reviewed, and where possible the host should be rebuilt from a known-good image.
Conclusion
The XZ incident showed that in the open source ecosystem the most critical dependency is not code but human trust. On the enterprise side the controls are clear: pin versions in production images, aim for reproducible builds, generate an SBOM, and keep testing channels well away from production.
Sources
Test it in your own environment
We assess your distribution channels and build pipeline against supply chain attacks.