CVE-2019-16197: Cross-site scripting in Dolibarr
6.1
CVSS Score
3.1
Basic Information
CVE ID
GHSA ID
EPSS Score
0.40686%
CWE
Published
11/8/2019
Updated
1/28/2023
KEV Status
No
Technology
PHP
Technical Details
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
---|---|---|---|
dolibarr/dolibarr | composer | < 10.0.2 | 10.0.2 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability stems from improper input handling in the language detection mechanism. Though the CVE description mentions User-Agent header XSS, the actual patched code shows the vulnerability was in the Accept-Language header processing within Translate::setDefaultLang. The commit adds a critical regex filter (preg_replace('/[^_a-zA-Z]/', '', ...)) to sanitize the input, and the accompanying test case demonstrates XSS prevention by testing malicious header injection. The User-Agent mention in the CVE description appears to be an error, as the code changes and advisory context clearly point to Accept-Language handling in this function as the root cause.