Skip to content
RCE Advisory Intermediate CVE-2019-5142

Moxa AWK-3131A WAP Hostname Command Injection Vulnerability

The Moxa AWK-3131A wireless access point fails to properly filter the device hostname, allowing an authenticated attacker to inject arbitrary system commands that are executed when the device reboots. This gives the attacker full control of the device.

Jared Rittle Follow

Originally disclosed on Cisco Talos

High 7.2 View original

An exploitable command injection vulnerability exists in the hostname functionality of the Moxa AWK-3131A firmware version 1.13. A specially crafted entry to network configuration information can cause execution of arbitrary system commands, resulting in full control of the device.

Jared Rittle and Alexander Perez Palma, on Cisco Talos

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 report has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely the hostname value is stored in flash and later passed unsanitised to a shell command via iw_system, allowing command injection.

Impact

An authenticated attacker could execute arbitrary system commands, resulting in full control of the device.

What the attacker needed

Authenticated access to web or telnet; device reboot

How it was found

  1. Log in to the device via web or telnet.
  2. Change the Device Name (hostname) to a value containing shell metacharacters.
  3. Reboot the device to save the change to flash.
  4. After reboot, the init process reads the config and calls iw_system, which executes 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 report has not been written yet. The Original tab links to the source.

This is a command injection bug. When you set the device name (hostname) on the access point, the device later uses that name in a system command without cleaning it first. An attacker who can log in can put special characters in the name so that extra commands run, taking over 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 Talos

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.