Open
Description
Example this tag was just updated 3 hours back and is potentially exfiltrating credentials
https://github.com/tj-actions/changed-files/tags?after=v35.9.3
You can read more here: https://www.stepsecurity.io/blog/harden-runner-detection-tj-actions-changed-files-action-is-compromised
Activity
tj-actions-bot commentedon Mar 15, 2025
Thanks for reporting this issue, don't forget to star this project if you haven't already to help us reach a wider audience.
salolivares commentedon Mar 15, 2025
Yep... this looks scary: 0e58ed8
edit: https://semgrep.dev/blog/2025/popular-github-action-tj-actionschanged-files-is-compromised/
kbsteere commentedon Mar 15, 2025
@jackton1 for you awareness
ElijahLynn commentedon Mar 15, 2025
It ultimately dumps memory to GHA logs, which can include GHA secrets:
from the malicious commit: 0e58ed8 introduced in:
And if we base64 decode it:
aetzieba commentedon Mar 15, 2025
Is it possible that this fails if bash is not installed?
Leroy231 commentedon Mar 15, 2025
Yes, I started getting this error on my self-hosted Windows runners:
Not sure if GitHub hosted Windows runners have bash installed.
Leroy231 commentedon Mar 15, 2025
@varunsh-coder did you already contact the email address in https://github.com/tj-actions/changed-files/security#public-vulnerability-disclosures?
varunsh-coder commentedon Mar 15, 2025
Yes
aetzieba commentedon Mar 15, 2025
I noticed this in a similar scenario.
AdnaneKhan commentedon Mar 15, 2025
We even see some repositories using the backdoored commit by hash after updates by Renovate: https://github.com/search?q=0e58ed8671d6b60d0890c21b07f8835ace038e67&type=code
ElijahLynn commentedon Mar 15, 2025
I've just confirmed that it is printing double base64 encoded secrets in runner job logs based on your link.
Here is one: https://github.com/szinn/k8s-homelab/actions/runs/13865435819/job/38803427088?pr=5353, double base64 --decode that output and boom, there is a
github_token.ElijahLynn commentedon Mar 15, 2025
Every tag got pointed to this malicious commit:
https://github.com/tj-actions/changed-files/tags
ElijahLynn commentedon Mar 15, 2025
I've just emailed security@github.com too with the title: "Urgent: Hundreds/Thousands of
github_tokensecrets leaked" and linked to this issue. Because some action needs to be taken at the GitHub level to fix this and inform everyone.gaby commentedon Mar 15, 2025
@ElijahLynn I submitted a active malware report too
3 remaining items
gaby commentedon Mar 15, 2025
Makes me wonder if renovate is the one compromised?
themaxdavitt commentedon Mar 15, 2025
I wouldn't jump to that assumption; I thought you could set your Git author name and email to anything you want, e.g.:
Haven't people done this to fake famous developers making commits in their repos?
tdorianh commentedon Mar 15, 2025
@mceachen Re: renovate credentials: likely not. This commit was unsigned, while every other commit by Renovate in this repo is. Looks like a fake.
themaxdavitt commentedon Mar 15, 2025
I think it's unlikely
renovate[bot]was involved at all in committing this attack. Despite 0e58ed8's commit message, it was not actually introduced in #2460. The attacker probably just made their new commit look exactly like the last commit onmain(9200e69) , which was actually byrenovate[bot](check its signature), to not look suspicious.However, unfortunately the real
renovate[bot]is continuing to do what it does best, which is updating people's repos to the latest versions of dependencies... which is why this needs to get resolved ASAP.sarentz-tc commentedon Mar 15, 2025
Is it possible that the memory dumper from https://gist.githubusercontent.com/nikitastupin/30e525b776c409e03c2d6f328f254965/raw/memdump.py does not work in Docker containers?
When I run it in
python:3-bookwormI get the following error:jameswald commentedon Mar 15, 2025
@sarentz-tc It didn't output anything on our self-hosted runners. No error or secrets displayed.
sarentz-tc commentedon Mar 15, 2025
Same. Ours are all in Docker. No VMs. I'm trying to see if that makes a difference. The error that I posted may be because the image I ran was not actually a runner image.
gurchik commentedon Mar 15, 2025
The offending commit 0e58ed8 was never pushed to this repository, as you can see by clicking the link, the commit belongs to a fork of the repository. If the attacker had some way of updating the tags and releases of this repository, then they could have accomplished this attack by:
As the compromised commit was never pushed to the parent repository, it would not show in the Git logs.
Only the owner of this organization has the audit logs necessary to figure out how step 3 was accomplished. I hope a full investigation is done
sarentz-tc commentedon Mar 15, 2025
Confirming that the memdump.py script works inside Docker based GitHub runners.
msheiny commentedon Mar 15, 2025
Wait is that true though? How is that possible to have a tag reference a fork's commit? I see this discussion and they say it's a misleading message but 🤷 https://github.com/orgs/community/discussions/19021 . Anyone know more if thats even possible?