CVE-2024-42468: CometVisu Backend for openHAB has a path traversal vulnerability
5.3
CVSS Score
3.1
Basic Information
CVE ID
GHSA ID
EPSS Score
0.378%
CWE
Published
8/9/2024
Updated
8/12/2024
KEV Status
No
Technology
Java
Technical Details
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N
| Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
|---|---|---|---|
| org.openhab.ui.bundles:org.openhab.ui.cometvisu | maven | <= 4.2.0 | 4.2.1 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability stems from improper path validation in getRequestedFile():
- User-controlled path parameter was URL-decoded and directly used to construct file paths
- Pre-patch code lacked canonical path checks (file.getCanonicalPath().startsWith(...))
- The commit added security checks to prevent directory traversal
- CodeQL's 'Uncontrolled data in path expression' finding matches this pattern
- CWE-22 description aligns with this insecure path handling
- The patch directly modifies this function to add path containment validation