Re:Popular GitHub Action tj-actions/changed-files is comprom...
by mceachen on Friday March 14, 2025 @10:10PM
(#43369310)
GitHub actions supports version numbers, version ranges, and even commit hashes.
[ Parent
| on HN ]
Re:Popular GitHub Action tj-actions/changed-files is comprom...
by frenchtoast8 on Friday March 14, 2025 @10:24PM
(#43369373)
The version numbers aren't immutable, so an attacker can just update the versions to point to the compromised code, which is what happened here. Commit hashes are a great idea, but you still need to be careful: lots of people use bots like Renovate to update your pinned hashes whenever a new version is published, which runs into the same problem.
Re:Popular GitHub Action tj-actions/changed-files is comprom...
by marsovo on Saturday March 15, 2025 @01:09PM
(#43373787)
I don't think that's exactly what happened here: the compromise created new tags but generally the tag consumption relies on semantic versioning
In other words: you specify version 44, the attacker creates 44.1, you're still hosed.
Re:Popular GitHub Action tj-actions/changed-files is comprom...
by BlackFingolfin on Saturday March 15, 2025 @04:15PM
(#43374891)
No you literally can (and the attackers did) change version 44 (the tag for it) to point to a different compromised commmit
Re:Popular GitHub Action tj-actions/changed-files is comprom...
by marsovo on Saturday March 15, 2025 @07:22PM
(#43375837)
Yes, you're right. I wasn't able to double-check as the repo was deleted at the time. That said, AIUI making the tags read-only would still often be vulnerable to semantic-version exploitation.
Re:Popular GitHub Action tj-actions/changed-files is comprom...
by werrett on Friday March 14, 2025 @11:07PM
(#43369595)
Only commit hashes are safe. In this case the bad actor changed all of the version tags to point to their malicious commit.
See https://github.com/tj-actions/changed-files/tags
All the tags point to commit `^0e58ed8` https://github.com/tj-actions/changed-files/commit/0e58ed867...