Git Product home page Git Product logo

hikvision-password-extractor's Introduction

Hikvision NVR and Camera Password Extraction Tool

Why?

Hikvision refuses to talk to customers directly and will only help you with a forgotten password / password reset on the devices they manufacture if you are an installer or other "professional" - as if it requires some magic knowledge to request a password reset.

After my own experience of using their SADP tool to try and reset my NVR password and then Hikvision responding, "Hikvision CCTV equipment is commercial graded product and should be installed and maintained by a Hikvision recognised partner.

We do not directly support End Users with Technical issues, we support Professional Installation Companies and Distributors only, who then in turn will support their Clients."

Condescending and arrogant tone aside, I was annoyed enough to build a tool to exploit their rubbish coding and extract passwords via any camera connected to an NVR that is running firmware 5.4.0 or lower.

It's my god damn NVR and I paid for it, I'm not going to PAY someone to reset a forgotten password!!!

How?

All device passwords are stored in configuration files that are completely open to download. See:

https://packetstormsecurity.com/files/144097/Hikvision-IP-Camera-Access-Bypass.html

I suggest that once you get access back to your system you ensure that it is not accessible from the internet since this exploit will allow any attacker to take control of your network. It wouldn't take me very long to craft a new firmware that I could then upload to a camera on any network and allow me internal access to that network even through a firewall. Lock your cameras down please... don't trust any device, especially if you buy it from China.

Get the IP address of one of your Hikvision cameras

If you know the IP address of one of your cameras already you can skip this step entirely

Download the SADP tool from Hikvision and run it. You should see your Hikvision devices on your network listed. Make sure you have your computer plugged into the same network as your cameras - if you don't know how to do this, you can ask in various forums for help first.

Once you have the SADP tool up and running, note down the IP of one of the cameras that is running firmware 5.4.0 or lower.

Use the tool

You need Node.js installed to run this... you can get it at https://nodejs.org

Open the terminal app and run:

node index.js <camera ip address>

e.g.

node index.js 192.168.50.100

The tool will connect to the camera and try to download the configuration file. If successful it will then decrypt it, decode (XOR) it and then output any passwords that were found.

You can then try each password it found until you are able to access the NVR or camera whose password you have forgotten.

This password extraction tool is only possible because Hikvision really sucks at security AND customer service. Well done Hikvision, bravo.

Troubleshooting

If your camera is running a later firmware version, simply flash it back to the firmware version that includes this exploit. You can then re-flash it to the latest firmware again once you've reset your password.

hikvision-password-extractor's People

Contributors

irrelon avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

hikvision-password-extractor's Issues

Shell Error: Cannot find module 'request'

Hi @Irrelon

Thanks for the creation of the tool. I am very glad to see I am not the only one beeing incredibly annoyed by HIKVisions customer service...

I am trying to run your script but it always runs into an error:
Error: Cannot find module 'request'
Require stack:

  • S:\DachsClaud\temp\hikvision-password-extractor-master\downloadConfig.js
  • S:\DachsClaud\temp\hikvision-password-extractor-master\index.js
    ←[90m at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15)←[39m
    ←[90m at Function.Module._load (node:internal/modules/cjs/loader:778:27)←[39m
    ←[90m at Module.require (node:internal/modules/cjs/loader:1005:19)←[39m
    ←[90m at require (node:internal/modules/cjs/helpers:102:18)←[39m
    at Object. (S:\DachsClaud\temp\hikvision-password-extractor-master\downloadConfig.js:2:17)
    ←[90m at Module._compile (node:internal/modules/cjs/loader:1101:14)←[39m
    ←[90m at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)←[39m
    ←[90m at Module.load (node:internal/modules/cjs/loader:981:32)←[39m
    ←[90m at Function.Module._load (node:internal/modules/cjs/loader:822:12)←[39m
    ←[90m at Module.require (node:internal/modules/cjs/loader:1005:19)←[39m {
    code: ←[32m'MODULE_NOT_FOUND'←[39m,
    requireStack: [
    ←[32m'S:\DachsClaud\temp\hikvision-password-extractor-master\downloadConfig.js'←[39m,
    ←[32m'S:\DachsClaud\temp\hikvision-password-extractor-master\index.js'←[39m
    ]
    }

Any idea what could cause this?

Thanks,
Fred

Edit: I've installed the current version of node

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.