GHSA-fvch-fpgq-pwfx: ProxySQL: Uninitialized heap read in MySQL compressed packet decompression via zlib path
ProxySQL is a proxy for MySQL and its forks, as well as PostgreSQL. Prior to 3.0.10, 3.1.10, and 4.0.10, decompressmysqlpayload() in lib/mysqldatastream.cpp accepts a zlib stream when uncompress() returns ZOK without checking that the actual output length equals the attacker-controlled payloadlength. An authenticated MySQL client that negotiates compression can overstate payloadlength, causing buffer2array() to parse the uninitialized tail of a heap buffer as MySQL packet headers and forward stale data to the backend. Backend error responses can disclose prior SQL queries, result data, credentials, or session state, and malformed lengths can also cause excessive allocations. This issue is fixed in versions 3.0.10, 3.1.10, and 4.0.10.
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
ProxySQLto a version that resolves this vulnerability.Fixed in 3.0.10 - Upgrade
Upgrade
ProxySQLto a version that resolves this vulnerability.Fixed in 3.1.10 - Upgrade
Upgrade
ProxySQLto a version that resolves this vulnerability.Fixed in 4.0.10