HomePostsHow a single VS Code extension hacked GitHub

How a single VS Code extension hacked GitHub

By tuabuh3 min read1 view
HackingDevOps
Share:
How a single VS Code extension hacked GitHub
GitHub didn't get hacked by a master hacker breaking encryption. It got hacked because an employee installed a single poisoned VS Code extension. That one extension — with over 2 million installs — gave attackers access to tokens, AWS keys and password vaults, letting them pull ∼3,800 internal GitHub repositories. It's a reminder that private code isn't breached, it's handed over by mistake through the tools we trust every day.

It wasn't some Hollywood firewall hack, it was way more mundane.

In mid-May 2026, GitHub got breached. On May 19th, a group calling itself TeamPCP posted on BreachForums claiming roughly 4,000 of GitHub's internal repositories. GitHub confirmed it the next day. About 3,800 internal repos, accessed.

How did they get in? One employee installed one bad extension.

The extension was NX Console. Popular thing, over 2 million installs straight from the official marketplace. For about 18 minutes on May 18th, a compromised version sat live on the store. The attackers had gotten there by first compromising the TanStack open source framework, then abusing a GitHub Actions cache-poisoning trick to push the malicious update.

That was all it took. The moment the employee installed it, the extension had the run of their machine. And this is the blind spot nobody watches. VS Code extensions can read your files, run commands, grab your tokens. This one grabbed the lot: GitHub tokens, NPM tokens, AWS keys, even password vaults.

From that single laptop, the attackers walked sideways into GitHub's own infrastructure and pulled the internal repos out.

Here's the wild part. GitHub says no customer code and no customer data was touched. All of it was internal. TeamPCP (the same crew tied to the Nvidia and Microsoft hits) first tried to sell the haul, then relisted it for $95k on their leak site.

This is the whole lesson, really. Private repos don't get cracked open by defeating encryption. They fall for dumber reasons:

  1. Poisoned dev tools. We install linters, themes, little productivity helpers, and we never check the permissions. One bad update owns everyone running it.
  2. Hardcoded secrets. Those stolen tokens and keys were just sitting in env files and config, right where an extension can read them.
  3. Wide-open access. One compromised employee account reached thousands of repos. It should never have been able to.

Think about why that CISA story blew up the same week. The agency whose entire job is securing the US accidentally shipped a public GitHub repo named "Private-CISA," with AWS GovCloud keys inside. Then took a week to rotate them.

So the fix isn't "be careful." Be careful is not a strategy. Assume breach instead. Allowlist your extensions, so only approved ones can run. Scan for secrets before they ever get committed (GitHub Advanced Security, GitGuardian, and TruffleHog all do this). Sandbox your extensions. And if a key leaks, rotate it right then, not next week.