WooCommerce Legacy REST API Security & Risk Analysis

wordpress.org/plugins/woocommerce-legacy-rest-api

The WooCommerce Legacy REST API, which is now part of WooCommerce itself but will be removed in WooCommerce 9.0.

400K active installs v1.0.5 PHP 7.4+ WP 6.2+ Updated Jan 23, 2025
rest-apiwoowoocommerce
92
A · Safe
CVEs total0
Unpatched0
Last CVENever
Safety Verdict

Is WooCommerce Legacy REST API Safe to Use in 2026?

Generally Safe

Score 92/100

WooCommerce Legacy REST API has no known CVEs and is actively maintained. It's a solid choice for most WordPress installations.

No known CVEs Updated 1yr ago
Risk Assessment

The 'woocommerce-legacy-rest-api' plugin version 1.0.5 exhibits a generally strong security posture based on the provided static analysis. The plugin demonstrates excellent adherence to secure coding practices, with a near-perfect implementation of prepared statements for SQL queries and robust output escaping. The complete absence of known CVEs and a clean vulnerability history further reinforce this positive outlook, suggesting a well-maintained and secure codebase over time. However, the taint analysis reveals a concerning pattern: all six analyzed flows have unsanitized paths, with all six being of high severity. While these high-severity flows do not appear to have resulted in exploitable vulnerabilities (given the lack of CVEs), they represent a significant area of potential risk that requires immediate attention. This discrepancy suggests that while the overall architecture might be secure, there are specific areas within the code that could be vulnerable if an attacker were to find a way to exploit them.

Despite the positive indicators like minimal attack surface and comprehensive capability checks, the presence of multiple high-severity unsanitized flows is a significant weakness. The plugin's strength lies in its proactive use of prepared statements and output escaping, which mitigate many common vulnerabilities. The lack of known vulnerabilities is a testament to this. However, the taint analysis points to a blind spot that, if left unaddressed, could lead to future security incidents. Therefore, while the plugin has a good foundation, the identified taint flows represent a critical area for improvement to ensure continued security.

Key Concerns

  • High severity unsanitized taint flows
  • All taint flows have unsanitized paths
Vulnerabilities
None known

WooCommerce Legacy REST API Security Vulnerabilities

No known vulnerabilities — this is a good sign.
Code Analysis
Analyzed Mar 16, 2026

WooCommerce Legacy REST API Code Analysis

Dangerous Functions
0
Raw SQL Queries
1
43 prepared
Unescaped Output
6
252 escaped
Nonce Checks
0
Capability Checks
96
File Operations
3
External Requests
0
Bundled Libraries
0

SQL Query Safety

98% prepared44 total queries

Output Escaping

98% escaped258 total outputs
Data Flows
6 unsanitized

Data Flow Analysis

6 flows6 with unsanitized paths
perform_ssl_authentication (includes\legacy\api\v1\class-wc-api-authentication.php:76)
Source (user input) Sink (dangerous op) Sanitizer Transform Unsanitized Sanitized
Attack Surface

WooCommerce Legacy REST API Attack Surface

Entry Points0
Unprotected0
WordPress Hooks 22
actionparse_requestincludes\class-wc-api.php:37
actionbefore_woocommerce_initincludes\class-wc-legacy-rest-api-plugin.php:45
actionwoocommerce_initincludes\class-wc-legacy-rest-api-plugin.php:46
actionall_pluginsincludes\class-wc-legacy-rest-api-plugin.php:50
filterwoocommerce_api_check_authenticationincludes\legacy\api\v1\class-wc-api-authentication.php:26
filterwoocommerce_api_order_responseincludes\legacy\api\v1\class-wc-api-customers.php:40
actionpre_user_queryincludes\legacy\api\v1\class-wc-api-customers.php:43
filtercomments_clausesincludes\legacy\api\v1\class-wc-api-orders.php:330
filterwoocommerce_api_endpointsincludes\legacy\api\v1\class-wc-api-resource.php:37
filterwoocommerce_api_report_responseincludes\legacy\api\v1\class-wc-api-xml-handler.php:31
filterwoocommerce_api_product_responseincludes\legacy\api\v1\class-wc-api-xml-handler.php:34
filterwoocommerce_api_check_authenticationincludes\legacy\api\v2\class-wc-api-authentication.php:26
filterwoocommerce_api_order_responseincludes\legacy\api\v2\class-wc-api-customers.php:39
actionpre_user_queryincludes\legacy\api\v2\class-wc-api-customers.php:42
filtercomments_clausesincludes\legacy\api\v2\class-wc-api-orders.php:1217
filterwoocommerce_api_endpointsincludes\legacy\api\v2\class-wc-api-resource.php:36
filterwoocommerce_api_check_authenticationincludes\legacy\api\v3\class-wc-api-authentication.php:26
filterwoocommerce_api_order_responseincludes\legacy\api\v3\class-wc-api-customers.php:39
actionpre_user_queryincludes\legacy\api\v3\class-wc-api-customers.php:42
filtercomments_clausesincludes\legacy\api\v3\class-wc-api-orders.php:1262
filterwoocommerce_api_endpointsincludes\legacy\api\v3\class-wc-api-resource.php:36
actionparse_requestincludes\legacy\class-wc-legacy-api.php:49

Scheduled Events 3

woocommerce_flush_rewrite_rules
woocommerce_flush_rewrite_rules
woocommerce_flush_rewrite_rules
Maintenance & Trust

WooCommerce Legacy REST API Maintenance & Trust

Maintenance Signals

WordPress version tested
Last updatedJan 23, 2025
PHP min version7.4
Downloads2.3M

Community Trust

Rating30/100
Number of ratings27
Active installs400K
Developer Profile

WooCommerce Legacy REST API Developer Profile

Automattic

213 plugins · 19.2M total installs

73
trust score
Avg Security Score
92/100
Avg Patch Time
1384 days
View full developer profile
Detection Fingerprints

How We Detect WooCommerce Legacy REST API

Patterns used to identify this plugin on WordPress sites during automated security audits and web crawling.

Asset Fingerprints

HTML / DOM Fingerprints

REST Endpoints
/wc-api/v1//wc-api/v2//wc-api/v3/
FAQ

Frequently Asked Questions about WooCommerce Legacy REST API