CVE-2025-30932
Executive Summary
CVE-2025-30932 is a Missing Authorization vulnerability in the WP Compress for MainWP WordPress plugin, affecting versions up to and including 6.30.32. This flaw allows an authenticated attacker (with low privileges) to exploit incorrectly configured access control security levels, potentially leading to unauthorized data access or modification. The vulnerability is classified under CWE-862 (Missing Authorization) and carries a CVSS score of 5.4 (Medium). As a WordPress plugin vulnerability, it directly impacts the WordPress ecosystem and any sites using the MainWP integration for WP Compress.
No public proof-of-concept (PoC) or exploit code has been released, and the patch status remains unknown. The EPSS score is 0.0%, indicating a low probability of active exploitation in the wild at this time.
This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.
No signup required
Supply Chain & Package Security
This vulnerability affects a WordPress plugin distributed via the official WordPress plugin repository and the MainWP ecosystem. Organizations using WP Compress for MainWP should treat this as a supply chain risk, as the plugin is a third-party component integrated into WordPress sites. No known malicious packages have been identified, but the lack of a patch increases the risk of future exploitation.
CVSS Breakdown & Threat Level
- CVSS Vector: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:N
- Base Score: 5.4 (Medium)
- Attack Vector: Network (AV:N)
- Attack Complexity: Low (AC:L)
- Privileges Required: Low (PR:L) – attacker must have a valid WordPress user account (e.g., subscriber).
- User Interaction: None (UI:N)
- Scope: Unchanged (S:U)
- Confidentiality Impact: Low (C:L) – limited unauthorized data access.
- Integrity Impact: Low (I:L) – limited unauthorized modification.
- Availability Impact: None (A:N)
Threat Level: Medium. The vulnerability requires authentication but is easy to exploit once access is obtained. The impact is limited to low confidentiality and integrity loss.
Deep Dive & Mechanics
The vulnerability resides in the WP Compress for MainWP plugin, which integrates WP Compress image optimization with the MainWP dashboard management system. The plugin fails to properly enforce authorization checks on certain administrative or sensitive AJAX actions, REST API endpoints, or function calls.
Root Cause: The plugin does not verify that the current user has the required capabilities (e.g., manage_options, edit_posts, or a custom capability) before executing privileged operations. This allows any authenticated user, even with minimal privileges like a subscriber, to trigger actions intended only for administrators or site managers.
Attack Vector: An attacker with a low-privilege WordPress account (e.g., subscriber) can send crafted HTTP requests to the vulnerable endpoints. The plugin processes these requests without checking the user's role, leading to unauthorized actions such as:
- Viewing or modifying compression settings.
- Accessing cached data or logs.
- Triggering image optimization tasks on other sites managed via MainWP.
Affected Component: The wp-compress-mainwp plugin's authorization logic, likely in AJAX handlers or REST API routes registered by the plugin.
Vulnerable vs. Patched Code
Since no patch is available, the following is a hypothetical comparison based on common missing authorization patterns.
Vulnerable Code (wp-compress-mainwp <= 6.30.32):
add_action('wp_ajax_wp_compress_mainwp_optimize', 'wp_compress_mainwp_optimize_callback');
function wp_compress_mainwp_optimize_callback() {
// No capability check
$site_id = $_POST['site_id'];
// Perform optimization...
wp_send_json_success();
}
Patched Code (Hypothetical):
add_action('wp_ajax_wp_compress_mainwp_optimize', 'wp_compress_mainwp_optimize_callback');
function wp_compress_mainwp_optimize_callback() {
// Check for admin or specific capability
if (!current_user_can('manage_options')) {
wp_die('Unauthorized', 403);
}
$site_id = $_POST['site_id'];
// Perform optimization...
wp_send_json_success();
}
The patch adds a current_user_can() check to ensure only users with the manage_options capability can execute the action.
Exploitation & Lab Setup
Red Team (Exploitation)
Prerequisites:
- A WordPress site with WP Compress for MainWP plugin version <= 6.30.32 installed and activated.
- A low-privilege user account (e.g., subscriber) with valid credentials.
Exploitation Steps:
- Log in as the low-privilege user.
- Identify vulnerable AJAX actions by reviewing the plugin's source code or using a tool like Burp Suite to intercept requests.
- Craft a POST request to the vulnerable endpoint, e.g.:
POST /wp-admin/admin-ajax.php HTTP/1.1 Host: target-site.com Content-Type: application/x-www-form-urlencoded Cookie: wordpress_logged_in_... action=wp_compress_mainwp_optimize&site_id=123 - The server processes the request without authorization, returning sensitive data or performing unauthorized actions.
Example cURL Command:
curl -X POST https://target-site.com/wp-admin/admin-ajax.php \
-d "action=wp_compress_mainwp_optimize&site_id=123" \
--cookie "wordpress_logged_in_...=..."
Blue Team (Detection & Hardening)
Detection:
- Monitor for AJAX requests to
admin-ajax.phpwithactionparameters starting withwp_compress_mainwp_from low-privilege users. - Alert on any
wp_compress_mainwp_*action triggered by non-admin users.
Hardening:
- Immediately update the plugin if a patch becomes available.
- If no patch, disable the plugin or restrict access to its functionality via a Web Application Firewall (WAF) rule.
- Implement role-based access controls at the WordPress level using plugins like "User Role Editor".
Indicators of Compromise (IOCs)
- File Paths:
/wp-content/plugins/wp-compress-mainwp/ - Suspicious AJAX Actions:
wp_compress_mainwp_optimize,wp_compress_mainwp_get_settings,wp_compress_mainwp_clear_cache - Log Entries: Repeated
admin-ajax.phprequests from low-privilege user IDs (e.g., subscriber role) withwp_compress_mainwp_*actions. - Network Traffic: POST requests to
/wp-admin/admin-ajax.phpwithaction=wp_compress_mainwp_*parameters from non-admin IPs.
Detection Engineering
YARA Rule
rule CVE_2025_30932_WP_Compress_MainWP_Missing_Auth {
meta:
description = "Detects exploitation attempts of CVE-2025-30932 in WP Compress for MainWP"
author = "Valters IT"
date = "2025-04-17"
reference = "https://nvd.nist.gov/vuln/detail/CVE-2025-30932"
strings:
$ajax_action = /action=wp_compress_mainwp_[a-z_]+/
$low_priv_cookie = /wordpress_logged_in_[a-f0-9]{32}/
condition:
$ajax_action and #low_priv_cookie > 0
}
Sigma Rule
title: CVE-2025-30932 - WP Compress MainWP Missing Authorization Exploitation
id: 8a4b3c2d-1e5f-4a7b-9c8d-0e1f2a3b4c5d
status: experimental
description: Detects unauthorized AJAX requests to WP Compress MainWP endpoints from low-privilege users
author: Valters IT
date: 2025-04-17
logsource:
category: webserver
product: apache
service: access_combined
detection:
selection:
cs-method: 'POST'
cs-uri-query|contains: 'admin-ajax.php'
cs-uri-query|contains: 'action=wp_compress_mainwp_'
condition: selection
falsepositives:
- Legitimate admin actions (rare)
level: medium
tags:
- attack.initial_access
- attack.t1190
Suricata Rule
alert http $HOME_NET any -> $EXTERNAL_NET any (
msg:"CVE-2025-30932 - WP Compress MainWP Missing Authorization Exploitation";
flow:to_server,established;
content:"POST"; http_method;
content:"/wp-admin/admin-ajax.php"; http_uri;
content:"action=wp_compress_mainwp_"; http_client_body;
classtype:attempted-admin;
sid:10000001;
rev:1;
reference:cve,2025-30932;
)
Remediation & Mitigation
Immediate Actions:
- Disable the plugin if it is not critical to operations.
- Apply virtual patching via WAF rules to block requests to
admin-ajax.phpwithaction=wp_compress_mainwp_*from non-admin users. - Monitor logs for exploitation attempts using the provided detection rules.
Long-Term Fix:
- Await an official patch from the vendor (WP Compress). Once released, update to the patched version immediately.
- If no patch is forthcoming, consider replacing the plugin with an alternative that has proper authorization checks.
Workaround:
- Use a WordPress security plugin (e.g., Wordfence) to add custom firewall rules that block unauthorized AJAX requests.
Valters IT
What is this? Security researchers use these exact search queries on Shodan.io (a search engine for internet-connected devices) to find vulnerable systems globally. You can copy these dorks to see if your organization's IP space is exposed.
💣 PoC CODE AVAILABLE
Exploit code for this CVE is tracked in our database.
Access poc_code via API Pro.