reachy_mini Allows Unrestricted Upload of File with Dangerous TypeGHSA-m2pc-3q4q-w6jr
MEDIUMFix: pollen-robotics/reachy_mini@984c772GHSA-m2pc-3q4q-w6jr is a medium-severity (CVSS 5.3) Unrestricted File Upload vulnerability in reachy-mini. A fix is available for reachy-mini — see the affected versions and patch details below.
Exploitation Status
No confirmed exploitation observed yet
- CISA assesses this as automatable — exploitation doesn’t require manual, per-target effort, which raises the odds of mass scanning and opportunistic attacks.
- CISA’s own triage has not observed active exploitation or public proof-of-concept code for this CVE as of its last assessment.
Exploitation and automatability from CISA’s SSVC triage for GHSA-m2pc-3q4q-w6jr.
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
GHSA-m2pc-3q4q-w6jr by exploitation likelihood (EPSS) against impact (CVSS). Outside the shaded patch-first corner.
Where this sits among everything scored
Of 385,738 CVEs with a current EPSS score, this one falls in the < 10% band (highlighted). Counts from FIRST.org, log-scaled.
Real-World Exposure
reachy-miniReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects PyPI packages — download data is not available via public APIs for these ecosystems.
Description
Summary
The Reachy Mini daemon exposes the “/api/media/sounds/upload” endpoint without authentication and file validation mechanisms.
An attacker can use this endpoint to upload malicious files into the file system that will propagate in future attacks.
Compromise Chain: Unauthenticated to Full Root Access
This issue is part of a full compromise chain allowing an unauthenticated user to gain root access on the Reachy’s operating system:
- Unrestricted File Upload in Media Sounds Upload API <= current finding
- Bluetooth Authentication Bypass
- Bluetooth Directory Traversal
Description
The root cause of the issue is at the handler located in “src/daemon/app/routers/media.py” file at the “upload_sound” method:
@router.post("/sounds/upload")
async def upload_sound(
file: UploadFile = File(...),
) -> dict[str, str]:
"""Upload a sound file to the daemon's temporary sound directory.
The file is saved to ``/tmp/reachy_mini_sounds/<original_filename>``.
If a file with the same name already exists it is overwritten.
Returns:
JSON with the absolute *path* of the saved file on the daemon.
"""
if not file.filename:
raise HTTPException(status_code=400, detail="Filename is required")
# Reject path traversal
filename = Path(file.filename).name
if not filename or filename in (".", ".."):
raise HTTPException(status_code=400, detail="Invalid filename")
os.makedirs(SOUNDS_TMP_DIR, exist_ok=True)
dest = os.path.join(SOUNDS_TMP_DIR, filename)
content = await file.read()
with open(dest, "wb") as f:
f.write(content)
return {"status": "ok", "path": dest}
This endpoint lacks multiple defence mechanisms:
- No authentication mechanism.
- No file extension validation.
- No file content/size validation.
Additionally, the daemon is bound to the 0.0.0.0 network interfaces (a.k.a. all network interfaces) by default along with permissive CORS ( allow_origins=[“*”] ) meaning the following API endpoint is exposed to every network interface the daemon is connected to.
PoC
- Start the daemon in simulation mode (command depends on the installed environment):
.venv/bin/mjpython -m reachy_mini.daemon.app.main --sim --no-media
- After that check that the media upload API endpoint is activated and you can upload a wav file:
curl -X POST http://<daemon_domain>:<daemon_port>/api/media/sounds/upload \
-F "file=@/path/to/your/file.wav"
- Now attempt to create a “.sh” file containing a script and upload it:
curl -X POST http://<daemon_domain>:<daemon_port>/api/media/sounds/upload \
-F "file=@/path/to/your/script.sh"
- Now error message will be received and you will see that the script file was successfully uploaded to disk.
Impact
Due to this issue, an attacker can upload malicious files instead of the intended sounds files, harming the integrity of the stored data and allowing an attacker to propagate a foothold in cases another vulnerabilities would arise.
Fix suggestion
Perform the following check on the API endpoint:
- Validate that the file extension contains only desired extensions (allow-list approach).
- Validate that the uploaded file’s content matches the desired extension (Magic numbers, and known file structure per file type).
- Enforce authentication on the file upload endpoint.
Credit
The vulnerability was discovered by Natan Nehorai of the JFrog Vulnerability Research team.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 🐍PyPI | reachy-mini | all versions | 1.8.2pip install --upgrade 'reachy-mini==1.8.2' |
Detection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for reachy-mini, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update reachy-mini to 1.8.2 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms GHSA-m2pc-3q4q-w6jr is resolved across your whole dependency graph.
Workarounds
Treat uploaded files as untrusted until proven otherwise: validate the actual content type rather than the supplied extension, store uploads outside the web root on a volume mounted without execute permission, and rename them to server-generated identifiers so an attacker cannot choose the path a request will later resolve.
Frequently Asked Questions
Is GHSA-m2pc-3q4q-w6jr in your dependencies?
Find it across PyPI, including transitive dependencies.