CVE-2024-41127 Code injection in monkeytype
Attackers can inject code into a GitHub workflow to gain write access to pull requests in the Monkeytype typing test application.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- A user has to click or open something
- Fix
- None listed
What is CVE-2024-41127?
CVE-2024-41127 is a high-severity code injection vulnerability in monkeytypegame monkeytype, published on 2 Aug 2024. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.
Official description
Monkeytype is a minimalistic and customizable typing test. Monkeytype is vulnerable to Poisoned Pipeline Execution through Code Injection in its ci-failure-comment.yml GitHub Workflow, enabling attackers to gain pull-requests write access. The ci-failure-comment.yml workflow is triggered when the Monkey CI workflow completes. When it runs, it will download an artifact uploaded by the triggering workflow and assign the contents of ./pr_num/pr_num.txt artifact to the steps.pr_num_reader.outputs.content WorkFlow variable. It is not validated that the variable is actually a number and later it is interpolated into a JS script allowing an attacker to change the code to be executed. This issue leads to pull-requests write access. This vulnerability is fixed in 24.30.0.
Which versions are affected by CVE-2024-41127?
It affects 1 product.
Products include Monkeytype Monkeytype.
How do I fix CVE-2024-41127?
No fix has been published for CVE-2024-41127 yet. Limit exposure of the affected software until one is available.
Upgrade, and never evaluate templates, expressions or code built from user input. More about Code injection.
Is CVE-2024-41127 being exploited?
It is not confirmed as exploited in the wild, but public exploit code for CVE-2024-41127 exists.
Public exploit code: 1 proofs of concept on GitHub.
Other vulnerabilities in monkeytypegame monkeytype
Sources
Also known as GHSA-wcjf-5464-4wq9.