Skip to content
Write-up Intermediate

GitHub Action tj-actions/changed-files supply chain attack: everything you need to know

The widely used GitHub Action tj-actions/changed-files was compromised, causing affected public repositories to leak their secrets in workflow logs. An attacker could obtain credentials such as cloud keys and tokens from those logs.

Merav Bar Follow

Published on wiz.io

The compromised action injected malicious code into any CI workflows using it, dumping the CI runner memory containing the workflow secrets. On public repositories, the secrets would then be visible to everyone as part of the workflow logs, though obfuscated as a double-encoded base64 payload.

Merav Bar, on wiz.io

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely the attacker gained access to a GitHub personal access token used by a bot with write access to the repository, allowing them to modify version tags to point to malicious code.

Impact

Secrets such as cloud access keys and tokens could be exposed in public workflow logs, though no external exfiltration to an attacker-controlled server was observed.

What the attacker needed

Workflow uses tj-actions/changed-files; repository is public for public leak; action not pinned to a safe hash

The fix

The malicious commits were reverted and the gist was deleted, mitigating future exploitation, but users should still rotate leaked secrets and pin actions to commit hashes.

How it was found

  1. Find repositories in your organisation that reference the affected action.
  2. Check workflow runs that used the action during the relevant timeframe.
  3. Look for a double-encoded base64 string in the 'Get changed files' step output.
  4. If found, treat secrets as exposed and rotate them, especially for public repositories.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

A GitHub Action is a reusable piece of automation that runs in a repository's workflow. Here, someone tampered with a popular action so that when it ran, it printed the workflow's secret values (like passwords and keys) into logs that anyone could read for public repositories.

More by Merav Bar

View all

27 more disclosed reports, best first.

Similar reports

Same bug class and techniques, clearest first.