Skip to content
RCE Write-up Advanced

Risk Assessment

A command injection vulnerability in many Hikvision cameras and some NVRs allows an unauthenticated remote attacker to execute arbitrary commands and gain a root shell, bypassing the restricted shell available to the device owner. This gives full control of the device and access to the internal network.

watchfulip.github.io

Published on watchfulip.github.io

The majority of the recent camera product ranges of Hikvision cameras are susceptible to a critical remote unauthenticated code execution vulnerability even with latest firmware (as of 21 June 2021). Some older models are affected also as far back as at least 2016.

The author, on watchfulip.github.io

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 a command injection vulnerability in the web server that fails to properly sanitise user input, allowing arbitrary commands to be executed.

Impact

An unauthenticated attacker could gain a root shell, read and change customer data, render the device inoperable, and attack the internal network; no defence is mentioned as blocking the exploit.

What the attacker needed

Access to the camera's HTTP(S) port; no authentication required

The fix

Hikvision released patched firmware that resolves the vulnerability, and the researcher confirmed the fix works.

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.

This is a flaw in Hikvision cameras that lets anyone on the internet take full control of the camera without needing a password. The attacker can then use the camera to break into the rest of the network. It is very serious because no action from the owner is needed.

What is RCE?

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

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.