CVE-2026-6722: Use-After-Free in SOAP using Apache map
In PHP versions 8.2.* before 8.2.31, 8.3.* before 8.3.31, 8.4.* before 8.4.21, and 8.5.* before 8.5.6, the SOAP extension's object deduplication mechanism stores pointers to PHP objects in a global map without incrementing their reference counts. When an apache:Map node contains duplicate keys, processing the second entry overwrites the first in the temporary result map, freeing the original PHP object while its stale pointer remains in the map. A subsequent href reference to the freed node can copy the dangling pointer into the result. As PHP string allocations can reclaim the freed memory region, an attacker with control over the SOAP request body can exploit this use-after-free to achieve remote code execution.
Security readout for executives and security teams
Plain-English summary
A remote attacker may take control of a vulnerable PHP application if it processes attacker-controlled SOAP messages containing a specially structured Apache Map. The flaw can corrupt memory and potentially execute code without authentication or user interaction. Exposure depends on whether the PHP SOAP extension is enabled and reachable by untrusted clients.
Executive priority
Treat as an urgent, exposure-driven remediation. Patch reachable SOAP services first because successful exploitation could compromise confidentiality, integrity, and availability. Rapidly inventory affected PHP runtimes before assuming broad exposure; the attack requires specific SOAP processing conditions and active exploitation is not established by the supplied evidence.
Technical view
PHP SOAP object deduplication retains uncounted object pointers in a global map. Duplicate Apache Map keys can free an object while leaving a stale pointer. A later href reference may reuse that dangling pointer after memory reclamation, producing a use-after-free with potential remote code execution.
Likely exposure
Affected deployments run PHP 8.2 before 8.2.31, 8.3 before 8.3.31, 8.4 before 8.4.21, or 8.5 before 8.5.6, with the SOAP extension processing attacker-controlled request bodies. Systems without enabled or reachable SOAP handling are less likely exposed.
Exploitation context
The supplied CVSS 4.0 score is 9.5. Network exploitation requires no privileges or user interaction, but attack complexity is high and additional prerequisites apply. The bundle marks KEV false and provides no evidence of active exploitation or a public exploit.
Researcher notes
CWE-416 and CWE-825 describe the use-after-free and expired-pointer conditions. The important validation boundary is not PHP alone: SOAP must process attacker-controlled Apache Map content. The source bundle does not establish exploit reliability, affected application frameworks, indicators of compromise, or mitigations beyond moving to fixed releases and relevant vendor updates.
Mitigation direction
Upgrade to PHP 8.2.31, 8.3.31, 8.4.21, 8.5.6, or a later supported release.
Prioritize internet-facing services that accept untrusted SOAP request bodies.
If immediate upgrading is impossible, restrict untrusted access to SOAP endpoints while checking vendor guidance.
Apply relevant distribution security updates where PHP is supplied by an operating-system vendor.
Validation and detection
Inventory PHP versions and determine whether the SOAP extension is installed and enabled.
Identify public or partner-accessible endpoints that process SOAP request bodies.
Confirm deployed versions meet the fixed-version thresholds for their respective PHP branches.
Review vendor package advisories because distribution version numbering may differ from upstream PHP.
After updating, verify runtime PHP versions and retest legitimate SOAP application workflows.
Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.
Potential ATT&CK relevance
Conservative CVE-to-ATT&CK context
These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.
ATT&CK lookup starting points
Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.
cwe · low confidence lookup
CWE-416: Exact CWE lookup
Use the exact CWE identifier as the starting point before reviewing related ATT&CK behavior. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.
Use the exact CWE identifier as the starting point before reviewing related ATT&CK behavior. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.
The CVE wording references code or command execution, so execution technique review may help defensive triage. This is a Glexia inferred lookup path, not an official MITRE, ATT&CK, or CVE Program mapping.
These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.
2CVSS vectors
5Timeline events
2ADP providers
12Source links
SSVC decision data
CISA-ADPCISA Coordinator
Timestamp
Version
2.0.3
Exploitation: noneAutomatable: noTechnical Impact: total
CVSS vector scores
2 official scores
We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.
CWE links open Glexia weakness intelligence pages with official CWE context, developer remediation guidance, and related CVE mappings.
CWE-416 · source CWE mapping
Use After Free
Use After Free represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.
Expired Pointer Dereference represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.