Skip to content
Noroxi
CVE-2022-23305· NVD / CVE Program· CNA apache

SQL injection in JDBC Appender in Apache Log4j V1

By design, the JDBCAppender in Log4j 1.2.x accepts an SQL statement as a configuration parameter where the values to be inserted are converters from PatternLayout. The message converter, %m, is likely to always be included. This allows attackers to manipulate the SQL by entering crafted strings into input fields or headers of an application that are logged allowing unintended SQL queries to be executed. Note this issue only affects Log4j 1.x when specifically configured to use the JDBCAppender, which is not the default. Beginning in version 2.0-beta8, the JDBCAppender was re-introduced with proper support for parameterized SQL queries and further customization over the columns written to in logs. Apache Log4j 1.2 reached end of life in August 2015. Users should upgrade to Log4j 2 as it addresses numerous other issues from the previous versions.

CriticalCVSS 9.8 · v3.1—Proof of concept Fix available
Published
Jan 18, 2022
Updated
Jun 17, 2026
EPSS
66.5% · 99th percentile
Follow this CVE

Sign in to follow · You’ll be notified if a followed record enters KEV, gets an exploit or is updated.

Report tools

JSON

Action score

59

Plan

Add it to your regular patch cycle.

CVSS
39 / 40 · 9.8 / 10
CISA KEV
0 / 30 · Not listed
EPSS
20 / 30 · 66.5%

CISA SSVC decision

Exploitation
none
Automatable
yes
Technical impact
total

Vulnrichment: CISA's decision-tree inputs.

Affected systems

VendorProduct
apachelog4j
netappsnapmanager
broadcombrocade sannav
qosreload4j
oracleadvanced supply chain planning
oraclebusiness intelligence
oraclebusiness process management suite
oraclecommunications eagle ftp table base retrieval
oraclecommunications instant messaging server
oraclecommunications messaging server
oraclecommunications network integrity
oraclecommunications offline mediation controller

and 16 more

Affected versions

NVD version ranges (for catalog products). Add the product to your stack with a version and matching uses these.

  • apache log4j1.2 and later · up to 1.2.17 inclusive
  • broadcom brocade sannavall versions
  • netapp snapmanagerall versions
  • oracle advanced supply chain planning12.1
  • oracle advanced supply chain planning12.2
  • oracle business intelligence12.2.1.3.0
  • oracle business intelligence12.2.1.4.0
  • oracle business intelligence5.9.0.0.0
  • oracle business process management suite12.2.1.3.0
  • oracle business process management suite12.2.1.4.0
  • oracle communications eagle ftp table base retrieval4.5
  • oracle communications instant messaging server10.0.1.5.0
  • oracle communications messaging server8.1
  • oracle communications network integrity7.3.6
  • oracle communications offline mediation controllerbefore 12.0.0.4.4
  • oracle communications offline mediation controller12.0.0.5.0
  • oracle communications unified inventory management7.4.1
  • oracle communications unified inventory management7.4.2
  • oracle e-business suite cloud manager and cloud backup modulebefore 2.2.1.1.1
  • oracle e-business suite cloud manager and cloud backup module2.2.1.1.1

Versions reported by the vendor

Affected version ranges reported by the assigning authority (apache). Independent of NVD's CPE analysis and usually ahead of it.

  • Apache Software Foundation Apache Log4j 1.x

    • 1.2.1 and later · before unspecifiedaffected
    • unspecified and later · before 2.0-alpha1affected

Package-level exposure

OSV and GitHub Advisory data: ecosystem, package and range. SBOM matching uses this table.

