A use-after-free flaw in PHP's ext-soap component can let attackers achieve remote code execution by sending a crafted SOAP request that abuses apache:Map handling and href references. Tracked as CVE-2026-6722 and GHSA-85c2-q967-79q5, the bug occurs because PHP stores plain object pointers in SOAP_GLOBAL(ref_map) keyed by libxml2 node pointers without increasing the objects' reference counts, allowing stale references to remain after the original object has been freed.
The issue affects PHP 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. According to the advisory, duplicate keys in an apache:Map node can trigger object replacement and free the original object while leaving a dangling pointer in the reference map; a later href dereference can then access reclaimed memory, which attackers may shape through subsequent string allocations to gain code execution. PHP fixed the bug by incrementing the object's reference count before inserting it into the map and using safe cleanup logic with ZVAL_PTR_DTOR when processing ends.

See affected versions and whether adversaries are exploiting it.
1 event from the most recent confirmed update back to the earliest known activity.
A GitHub security advisory disclosed a use-after-free flaw in PHP's ext-soap component that can lead to remote code execution via Apache Map handling and href references. The advisory states the issue is fixed in PHP 8.2.31, 8.3.31, 8.4.21, and 8.5.6.
Vulnerabilities, threat actors, malware, products, organizations, and breaches Mallory has linked to this story.
See whether adversaries are exploiting this yet, and where the affected versions run in your environment.
2 references tracked. Mallory keeps watching after this page renders.
Map indicators from this story to your assets and identify affected systems in minutes.
Every observed campaign, victim, and pivot linked to actors named in this story.
Malware, exploits, and IOCs connected to the activity described here.
YARA, Sigma, and Snort rules deployed to your SIEM as soon as they’re published.
Get matching new stories delivered to your team as they break — not the next morning.
Ask questions about this story and take action on the answers.