Dahua DVR Authentication Bypass - CVE-2013-6117

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Dahua DVR Authentication Bypass - CVE-2013-6117

--Summary--

Dahua web-enabled DVRs and rebranded versions do not enforce authentication on their administrative services.

# Zhejiang Dahua Technology Co., Ltd.
# http://www.dahuasecurity.com

--Affects--

# Dahua web-enabled DVRs
# Dahua-rebranded web-enabled DVRs
# Verified on v2.608.0000.0 and 2.608.GV00.0

--Details--

Dahua web-enabled DVRs utilize fat-client utilities like PSS, mobile client interfaces like iDMSS, and an ActiveX control, "webrec.cab" for browser-based access. These clients communicate with an administrative service which runs on TCP port 37777 by default and can be changed. At least in the case of the ActiveX control, a simple binary protocol is used. The various commands supported by the server are not authorized in any way. Authentication simply serves as a way to let the client transition past the login screen. Various commands can be replayed to any DVR sans authentication. These include:

# Get the firmware version
# Get the serial number
# Get the email settings (includes username, SMTP server, and cleartext creds)
# Get the DDNS settings (includes the DDNS service, server, and cleartext creds)
# Get the NAS settings (again, cleartext creds)
# Get the users (username, group membership, and hashed passwords)
# Get the user groups (group name, description, etc)
# Get the channels (camera channel names, e.g. "bedroom" "cocina")
# Clear the logs (handy)
# Change a user's password (unauthorized access)

More Details: http://blog.depthsecurity.com/2013/11/dahua-dvr-authentication-bypass-cve.html

--MetaSploit Module--

We wrote a MetaSploit scanner module as a proof of concept. It is multithreaded and can look for a specified port, scan networks, find DVRs, get all the above info, change a user's password, and clear the logs when it's through. 

# GIT Repo: https://github.com/depthsecurity/dahua_dvr_auth_bypass.git

--Other Concerns--

# Some nearly simultaneous research independent of mine: http://www.kb.cert.org/vuls/id/800094 
# CVE-2013-3612: DVRs listen for telnet by default and the root password is static and publicly known on all devices. (http://www.cctvforum.com/viewtopic.php?f=3&t=32408) 
# Other backdoor accounts exist, including one with a revolving password that is a simple date hash.
# CVE-2013-3613: UPnP requests from untrusted addresses is supported and could be used to get publicly accessible telnet on a DVR.
# CVE-2013-3614: Passwords are limited to 6 chars.
# CVE-2013-3615: A weak 48-bit hash is utilized to protect DVR account passwords. 
# We admittedly did not perform any serious fuzzing of the vulnerable service so there is a large potential for more serious vulnerabilities that allow RCE. 
# Also, the DVRs listen on many different ports including telnet besides those necessary for web access (TCP/80,37777,&37778 by default). 
# SMTP, NAS, and DDNS credentials were all stored and transferred in cleartext. 

--Mitigation--

The best advice for now is to make sure these devices are not publicly accessible to the internet. Dahua initially stated they would work on fixing the issues but went radio silent afterwards.

--Timeline--

# 8/26/2013: Identified authorization flaw
# 8/27/2013: Wrote proof of concept tool/scanner
# 8/28/2013: Disclosed issue to Dahua
# 8/30/2013: Received initial response from Dahua including request for more info
# 8/30/2013: Responded to Dahua with requested info
# 9/2/2013: Received confirmation that Dahua R&D is working to fix the issue
# 10/2/2013: Requested status update from Dahua
# 10/10/2013: Re-requested status update from Dahua after no response from 10/2/2013
# 11/13/2013: Publicly disclosed vulnerability

Jake Reynolds - Partner / Principal Consultant   






[Index of Archives]     [Linux Security]     [Netfilter]     [PHP]     [Yosemite News]     [Linux Kernel]

  Powered by Linux