-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA512 Advisory ID: SYSS-2024-021 Product: C-MOR Video Surveillance Manufacturer: za-internet GmbH Affected Version(s): 5.2401, 6.00PL01 Tested Version(s): 5.2401, 6.00PL01 Vulnerability Type: Persistent Cross-Site Scripting (CWE-79) Risk Level: High Solution Status: Open Manufacturer Notification: 2024-04-05 Solution Date: - Public Disclosure: 2024-09-04 CVE Reference: CVE-2024-45177 Authors of Advisory: Chris Beiter, Frederik Beimgraben, and Matthias Deeg ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Overview: The software product C-MOR is an IP video surveillance system. The manufacturer describes the product as follows: "With C-MOR video surveillance, it is possible to check your surveillance over network and the Internet. You can access the live view as well as previous recordings from any PC or mobile device. C-MOR is managed and controlled over the C-MOR web interface. IP settings, camera recording setup, user rights and so on are set over the web without the installation of any software on the client."[1] Due to improper input validation, the C-MOR web interface is vulnerable to persistent cross-site scripting attacks. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Vulnerability Details: By analyzing the C-MOR web interface, it was found that the camera configuration is vulnerable to a persistent cross-site scripting attack due to insufficient user input validation. This kind of attack enables an attacker to persistently store attack vectors in form of arbitrary code, for instance JavaScript code, in the web application database, which may be executed in the context of other users. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Proof of Concept (PoC): An authenticated user can set the location of a camera. If valid JavaScript code is used as location value, this code will be persistently stored in the web application database. The injected JavaScript code is served to users and executed in their web browser's context when using different functionality of the C-MOR web interface, for instance camera settings via "show-movies.plm" or system administration via "systemadministration.plm". The following HTTPS POST request illustrates storing an attack vector via the parameter "location": POST /changelocation.pml HTTP/1.1 Host: Authorization: Basic Content-Type: application/x-www-form-urlencoded Content-Length: 81 location=location%3Cscript%3Ealert%28%22SySS+XSS%21%22%29%3C%2Fscript%3E&cam=cam1 An excerpt of the resulting HTML source code containing the injected JavaScript code is shown below: (...) location
(...) This PoC attack can be performed using the following curl command: curl -X POST -d 'location=location&cam=cam1' --user ":" --insecure --ciphers 'DEFAULT:!DH' https:///changelocation.pml In version 6.00PL01, persistent cross-site scripting vulnerabilties have not been fixed completely. For example, the following attack vector can successfully store attacker-controlled JavaScript code in the logs: curl -X POST \ -d 'cam=