EcosystemPackageAffected rangeFix
AlmaLinux:8parfaitbefore 0.5.4-4.module_el8.5.0+2610+de2b8c0b0.5.4-4.module_el8.5.0+2610+de2b8c0b
AlmaLinux:8parfaitbefore 0.5.4-4.module_el8.5.0+235+62ea77380.5.4-4.module_el8.5.0+235+62ea7738
AlmaLinux:8parfait-examplesbefore 0.5.4-4.module_el8.5.0+235+62ea77380.5.4-4.module_el8.5.0+235+62ea7738
AlmaLinux:8parfait-examplesbefore 0.5.4-4.module_el8.5.0+2610+de2b8c0b0.5.4-4.module_el8.5.0+2610+de2b8c0b
AlmaLinux:8parfait-javadocbefore 0.5.4-4.module_el8.5.0+2610+de2b8c0b0.5.4-4.module_el8.5.0+2610+de2b8c0b
AlmaLinux:8parfait-javadocbefore 0.5.4-4.module_el8.5.0+235+62ea77380.5.4-4.module_el8.5.0+235+62ea7738
AlmaLinux:8pcp-parfait-agentbefore 0.5.4-4.module_el8.5.0+235+62ea77380.5.4-4.module_el8.5.0+235+62ea7738
AlmaLinux:8pcp-parfait-agentbefore 0.5.4-4.module_el8.5.0+2610+de2b8c0b0.5.4-4.module_el8.5.0+2610+de2b8c0b
AlmaLinux:8si-unitsbefore 0.6.5-2.module_el8.5.0+235+62ea77380.6.5-2.module_el8.5.0+235+62ea7738
AlmaLinux:8si-unitsbefore 0.6.5-2.module_el8.5.0+2610+de2b8c0b0.6.5-2.module_el8.5.0+2610+de2b8c0b
AlmaLinux:8si-units-javadocbefore 0.6.5-2.module_el8.5.0+235+62ea77380.6.5-2.module_el8.5.0+235+62ea7738
AlmaLinux:8si-units-javadocbefore 0.6.5-2.module_el8.5.0+2610+de2b8c0b0.6.5-2.module_el8.5.0+2610+de2b8c0b
AlmaLinux:8unit-apibefore 1.0-5.module_el8.5.0+235+62ea77381.0-5.module_el8.5.0+235+62ea7738
AlmaLinux:8unit-apibefore 1.0-5.module_el8.5.0+2610+de2b8c0b1.0-5.module_el8.5.0+2610+de2b8c0b
AlmaLinux:8unit-api-javadocbefore 1.0-5.module_el8.5.0+2610+de2b8c0b1.0-5.module_el8.5.0+2610+de2b8c0b
AlmaLinux:8unit-api-javadocbefore 1.0-5.module_el8.5.0+235+62ea77381.0-5.module_el8.5.0+235+62ea7738
AlmaLinux:8uom-libbefore 1.0.1-6.module_el8.5.0+2610+de2b8c0b1.0.1-6.module_el8.5.0+2610+de2b8c0b
AlmaLinux:8uom-libbefore 1.0.1-6.module_el8.5.0+235+62ea77381.0.1-6.module_el8.5.0+235+62ea7738
AlmaLinux:8uom-lib-javadocbefore 1.0.1-6.module_el8.5.0+235+62ea77381.0.1-6.module_el8.5.0+235+62ea7738
AlmaLinux:8uom-lib-javadocbefore 1.0.1-6.module_el8.5.0+2610+de2b8c0b1.0.1-6.module_el8.5.0+2610+de2b8c0b
AlmaLinux:8uom-parentbefore 1.0.3-3.module_el8.5.0+2610+de2b8c0b1.0.3-3.module_el8.5.0+2610+de2b8c0b
AlmaLinux:8uom-parentbefore 1.0.3-3.module_el8.5.0+235+62ea77381.0.3-3.module_el8.5.0+235+62ea7738
AlmaLinux:8uom-sebefore 1.0.4-3.module_el8.5.0+2610+de2b8c0b1.0.4-3.module_el8.5.0+2610+de2b8c0b
AlmaLinux:8uom-sebefore 1.0.4-3.module_el8.5.0+235+62ea77381.0.4-3.module_el8.5.0+235+62ea7738

+96

Other highest-scoring records for the same primary product.

  • CVE-2021-44228Apache Log4j2 JNDI features do not protect against attacker controlled LDAP and other JNDI related endpointsKEV
    100Now
  • CVE-2021-45046Apache Log4j2 Thread Context Message Pattern and Context Lookup Pattern vulnerable to a denial of service attackKEV
    96Now
  • CVE-2017-5645In Apache Log4j 2.x before 2.8.2, when using the TCP socket server or UDP socket server to receive serialized log events from another applic
    66This week
  • CVE-2019-17571Included in Log4j 1.2 is a SocketServer class that is vulnerable to deserialization of untrusted data which can be exploited to remotely exe
    60This week
  • CVE-2021-44832Apache Log4j2 vulnerable to RCE via JDBC Appender when attacker controls configuration
    55Plan
  • CVE-2022-23302Deserialization of untrusted data in JMSSink in Apache Log4j 1.x
    54Plan

