❌

Reading view

There are new articles available, click to refresh the page.

Camera Hacking: Using PwnEye to Compromise IP Cameras

Welcome back, aspiring cyberwarriors.Β 

Some cameras protect a building, others betray it. Camera hacking isn’t hard, and that’s the problem. These devices are often the most vulnerable in any environment. Once installed, they aren’t maintained until there’s a problem. Many β€œproblems” can go unnoticed if you know how vulnerable cameras are. Hackers can use them for persistence or as an entry point into an organization.

We do have different articles on this topic, but this time there’s something else we want to show. It’s PwnEye.Β 

PwnEye

PwnEye is a newer tool that didn’t get enough attention yet. It works with both ONVIF and RTSP and that’s pretty much all you need. Once it has compromised a camera, it can reboot it, factory reset and open an interactive shell via ONVIF.

You also black out the operator’s view. Just like in movies.Β 

Setting Up

Let’s set up the tool. You’ll need ffmpeg first.

kali > sudo apt install ffmpeg
installing ffmpeg

Then install pipx and grab the tool.

kali > sudo apt install pipx 
kali > pipx install git+https://github.com/Hackerest/pwneye.git

Once it’s ready, you can test it:

kali > pwneye -h 
pwneye help menu

The help menu’s large. The tool can be used to find cameras in a local network with –discover, but it can be pointed at any camera IP. That’s where we’ll start.

ONVIF AttacksΒ 

ONVIF is the protocol that lets cameras from different manufacturers talk to each other without buying the same product. It’s basically a standard, but it’s also an attack vector.

kali > pwneye -t IP
onvif - attacking a camera

If the camera’s running default or weak credentials, you get access. The tool extracts everything after compromise. Below you can see the network config, MAC address, DNS entries and configured users. DNS entries may sometimes point to interesting internal servers.

device and network info

Look at the configured user credentials in the output. You’ll use those to get a shell.

The tool also finds snapshots that the camera captures regularly. You can view them in the browser or wait for PwnEye to open the stream.Β 

snapshots and video stream

Some cameras support deface (black the screen), PTZ movement and factory reset through ONVIF. Not all. Depends on the model.

Finally, once it finishes, you get the stream.

live camera feed daytime

Well, it’s just a bus station. Nothing fancy here.

Defacing Cameras

If the camera supports it, you can deface it.

kali > pwneye -t IP --deface [MESSAGE]
defacing a camera

It’s not sophisticated, but it works.Β 

Shell

That’s probably the most interesting part. Take the credentials from the user profile output and get a shell.

kali > pwneye -t IP -ou admin -op β€˜β€™
getting an onvif shell

Once you’re in, run help and see what it has. Some cameras let you do more than others.

running shell commands

RTSP Attacks

ONVIF compromise is worse than RTSP compromise, but RTSP often works when ONVIF doesn’t. The tool tries both by default, but you can skip ONVIF and go straight to RTSP if you want.

kali > pwneye -t IP -so
rstp brutefoce attack

The tool has more than 450 credentials built in. You can also try common corporate passwords like Company123 or just Company.

Once it gets credentials, you get the stream.

live camera feed night

Summary

Some IP cameras might be accessible from the internet and locally. That means compromising them also gives you a foothold on the internal network. They aren’t upgraded regularly and IoT devices in general lack proper software updates. There are dozens of known CVEs on most camera models. Cameras can be used to proxy through them, attack other hosts or maintain persistence.

There are many other attacks on cameras, and it would be a very long article to cover them here. That’s why we created our IP Camera Hacking Training. It’s now part of our Cybersecurity Starter Bundle II. With it you get Wi-Fi Hacking, Python Basics for Hackers, Remaining Anonymous and more.Β 

The post Camera Hacking: Using PwnEye to Compromise IP Cameras first appeared on Hackers Arise.

❌