CVE-2018-16809: Dolibarr SQL injection via the integer parameters qty and value_unit
9.8
CVSS Score
3.0
Basic Information
CVE ID
GHSA ID
EPSS Score
0.71258%
CWE
Published
5/14/2022
Updated
4/24/2024
KEV Status
No
Technology
PHP
Technical Details
CVSS Vector
CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
---|---|---|---|
dolibarr/dolibarr | composer | >= 3.8, <= 7.0.0 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability stems from Dolibarr's use of regex-based blacklist filtering in these functions rather than prepared statements or proper type casting. The advisory explicitly states these functions were intended to protect against SQLi but were bypassed due to: 1) Insufficient regex patterns that could be evaded via parameter splitting 2) Failure to properly handle integer parameters 3) Lack of context-aware escaping. These functions directly process
the qty/value_unit parameters used in the vulnerable UPDATE
query in expensereport/card.php
.