Woocommerce Custom Product Addons Pro <= 5.4.1 - Unauthenticated Remote Code Execution via Custom Pricing Formula

9.8
Improper Neutralization of Directives in Dynamically Evaluated Code ('Eval Injection')
CVE CVE-2026-4001
CVSS 9.8 (Critical)
Publicly Published March 23, 2026
Last Updated March 23, 2026
Researcher Ren Voza

Description

The Woocommerce Custom Product Addons Pro plugin for WordPress is vulnerable to Remote Code Execution in all versions up to, and including, 5.4.1 via the custom pricing formula eval() in the process_custom_formula() function within includes/process/price.php. This is due to insufficient sanitization and validation of user-submitted field values before passing them to PHP's eval() function. The sanitize_values() method strips HTML tags but does not escape single quotes or prevent PHP code injection. This makes it possible for unauthenticated attackers to execute arbitrary code on the server by submitting a crafted value to a WCPA text field configured with custom pricing formula (pricingType: "custom" with {this.value}).

References

Share

Vulnerability Details for Woocommerce Custom Product Addons Pro

Software Type Plugin
Software Slug woo-custom-product-addons-pro (view on wordpress.org)
Patched? Yes
Remediation Update to version 5.4.2, or a newer patched version
Affected Version
  • <= 5.4.1
Patched Version
  • 5.4.2

Did you know Wordfence Intelligence provides free personal and commercial API access to our comprehensive WordPress vulnerability database, along with a free webhook integration to stay on top of the latest vulnerabilities added and updated in the database? Get started today!

Learn more

Want to get notified of the latest vulnerabilities that may affect your WordPress site?
Install Wordfence on your site today to get notified immediately if your site is affected by a vulnerability that has been added to our database.

Get Wordfence

The Wordfence Intelligence WordPress vulnerability database is completely free to access and query via API. Please review the documentation on how to access and consume the vulnerability data via API.

Documentation