GHSA-m2pc-3q4q-w6jr: Malicious File Upload

Published Aug 25, 2026
·
Updated

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:

1. Unrestricted File Upload in Media Sounds Upload API \<= current finding 2. Bluetooth Authentication Bypass 3. 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:

py @router.post("/sounds/upload") async def uploadsound( file: UploadFile = File(...), ) -> dict[str, str]: """Upload a sound file to the daemon's temporary sound directory. The file is saved to /tmp/reachyminisounds/<originalfilename>. 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(statuscode=400, detail="Filename is required") # Reject path traversal filename = Path(file.filename).name if not filename or filename in (".", ".."): raise HTTPException(statuscode=400, detail="Invalid filename") os.makedirs(SOUNDSTMPDIR, existok=True) dest = os.path.join(SOUNDSTMPDIR, 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:

1. No authentication mechanism. 2. No file extension validation. 3. 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

1. Start the daemon in simulation mode (command depends on the installed environment):

shell .venv/bin/mjpython -m reachymini.daemon.app.main --sim --no-media

2. After that check that the media upload API endpoint is activated and you can upload a wav file:

shell curl -X POST http://<daemondomain>:<daemonport>/api/media/sounds/upload \ -F "file=@/path/to/your/file.wav"

3. Now attempt to create a “.sh” file containing a script and upload it:

shell curl -X POST http://<daemondomain>:<daemonport>/api/media/sounds/upload \ -F "file=@/path/to/your/script.sh"

4. 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:

1. Validate that the file extension contains only desired extensions (allow-list approach). 2. Validate that the uploaded file’s content matches the desired extension (Magic numbers, and known file structure per file type). 3. Enforce authentication on the file upload endpoint.

Credit

The vulnerability was discovered by Natan Nehorai of the JFrog Vulnerability Research team.

Affected Software

1 affected componentFixes available
pip/reachy-mini<1.8.2
1.8.2

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade pip/reachy-mini to a version that resolves this vulnerability.

    Fixed in 1.8.2
  2. Configuration

    Enforce authentication on the file upload endpoint (/api/media/sounds/upload) so the handler at src/daemon/app/routers/media.py (upload_sound) is not callable without authentication.

    Reachy Mini daemon (media sounds upload API endpoint /api/media/sounds/upload) authentication_enforced_on_upload_sound = enabled
  3. Configuration

    Validate uploaded filenames using an allow-list approach: reject any file extension that is not one of the desired extensions (the material notes there is no file extension validation today).

    Reachy Mini daemon (media sounds upload API endpoint /api/media/sounds/upload) file_extension_validation = allow-list
  4. Configuration

    Validate uploaded file content matches the desired extension using magic numbers and known file structure for the given file type (the material notes there is currently no file content/size validation).

    Reachy Mini daemon (media sounds upload API endpoint /api/media/sounds/upload) file_content_validation = enforced
  5. Compensating control

    Restrict network exposure of the Reachy Mini daemon. The material states the daemon is bound to 0.0.0.0 and CORS is permissive (allow_origins=['*']); limit binding to required interfaces/addresses and tighten CORS so the upload endpoint is not exposed to every network interface the daemon is connected to.

Event History

Aug 25, 2026
Advisory Published
via GitHub·05:38 PM
Data Sourced
via GitHub·05:38 PM
DescriptionSeverityWeaknessAffected Software

Frequently Asked Questions

1

Does an attacker need credentials or user interaction to use the upload endpoint?

No. The endpoint is exposed without authentication, and the reported attack vector is network-based with no required privileges or user interaction.

2

What can an attacker place on the device?

The endpoint lacks file validation, allowing malicious files to be uploaded to the daemon's filesystem. Uploaded content is saved under /tmp/reachy_mini_sounds using the supplied original filename, and an existing file with the same name is overwritten.

3

Does this issue alone provide root access?

The advisory identifies this as the first step in a compromise chain. Full root access requires the additional Bluetooth authentication-bypass and Bluetooth directory-traversal issues described in that chain.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203