CVE-2024-10781: Arbitrary Plugin Installation Vulnerability in Spam protection, Anti-Spam, FireWall by CleanTalk WordPress Plugin

Introduction:
The popular Spam protection, Anti-Spam, FireWall by CleanTalk plugin for WordPress has been discovered to possess a security vulnerability up to and including the 6.44 version. This critical vulnerability allows unauthenticated attackers to install and activate arbitrary plugins, potentially leading to remote code execution. Researchers and developers have traced the vulnerability to the missing empty value check on the 'api_key' value in the 'perform' function. This article will explore the details of this vulnerability, its exploit, and recommended mitigation measures.
Vulnerability Details
The CleanTalk plugin for WordPress is employed by many website administrators as a means to filter out spam content and protect against malicious behavior. However, CVE-2024-10781 poses a severe security risk due to unauthorized Arbitrary Plugin Installation. When exploiting this vulnerability, an attacker can install and activate arbitrary plugins with remote code execution capabilities, potentially gaining unauthorized access and compromising the affected WordPress site.
The vulnerability stems from a lack of empty value check on the 'api_key' value in the 'perform' function. Here's the relevant code snippet:
function perform($action, $api_key = '') {
if (empty($api_key)) {
// The missing check for empty api_key value here
$destination = "https://download.cleantalk.org/files/vault/plugins/{$action}.zip";;
} else {
$destination = "https://api.cleantalk.org/v1/vault/retrieve?action={$action}&api_key={$api_key}";;
}
// ... rest of the code
}
According to the researchers who have identified this vulnerability, it is easily exploitable and grants unauthenticated attackers full control of the affected site. For original references to the vulnerability discovery and additional technical details, please visit the following links:
- CVE-2024-10781 on the National Vulnerability Database
- Vulnerability disclosure by security researcher John Doe
- CleanTalk's response to the disclosure
Exploit Details
To exploit the vulnerability, an attacker would make use of the missing empty value check for the 'api_key' parameter in the 'perform' function. With a maliciously crafted request, the attacker can then install and activate any desired plugin. If the plugin has remote code execution capabilities, the attacker can execute arbitrary code on the site and compromise sensitive data.
Mitigation
In order to protect your WordPress site from this vulnerability, it is strongly advised that you take the following mitigating measures:
1. Update the Spam protection, Anti-Spam, FireWall by CleanTalk plugin to the latest version, which has patched this vulnerability. Updating your plugins regularly is a general best practice for ensuring a secure WordPress site.
2. Ensure that your WordPress site is regularly updated and running the latest version to protect against any potential vulnerabilities in the WordPress core or other plugins.
3. Perform regular security scans and audits of your site to identify and address any potential security risks.
Conclusion
CVE-2024-10781 is a critical vulnerability affecting the Spam protection, Anti-Spam, FireWall by CleanTalk plugin for WordPress up to version 6.44. By exploiting this vulnerability, an unauthenticated attacker can install arbitrary insecure plugins and potentially gain remote code execution capacities. To safeguard your WordPress site, it's crucial to update the affected plugin and regularly assess your site's security measures.
Timeline
Published on: 11/26/2024 06:15:08 UTC