CVE-2021-35401: Unauthenticated Command Injection in Prolink PRC2402M login.cgi
CVE-2021-35401 is an unauthenticated OS command injection vulnerability in the Prolink PRC2402M router, tested on firmware version 20190909. The flaw is in /cgi-bin/login.cgi, specifically the sys_login code path reached when the POST parameter page=login and langChange is not equal to "1". In that path, the application reads the attacker-controlled key parameter from the HTTP request body, concatenates it with the stored Password value from NVRAM, formats a shell command using sprintf with the pattern "echo -n '%s' | md5sum", and executes it via popen. Because the key parameter is not properly validated or sanitized before being embedded in a shell command, an attacker can inject shell metacharacters and execute arbitrary commands. The vulnerable process runs with root privileges on the router.
Impact, mitigation & remediation
What it means and what to do now: patch path, interim mitigations, and the assume-compromise checklist.
Impact
What an attacker gets, and what they’ve been doing with it.
Successful exploitation allows remote unauthenticated attackers to execute arbitrary OS commands as root on the affected router. This can result in full device compromise, including modification of configuration, installation of persistent backdoors, interception or manipulation of network traffic, credential extraction, and use of the router as a pivot point or botnet node.
Mitigation
If you can’t patch tonight, do this now.
Until patched firmware is deployed, restrict or disable WAN access to the router’s web administration interface and limit management access to trusted internal hosts only. Use network ACLs or firewall rules to block external access to /cgi-bin/login.cgi and the administrative HTTP service. Monitor for suspicious POST requests to /cgi-bin/login.cgi containing crafted key values or shell metacharacters. If compromise is suspected, rotate credentials, inspect startup scripts and configuration for persistence, and reflash the device with known-good firmware.
Remediation
Patch, then assume compromise.
Apply the vendor-provided firmware update that fixes CVE-2021-35401. The available context indicates Prolink acknowledged the issue and fixed it on 2021-06-13. Remediation should include eliminating shell invocation on user-controlled data, avoiding popen for this logic, and performing strict server-side validation and safe handling of the key parameter.
Exploits
No public exploits tracked yet. Mallory keeps watching.
References
Frequently asked questions
- Is CVE-2021-35401 exploited in the wild?
- As of Apr 11, 2026, Mallory has no reports of CVE-2021-35401 being exploited in the wild. It is not listed in CISA KEV.
- Is there a public exploit for CVE-2021-35401?
- As of Apr 11, 2026, Mallory has found no public exploit for CVE-2021-35401.
- Is there a patch for CVE-2021-35401?
- Apply the vendor-provided firmware update that fixes CVE-2021-35401. The available context indicates Prolink acknowledged the issue and fixed it on 2021-06-13.
Recent activity
2 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.