Search covers the description text, product and vendor names and weakness types (also partial words).

CVE-2023-31038
apache log4cxx

Score8.8 High
CVSS 3.1
Exploit probability (EPSS)1.5%
within the next 30 days
CategorySQL & query injection
Published8 May 2023
Last modified: 17 June 2026

In short

This vulnerability can be exploited remotely over the network, with a regular user account, without any user interaction.

A successful attack has high impact: reading confidential data, modifying data, crashing the system or making it unavailable.

Weakness type: SQL injection.

✨ AI commentary

After a short ad, a plain-language commentary on this vulnerability is shown. AI can make mistakes; base decisions on the official sources.

Official description

SQL injection in Log4cxx when using the ODBC appender to send log messages to a database.  No fields sent to the database were properly escaped for SQL injection.  This has been the case since at least version 0.9.0(released 2003-08-06) Note that Log4cxx is a C++ framework, so only C++ applications are affected. Before version 1.1.0, the ODBC appender was automatically part of Log4cxx if the library was found when compiling the library.  As of version 1.1.0, this must be both explicitly enabled in order to be compiled in. Three preconditions must be met for this vulnerability to be possible: 1. Log4cxx compiled with ODBC support(before version 1.1.0, this was auto-detected at compile time) 2. ODBCAppender enabled for logging messages to, generally done via a config file 3. User input is logged at some point. If your application does not have user input, it is unlikely to be affected. Users are recommended to upgrade to version 1.1.0 which properly binds the parameters to the SQL statement, or migrate to the new DBAppender class which supports an ODBC connection in addition to other databases. Note that this fix does require a configuration file update, as the old configuration files will not configure properly.  An example is shown below, and more information may be found in the Log4cxx documentation on the ODBCAppender. Example of old configuration snippet: <appender name="SqlODBCAppender" class="ODBCAppender">     <param name="sql" value="INSERT INTO logs (message) VALUES ('%m')" />     ... other params here ... </appender> The migrated configuration snippet with new ColumnMapping parameters: <appender name="SqlODBCAppender" class="ODBCAppender">     <param name="sql" value="INSERT INTO logs (message) VALUES (?)" />     <param name="ColumnMapping" value="message"/>     ... other params here ... </appender>

CVSS: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

Weakness: CWE-89 – SQL injection

Affected products

VendorProductVersions
apachelog4cxx>=0.9.0 <1.1.0

Sources

Latest in the same category

  • CVE-2026-137097 Not scored
    Net::WoRMS versions before 1.901 for Perl allow SQL injection via SOAP response fields in the SQL output of printRecord. Net::WoRMS is a tool for querying the World Register of Marine Species (WoRMS). The SQL output…
    SQL & query injection · 30 November 2026
  • CVE-2026-139990 High 8.7
    GLPI 11.0.0 before 11.0.9 contains an unauthenticated sql injection vulnerability in the planning availability check via the begin and end parameters. Attackers can send genical and checkavailability parameters to…
    SQL & query injection · 30 November 2026
  • CVE-2023-54424 High 8.7
    JIESHUN JieLink+ Intelligent Terminal Operation Platform contains a SQL injection vulnerability that allows unauthenticated attackers to execute arbitrary SQL queries through the deviceId parameter of the…
    SQL & query injection · 30 November 2026
  • CVE-2026-120705 High 8.6KEV
    GeoServer is an open source server that allows users to share and edit geospatial data. Prior to "org.geoserver:gs-wfs-core" versions 2.27.7, 2.28.6, and 3.0.2 and prior to "org.geotools:gt-metadata" versions 33.7,…
    osgeo geoserver · SQL & query injection · 30 November 2026
  • CVE-2026-139882 High 7.1
    OS4ED openSIS Classic through 9.3 contains an sql injection vulnerability in api/StudentEnrollmentInfo.php and api/StaffInfo.php via the unquoted sch_year parameter. Attackers holding any valid API key and secret can…
    SQL & query injection · 30 November 2026
  • CVE-2026-139877 Critical 9.1
    mysql2 before 3.25.0 contains an sql injection vulnerability in Connection.format() and Connection.escape() because quotes are always backslash-escaped regardless of session SQL mode. When NO_BACKSLASH_ESCAPES is…
    SQL & query injection · 30 November 2026