Skip to content
Supply Chain2024-03-29

xz Utils: A Two-Year Social Engineering Job

A maintainer spent two years earning trust in an open-source project to slip a backdoor into the build process. This wasn't a technical exploit. It was social engineering with a very long fuse.

My take

People keep calling this sophisticated. It's not. It's a person who showed up, contributed code, gained trust, got commit access, and eventually poisoned the supply chain. The scary part isn't the technique. It's that the entire model of open-source trust made it possible. We hand the keys to anyone who sticks around long enough, and nobody has the time or funding to audit every contribution from every maintainer.

Terminal

~/security/notes
# checking xz version on a debian system
$ xz --version
xz (XZ Utils) 5.6.1
liblzma 5.6.1
# 5.6.0 and 5.6.1 contain the backdoor
# check if sshd links against liblzma
$ ldd $(which sshd) | grep lzma
liblzma.so.5 => /lib/x86_64-linux-gnu/liblzma.so.5 (0x00007f1234567000)
# if this returns a match, your sshd is linked to the compromised library
# downgrade immediately: apt install xz-utils=5.4.5-0.3

This was a human problem, not a code problem.

The backdoor wasn't found by a scanner or a CI check. It was found by a developer who noticed sshd was running slower than expected and had the curiosity to dig into why. That's it. One person paying attention. The tooling missed it. The review process missed it. The entire open-source ecosystem missed it for months. Because the attack wasn't technical. It was social.

AI accelerates this pattern.

Now imagine an attacker using AI to generate high-quality contributions across dozens of open-source projects simultaneously. Legitimate-looking code, helpful PR comments, responsive to maintainer feedback. The social engineering playbook scales with AI. And most maintainers are unpaid volunteers who are going to welcome help from anyone willing to do the work.

Takeaway

The supply chain is only as strong as the humans in it. Pin your dependencies. Know who maintains the code you depend on. And stop assuming that 'open source' means 'someone else already reviewed it.' Nobody did.