Remediation

Which version to upgrade to

Fix versions compiled from the vendor, package registries and Microsoft. Verify the vendor's note before upgrading.

Product / packageFixed versionSource
AlmaLinux:parfait0.5.4-4.module_el8.5.0+235+62ea7738 · AlmaLinux:8Package registry (OSV)
AlmaLinux:parfait-examples0.5.4-4.module_el8.5.0+2610+de2b8c0b · AlmaLinux:8Package registry (OSV)
AlmaLinux:parfait-javadoc0.5.4-4.module_el8.5.0+235+62ea7738 · AlmaLinux:8Package registry (OSV)
AlmaLinux:pcp-parfait-agent0.5.4-4.module_el8.5.0+2610+de2b8c0b · AlmaLinux:8Package registry (OSV)
AlmaLinux:si-units0.6.5-2.module_el8.5.0+235+62ea7738 · AlmaLinux:8Package registry (OSV)
AlmaLinux:si-units-javadoc0.6.5-2.module_el8.5.0+2610+de2b8c0b · AlmaLinux:8Package registry (OSV)
AlmaLinux:unit-api1.0-5.module_el8.5.0+2610+de2b8c0b · AlmaLinux:8Package registry (OSV)
AlmaLinux:unit-api-javadoc1.0-5.module_el8.5.0+2610+de2b8c0b · AlmaLinux:8Package registry (OSV)
AlmaLinux:uom-lib1.0.1-6.module_el8.5.0+2610+de2b8c0b · AlmaLinux:8Package registry (OSV)
AlmaLinux:uom-lib-javadoc1.0.1-6.module_el8.5.0+2610+de2b8c0b · AlmaLinux:8Package registry (OSV)
AlmaLinux:uom-parent1.0.3-3.module_el8.5.0+235+62ea7738 · AlmaLinux:8Package registry (OSV)
AlmaLinux:uom-se1.0.4-3.module_el8.5.0+235+62ea7738 · AlmaLinux:8Package registry (OSV)
Debian:apache-log4j1.21.2.17-11 · Debian:12Package registry (OSV)
openSUSE:kafka2.1.0-bp153.2.6.1 · openSUSE:Leap 15.3Package registry (OSV)
openSUSE:kafka-kit2.1.0-bp153.2.6.1 · openSUSE:Leap 15.3Package registry (OSV)
openSUSE:log4j1.2.17-5.9.1 · openSUSE:Leap 15.3Package registry (OSV)
openSUSE:log4j121.2.17-4.9.1 · openSUSE:Leap 15.3Package registry (OSV)
Red Hat:parfait0:0.5.4-4.module+el8.4.0+13998+1b70e2b7 · Red Hat:rhel_eus:8.4::appstreamPackage registry (OSV)
Red Hat:parfait-examples0:0.5.4-4.module+el8.4.0+13998+1b70e2b7 · Red Hat:rhel_eus:8.4::appstreamPackage registry (OSV)
Red Hat:parfait-javadoc0:0.5.4-4.module+el8.4.0+13998+1b70e2b7 · Red Hat:rhel_eus:8.4::appstreamPackage registry (OSV)
Red Hat:pcp-parfait-agent0:0.5.4-4.module+el8.4.0+13998+1b70e2b7 · Red Hat:rhel_eus:8.4::appstreamPackage registry (OSV)
Red Hat:si-units0:0.6.5-2.module+el8+2463+615f6896 · Red Hat:rhel_eus:8.4::appstreamPackage registry (OSV)
Red Hat:si-units-javadoc0:0.6.5-2.module+el8+2463+615f6896 · Red Hat:rhel_eus:8.4::appstreamPackage registry (OSV)
Red Hat:unit-api0:1.0-5.module+el8+2463+615f6896 · Red Hat:rhel_eus:8.4::appstreamPackage registry (OSV)
Red Hat:unit-api-javadoc0:1.0-5.module+el8+2463+615f6896 · Red Hat:rhel_eus:8.4::appstreamPackage registry (OSV)
Red Hat:uom-lib0:1.0.1-6.module+el8+2463+615f6896 · Red Hat:rhel_eus:8.4::appstreamPackage registry (OSV)
Red Hat:uom-lib-javadoc0:1.0.1-6.module+el8+2463+615f6896 · Red Hat:rhel_eus:8.4::appstreamPackage registry (OSV)
Red Hat:uom-parent0:1.0.3-3.module+el8+2463+615f6896 · Red Hat:rhel_eus:8.4::appstreamPackage registry (OSV)
Red Hat:uom-se0:1.0.4-3.module+el8+2463+615f6896 · Red Hat:rhel_eus:8.4::appstreamPackage registry (OSV)
Rocky Linux:parfait0:0.5.4-4.module+el8.5.0+728+553fbdb8 · Rocky Linux:8Package registry (OSV)

