CVE-2026-50629
Apache CXF vulnerability analysis and mitigation

Overview

CVE-2026-50629 is a log injection vulnerability in Apache CXF's OAuth2 server component, classified as "Apache CXF: OAuth2: Log Injection via Unsanitized Client Identifier." The clientId parameter from incoming HTTP requests is directly concatenated into OAuth2 server log warning messages without sanitizing control characters, enabling attackers to inject arbitrary content — including fake log entries — into server log files. Affected versions include Apache CXF (org.apache.cxf:cxf-rt-rs-security-oauth2) before 4.1.7 and 4.2.0 before 4.2.2. The vulnerability was disclosed on June 11, 2026, and carries a CVSS v3.1 base score of 5.3 (Medium) per NVD, though the GitHub Advisory Database assigns a score of 8.2 (High) (Apache Advisory, GitHub Advisory, Openwall OSS-Sec).

Technical details

The root cause is CWE-93 (Improper Neutralization of CRLF Sequences / CRLF Injection): the clientId value supplied in HTTP requests is concatenated directly into log warning messages in the OAuth2 server without stripping or escaping control characters such as carriage return (\r) and line feed (\n). An unauthenticated, network-accessible attacker can craft a malicious clientId value containing CRLF sequences to break log line boundaries and insert arbitrary fake log entries, potentially masking malicious activity or framing legitimate users. No authentication or user interaction is required, and attack complexity is low. The vulnerability was reported by Guanping Zhang (Openwall OSS-Sec, GitHub Advisory).

Impact

Successful exploitation allows an unauthenticated attacker to tamper with the integrity of OAuth2 server audit and application logs by injecting arbitrary content, including fabricated log entries. This can undermine forensic investigations, obscure evidence of malicious activity, and potentially mislead security operations teams. There is no direct impact on confidentiality or availability; the primary risk is integrity loss of log data, which can have downstream compliance and incident response consequences (Apache Advisory, GitHub Advisory).

Exploitation steps

  1. Identify target: Locate an internet-facing Apache CXF instance running the OAuth2 server component (org.apache.cxf:cxf-rt-rs-security-oauth2) at a version before 4.1.7 or between 4.2.0 and 4.2.2.
  2. Craft malicious clientId: Construct an HTTP request to the OAuth2 endpoint (e.g., token endpoint) with a clientId parameter containing CRLF sequences and arbitrary log content, such as: clientId=legitimate_client%0d%0a[FAKE LOG ENTRY] Admin login successful from 192.168.1.1.
  3. Send the request: Submit the crafted request to the OAuth2 server (e.g., via curl or a custom script). No authentication is required.
  4. Observe log injection: The server writes the unsanitized clientId value into its log file, inserting the fake log entry as a new line, potentially masking attacker activity or injecting misleading audit records (Openwall OSS-Sec, GitHub Advisory).

Indicators of compromise

  • Logs: Apache CXF OAuth2 server log files containing unexpected line breaks, unusual formatting, or entries with forged timestamps, IP addresses, or user identifiers that do not correspond to actual system events; log lines containing URL-encoded CRLF sequences (%0d%0a, %0a, %0d) in the clientId field.
  • Network: HTTP requests to OAuth2 token or authorization endpoints with clientId parameter values containing encoded newline characters (\r\n, \n) or other control characters.
  • Application: Anomalous or duplicate log entries in cxf.log or equivalent application log files that appear structurally inconsistent with surrounding entries.

Mitigation and workarounds

Apache has released patched versions that sanitize the clientId parameter before logging: upgrade to Apache CXF 4.1.7 (for the pre-4.2.x branch) or Apache CXF 4.2.2 (for the 4.2.x branch). As a complementary measure, implement input validation and sanitization for the clientId parameter to remove or escape control characters before any logging occurs. Organizations should also review existing log files for anomalous entries that may indicate prior exploitation attempts (Apache Advisory, Openwall OSS-Sec).

Community reactions

The vulnerability was disclosed by Apache CXF committer Colm O hEigeartaigh via the oss-security mailing list on June 11, 2026, crediting Guanping Zhang as the finder (Openwall OSS-Sec). Community reaction has been limited, consistent with the low-to-medium severity rating and absence of active exploitation. The advisory was noted on Bluesky's infosec community feed shortly after disclosure (Apache Advisory).

Additional resources


SourceThis report was generated using AI

Related Apache CXF vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2026-50633HIGH8.1
  • Apache CXF logoApache CXF
  • cpe:2.3:a:apache:cxf
NoYesJun 12, 2026
CVE-2026-50632HIGH8.1
  • Apache CXF logoApache CXF
  • cpe:2.3:a:apache:cxf
NoYesJun 12, 2026
CVE-2026-50645HIGH7.5
  • Apache CXF logoApache CXF
  • cpe:2.3:a:apache:cxf
NoYesJun 12, 2026
CVE-2026-50631HIGH7.4
  • Apache CXF logoApache CXF
  • cpe:2.3:a:apache:cxf
NoYesJun 12, 2026
CVE-2026-50634MEDIUM6.5
  • Apache CXF logoApache CXF
  • cpe:2.3:a:apache:cxf
NoYesJun 12, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management