How I Discovered Command Injection and Soft-Brick Bugs in a $5 Temu Wi-Fi Repeater | Brav

How I Discovered Command Injection and Soft-Brick Bugs in a $5 Temu Wi-Fi Repeater


Table of Contents

TL;DR:

  • Cheap Wi-Fi repeaters can hide command injection, soft-brick, and telnet vulnerabilities.
  • I extracted the firmware, found a vulnerable /protocol.csp endpoint, and exploited NVRAM.
  • I used telnetd to gain root, and demonstrated how to patch.
  • Avoiding such risks means checking for input sanitization and hardening firmware backup.

Why this matters

When I bought a $5 Wi-Fi repeater from Temu, I expected a simple range extender. It originally sold for $30, but on Temu it’s $5—a savings of 84% [Temu Wi-Fi repeater]. Instead, I discovered that cheap embedded devices often lack basic security controls. A single input flaw can let an attacker run commands, reboot the system, or even write to NVRAM and brick the device. This is a common problem for IoT manufacturers and a real threat for homeowners and small businesses.

Core concepts

The repeater runs a Linux-based OS with the Lighttpd web server [Lighttpd] and a custom binary called commuOS that serves the /protocol.csp endpoint. The firmware is packaged as a .bin file containing a SquashFS root filesystem [SquashFS]. I used Ghidra [Ghidra] and binwalk [binwalk] to extract and analyze the firmware. The telnet daemon (telnetd) is present in /usr/sbin and can be invoked on an open port, giving a shell if I can reach the device [Telnet RFC].

VulnerabilityTypical PayloadLikely ImpactMitigation
Command Injection$(id)Root shell or rebootInput sanitization, parameter validation
Soft-brick via NVRAMOverwrite NVRAMDevice fails to bootNVRAM write protection, firmware signing
Telnetd Exposuretelnetd -l 4444Remote shellDisable telnetd, use SSH instead

How to apply it

  1. Identify the device – Scan your network for the repeater’s IP and note the HTTP port (usually 81).
  2. Download the firmware – Most repeaters expose a “firmware backup” link; I used the web interface to download the .bin file [Temu Wi-Fi repeater].
  3. Extract the filesystembinwalk -e firmware.bin pulls out the SquashFS image.
  4. Mount SquashFSunsquashfs -d squashfs-root image.sqfs gives you a writable view of the root.
  5. Analyze commuOS – Open the binary in Ghidra; look for the protocol.csp handler.
  6. Find the injection point – The code concatenates user input into a shell command.
  7. Exploit – Send a crafted Wi-Fi password (or the SSID) that includes a shell metacharacter, e.g. ssid=$(id); the device reboots or runs arbitrary commands. This works because the endpoint is vulnerable to command injection [SSID injection article] and [CVE-2024-57366].
  8. Trigger a soft-brick – Write malicious data to NVRAM; the device refuses to boot until reset. The NVRAM interface is writable [FCC ID 2A2F4-U13].
  9. Enable telnetd – The firmware contains a telnetd binary that can be started on port 4444 [Telnet RFC].
  10. Get a shell – Use nc or telnet to connect to port 4444, then I had full root access.

Pitfalls & edge cases

  • Some firmware versions disable telnetd or move it to a different path.
  • NVRAM writes may be protected by checksum; a brute-force reset button is required.
  • If the firmware is encrypted, binwalk will fail to extract SquashFS.
  • Injecting a command that triggers a reboot may disconnect your network, so use a secondary connection.

Quick FAQ

QuestionAnswer
Can I use this on any Wi-Fi extender?Only if it runs Lighttpd and exposes /protocol.csp.
Is the NVRAM always writable?Many cheap devices allow it; verify with the device’s manual.
What if the firmware is signed?You’ll need to bypass the signature or use a custom firmware image.
How do I prevent command injection?Sanitize all user inputs and enforce length limits.
Is telnetd secure?No, it gives a shell to anyone who can reach the port.
Can I patch the firmware remotely?Not usually; you’ll need to flash a new image.

Conclusion

Cheap Wi-Fi repeaters like the Temu model can expose serious vulnerabilities: command injection, soft-brick via NVRAM, and open telnetd. If you own such a device, back it up, examine the firmware, and patch any input validation holes. If you’re a developer, treat every parameter as untrusted and avoid invoking the shell directly. For enterprises, replace these low-cost gadgets with devices that have proper firmware signing and hardened web interfaces. By staying aware of these risks, you keep your network safe and your data private.

Last updated: March 2, 2026

Recommended Articles

Bottleneck? How I Discovered and Dismantled My PC’s Performance Limits | Brav

Bottleneck? How I Discovered and Dismantled My PC’s Performance Limits

Discover how to spot CPU, GPU, and PCIe bottlenecks, what resolution does, and how to fix them with smart upgrades. Perfect for PC gamers and builders.
Prompt Injection in AI Agents: Why Your Code Bots Are Vulnerable | Brav

Prompt Injection in AI Agents: Why Your Code Bots Are Vulnerable

Prompt injection can hijack AI coding agents, enabling remote code execution and data exfiltration. Learn practical safeguards for CTOs and engineers.