Skip to content
RCE Write-up Advanced

Advisory: Cisco RV34X Series – Authentication Bypass and Remote Command Execution

The web management interface of Cisco RV34X routers had an authentication bypass in the /upload endpoint and a command injection in the sessionid cookie. An attacker could chain these to run arbitrary commands without authentication.

T. Shiomitsu Follow

Published on onekey.com

Example H2

T. Shiomitsu, on onekey.com

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely, the nginx authorization check treated any non-empty Authorization header as valid, and the upload.cgi binary passed the sessionid cookie value directly into a shell command without sanitisation.

Impact

An unauthenticated attacker could execute arbitrary commands on the device with the privileges of the www-data user.

What the attacker needed

Network access to the router's web interface

The fix

The issues were fixed in firmware version 1.0.03.21 for RV34X and [redacted] for RV16X/RV26X.

How it was found

  1. Send a request to the /upload endpoint with any non-empty Authorization header to bypass authentication.
  2. Include a crafted sessionid cookie value that contains shell metacharacters.
  3. Set the pathparam parameter to Configuration so the vulnerable code path is reached.
  4. The upload.cgi binary builds a curl command with the cookie value and runs it via popen, executing the injected command.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

A router's web admin page is meant to be protected by a login. Here, a mistake in the login check let anyone skip it, and another mistake let a value from a cookie be used to build a system command. Together, an unauthenticated attacker could run commands on the device.

What is RCE?

Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.

More from Cisco

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Remote code execution

The lesson behind this report.

Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.