CVE-2022-2099: Woocommerce/woocommerce Remote Code Execution Vulnerability
MODERATECVE-2022-2099 is a MODERATE (CVSS 4.8) remote code execution vulnerability (CWE-116: Improper Encoding or Escaping of Output) affecting Woocommerce/woocommerce libraries in the Packagist ecosystem. The issue involves woocommerce wordpress plugin before 6.6.0 vulnerable to stored html injection. Remediation is available by upgrading affected packages to version 6.6.0.
CVE-2022-2099 at a Glance
Security Impact
CVSS: 4.8
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:L/I:L/A:N).
How to Fix CVE-2022-2099
To remediate this vulnerability, upgrade all affected Woocommerce/woocommerce dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade woocommerce/woocommerce to 6.6.0
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for woocommerce/woocommerce
How to Check if You Are Affected
To determine whether your application is affected by CVE-2022-2099, inspect your project dependencies for Woocommerce/woocommerce:
inspect dependencies for woocommerce/woocommerce
Analyze the terminal output to locate any version of Woocommerce/woocommerce in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 6.6.0), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-116: Improper Encoding or Escaping of Output, where the product prepares a structured message for communication with another component, but encoding or escaping of the data is either missing or done incorrectly. as a result, the intended structure of the message is not preserved. In Woocommerce/woocommerce, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2022-2099 Affected Woocommerce/woocommerce Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
woocommerce/woocommerce
|
Packagist |
< 6.6.0
|
6.6.0
|
References
Frequently Asked Questions
What is CVE-2022-2099?
Which Woocommerce/woocommerce versions are affected?
What version fixes CVE-2022-2099?
Is woocommerce/woocommerce affected?
What is the CVSS score of CVE-2022-2099?
What CWE is associated with CVE-2022-2099?
How can I check Packagist dependencies for CVE-2022-2099?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-jwvf-28fg-g4xg",
"modified" : "2022-07-21T21:40:20Z",
"published" : "2022-07-18T00:00:33Z",
"aliases" : [ "CVE-2022-2099" ],
"summary" : "WooCommerce WordPress plugin before 6.6.0 vulnerable to stored HTML injection",
"details" : "The WooCommerce WordPress plugin before 6.6.0 is vulnerable to stored HTML injection due to lack of escaping and sanitizing in the payment gateway titles",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:L/I:L/A:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "Packagist",
"name" : "woocommerce/woocommerce"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "6.6.0"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2022-2099"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/woocommerce/woocommerce"
}, {
"type" : "WEB",
"url" : "https://wpscan.com/vulnerability/0316e5f3-3302-40e3-8ff4-be3423a3be7b"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-116", "CWE-94" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2022-07-21T21:40:20Z",
"nvd_published_at" : "2022-07-17T11:15:00Z"
}
}