GHSL-2024-052: Actions expression injection in an Actions workflow of AsyncAPI
An AsyncAPI organization-wide GitHub Actions workflow injects user-controlled data from issue, pull request, discussion, and comment titles and URLs directly into a script, allowing an attacker to execute arbitrary commands on the runner. This could lead to stealing workflow secrets and modifying the repository.
An AsyncAPI organization-wide workflow is vulnerable to Actions expression injection allowing an attacker to take over the repositories and steal secrets.
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 report has not been written yet. The Original tab links to the source.
How it worked
Root cause
The workflow uses GitHub Actions expression syntax to insert untrusted event data (such as issue titles and URLs) directly into a script, without sanitisation, enabling expression injection.
Impact
This issue may lead to stealing workflow secrets and modification of the repository.
What the attacker needed
Ability to trigger workflow via issue/comment/etc.
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 report has not been written yet. The Original tab links to the source.
GitHub Actions workflows can run scripts automatically when events like comments or issues happen. If the workflow puts text from those events directly into a script without cleaning it, an attacker can include special characters that make the script run their own commands. This report shows that mistake in an AsyncAPI workflow, which could let an attacker take control of the runner and access secrets.
What is RCE?
Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.