Summary
XML-RPC for PHP's Wrapper::buildClientWrapperCode method allows code injection via malicious $client argument
In order for this weakness to be exploited, the following conditions have to apply, at the same time:
- method
Wrapper::buildClientWrapperCode, or any methods which depend on it, such asWrapper::wrapXmlrpcServer,Wrapper::wrapXmlrpcMethodorWrapper::buildWrapMethodSourcemust be in use. Note that they are not used by default in either the Client or Server classes provided by the library; the developer has to specifically make use of them in his/her own code - the
$clientargument to either of those methods should have been built with malicious data, ie. data controlled by a 3rd party, passed to its constructor call
This is most likely an uncommon usage scenario, and as such the chances of exploitation may be low.
NB the graphical debugger which is shipped as part of the library is vulnerable to this, when used with the option "Generate stub for method call" selected. In that case, the debugger will display but not execute the malicious code, which would have to be provided via carefully crafted values for the "Address" and "Path" inputs.
The attack scenario in this case is that a developer copies into his/her own source code the php snippet generated by the debugger, in a situation where the debugger is used with "Address"/"Path" input values supplied by a 3rd party.
The malicious payload in the "Address"/"Path" input values should be easily recognized as suspicious by any barely proficient developer, as it resembles a bog-standard injection attack.
It goes without saying that a responsible developer should not blindly copy and paste into his/her own code anything generated by a 3rd party tool, such as the phpxmlrpc debugger, without giving it at least a cursory scan.
Originally reported as issue #80
Impact
Untrusted input is evaluated as executable code within the application's runtime environment. Typical impact: arbitrary code execution within the application's privilege context.
Affected versions
Security releases
Kodem intelligence
Severity tells you how bad this could be in the worst case. It does not tell you whether you are exposed. Exploitability and impact are functions of runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A vulnerable package can sit in your dependency tree and never run.
Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter. Kodem's runtime-powered SCA identifies whether this CVE is reachable in your applications.
Already deployed Kodem?
See it in your environmentNew to Kodem? Get a demo →Remediation advice
Kodem Kai can prioritize this vulnerability in your dependency tree and generate a fix recommendation.
Frequently Asked Questions
- What is GHSA-7VCX-V65Q-9WPG? GHSA-7VCX-V65Q-9WPG is a medium-severity code injection vulnerability in phpxmlrpc/phpxmlrpc (composer), affecting versions < 4.9.0. It is fixed in 4.9.0. Untrusted input is evaluated as executable code within the application's runtime environment.
- Which versions of phpxmlrpc/phpxmlrpc are affected by GHSA-7VCX-V65Q-9WPG? phpxmlrpc/phpxmlrpc (composer) versions < 4.9.0 is affected.
- Is there a fix for GHSA-7VCX-V65Q-9WPG? Yes. GHSA-7VCX-V65Q-9WPG is fixed in 4.9.0. Upgrade to this version or later.
- Is GHSA-7VCX-V65Q-9WPG exploitable, and should I be worried? Whether GHSA-7VCX-V65Q-9WPG is exploitable in your environment depends on whether the vulnerable code is present and reachable. A CVSS score is a worst-case rating; it does not account for your specific deployment, configuration, or usage patterns. Kodem, an Intelligent Application Security platform, uses runtime intelligence to show which vulnerabilities actually execute in production, so you can focus on the ones that represent real risk. Get a demo
- What actually determines whether GHSA-7VCX-V65Q-9WPG is exploitable, and how bad it is? Exploitability and impact are not fixed properties of a CVE. They depend on runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A high CVSS score on a dependency that never runs is not the same as real risk. Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter.
- How do I fix GHSA-7VCX-V65Q-9WPG? Upgrade
phpxmlrpc/phpxmlrpcto 4.9.0 or later.