+20

Exploit status

Proof of concept available

A public proof of concept or detection signature exists. Exploit knowledge is out there; don't delay patching.

Evidence

  • Proof-of-concept repository on GitHub ×3

Noroxi does not host or link to exploit code. Metasploit module names and Nuclei template ids are shown (names, not code); Exploit-DB entries and PoC repositories are given as counts only.

Public exploit evidence
SourceKindDate
Proof-of-concept repository on GitHubstars:392021-12-14
Proof-of-concept repository on GitHubstars:52022-01-21
Proof-of-concept repository on GitHubstars:12023-07-24

Research context

For pentesters and researchers: attack profile, score disagreement, timeline, patch commits, credits, variant and chain candidates, bug bounty scope. All derived from existing data; no exploit code.

Timeline

From publication to today: proof of concept, Metasploit module, CISA KEV and fix record. Dates are as reported by the sources.

  1. First PoC-36 d
  2. Published
  3. TodaySep 29, 2026+1715 d
EPSS, last 120 days

FIRST EPSS daily score; only changes of 0.01 or more are recorded (step chart).

Patch and commit links

Commit, PR and diff links among the references. A starting point for patch-diffing and variant hunting; fixes, not exploits.

No commit or PR link among the references.

Finders, reporters and analysts named in the CNA record. Click a name for that researcher’s other records.

Variant candidates

Same product, same weakness class, within 18 months. If the patch missed the root cause, the sibling bug is here.

No nightly-computed relations.

Chain candidates

An authentication bypass and a privilege-requiring bug in the same product, published close together: combined they may become an unauthenticated path.

—

Bug bounty scope

No known public program.

Source: bounty-targets-data (public HackerOne, Bugcrowd, Intigriti, YesWeHack listings).

Technical details

Attack conditions

  • Anyone who can reach it over the internet can trigger it.
  • No account or password is required.
  • No user action is required.
  • No special conditions are required; it is repeatable.

If successful

Confidentiality
high · data can be read
Integrity
high · data or configuration can be modified
Availability
high · the service can be disrupted
Attack vector
Network
Attack complexity
Low
Privileges required
None
User interaction
None
Scope
Unchanged
Confidentiality impact
High
Integrity impact
High
Availability impact
High

CVSS vector

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

nvd-primary

Root cause

The query text is built by concatenating user input. The database cannot tell where the data ends and the command begins.

A representative example of this vulnerability class. Not the vendor's source code; it shows the faulty pattern and its fix.

Vulnerable

ts
const owner = req.query.owner;const rows = await db.query(  "SELECT * FROM files WHERE owner = '" + owner + "'");

Fixed

ts
const owner = req.query.owner;const rows = await db.query(  "SELECT * FROM files WHERE owner = $1",  [owner]);

Noroxi analysis

No Noroxi analysis for this record yet

We don't hand-write analysis for all 385,000+ vulnerabilities; that wouldn't be honest. For notable, high-impact vulnerabilities our team writes the mechanism, detection and remediation steps.

We use this product, ask for help

Change log

  1. Fix✗ → ✓

For records you follow, these changes also arrive as notifications. →

References

All records