How BitFire Blocks CVE-2024-10781: CleanTalk Anti-Spam Authentication Bypass

WordPress 漏洞研究

BitFire PRO RASP blocks CVE-2024-10781, an empty-key authentication bypass that lets unauthenticated attackers install and activate arbitrary WordPress plugins.

Unauthenticated CVSS 8.1 High Arbitrary plugin installation Authentication bypass
BitFire·漏洞通报研究发表
咨询CVE-2024-10781
组件Anti-Spam by CleanTalk – Spam Protection Without CAPTCHA
相关来源lib/Cleantalk/ApbctWP/RemoteCalls.php — RemoteCalls::perform() token check
执行摘要

WordPress 管理员需要了解什么

CleanTalk Anti-Spam 6.44 exposes an unauthenticated remote-call endpoint that is reachable on every front-end request. When the plugin's API key is empty, the endpoint's shared-secret token check compares against publicly computable digests of the empty string and passes, handing attackers administrator-equivalent plugin installation and activation from the wordpress.org catalog. On sites running an affected version, BitFire PRO RASP interrupts the attack at its decisive step: the filesystem guard blocks the unauthorized PHP plugin-file writes into wp-content/plugins, so the attacker's package never lands and cannot be activated. Version 6.45 eliminates the flaw at its source. Here is how the exploit works and exactly where BitFire stops it.

一目了然

主要事实

  • Reachable on every front-end request through the plugin's init-hooked remote-call handler, with no login or capability check.
  • An empty CleanTalk API key reduces the token gate to publicly computable empty-string digests.
  • Attackers install and activate any wordpress.org plugin without credentials, writing PHP into wp-content/plugins.
  • Remote code execution is conditional on activating a further vulnerable plugin, per the disclosure.
  • CleanTalk 6.45 adds a non-empty-key precheck and a hardened token comparison in RemoteCalls::perform().
  • BitFire PRO RASP filesystem guard blocks the unauthorized PHP write the attack depends on.
01
漏洞概述

了解曝光

WordPress 网站受影响的组件、攻击路径和实际风险。

受影响的组件Anti-Spam by CleanTalk – Spam Protection Without CAPTCHA
潜在影响范围200000安装
攻击技术authentication bypass
已发表2026-09-29
BitFire PRO RASP stops CVE-2024-10781 at the only step that matters: the instant the exploit tries to write PHP plugin files into wp-content/plugins, BitFire blocks the unauthorized write — the package never lands, and the attack dies there.
02
技术分析

该漏洞如何发挥作用

研究详细信息、受影响的版本、利用行为和补救指南。

How CVE-2024-10781 Works

CleanTalk's remote-call interface hooks WordPress's init routine, so the handler runs on every front-end request — no login, nonce, or capability check stands in front of it. The handler compares a request-supplied token against the MD5 or SHA-256 digest of the site's CleanTalk API key. That comparison never verifies the key exists. On sites where no key is set, the matching digests are constants anyone can compute offline, and the gate opens. The attacker selects the plugin-installation action and names any plugin in the wordpress.org catalog. CleanTalk's own upgrader then writes the package — including PHP files — into wp-content/plugins and activates it, operations normally reserved for administrators. Per the disclosure, code execution is conditional on activating another vulnerable plugin; the unconditional impact is unauthorized plugin installation and full site integrity compromise.

Where BitFire PRO RASP Stops the Attack

BitFire PRO RASP is included with BitFire PRO and enforces authorization at the protected operation — and this attack has exactly one: writing PHP plugin files into wp-content/plugins. When the injected remote call reaches CleanTalk's upgrader and it attempts to create the package's PHP files, BitFire PRO RASP's filesystem guard classifies the write as unauthorized PHP creation, because no valid administrator session stands behind it, and blocks it. The attacker's chosen package never lands on disk, plugin activation has nothing to install, and the disclosure's conditional code-execution scenario collapses at its first requirement. Notably, the malicious request carries ordinary parameter values with no recognizable attack pattern. This is precisely the exploit class that runtime enforcement at the write is built to stop.

The Fix in CleanTalk 6.45

CleanTalk 6.45 closes the gate in lib/Cleantalk/ApbctWP/RemoteCalls.php. A new isRcAllowed() precheck runs before any token validation and terminates the request with a FORBIDDEN response unless the installation has a non-empty API key or a qualifying hosting license. The inline digest comparison is replaced by checkToken(), which builds its comparison secret only from a non-empty key and refuses to compare against an empty one, making the empty-string match impossible. Update to 6.45 or later immediately: the unauthenticated entry point and the install/activate code paths are unchanged, so only the repaired gate stands between an attacker and plugin installation.

If Your Site Was Affected, Investigate for Persistence.

Patching closes the known path; it does not undo a compromise that already happened. If your site ran CleanTalk 6.44 or earlier — particularly without an API key set — treat it as potentially compromised. Review your installed plugin list for anything you did not install, remove it, and rotate administrator credentials and WordPress authentication keys. Then run BitFire Threat Hunter. It performs a thorough post-compromise investigation and discovers backdoor WordPress administrator accounts, hidden database triggers, long-running PHP processes, and the droppers that can restore malware or reinfect the site. A missing suspicious file proves nothing; investigate before you consider the site clean.

Stop It at the Runtime, Not the Signature

CVE-2024-10781 turns a spam-filter plugin into an unauthenticated software installer. BitFire PRO RASP does not need to recognize the CVE: the moment the exploited remote call attempts to write PHP plugin files into wp-content/plugins, BitFire's filesystem guard blocks the unauthorized write, and the attack ends at the runtime operation it depends on. Patch to CleanTalk 6.45, investigate any site that ran an older version with BitFire Threat Hunter, and put BitFire PRO RASP in front of your WordPress filesystem today.

03
来源审查

易受攻击和固定的代码

相关来源位于 lib/Cleantalk/ApbctWP/RemoteCalls.php — RemoteCalls::perform() token check.

之前弱势行为
// Check Access key
if (
    ($token === strtolower(md5($apbct->api_key)) ||
     $token === strtolower(hash('sha256', $apbct->api_key))) ||
    (self::checkWithoutToken() && self::isAllowedWithoutToken($action))
) {
之后纠正行为
if ( ! self::isRcAllowed() ) {
    die('FAIL ' . json_encode(array('error' => 'FORBIDDEN')));
}

// Check Access key
if (
    (self::checkToken($token)) ||
    (self::checkWithoutToken() && self::isAllowedWithoutToken($action))
) {
04
零日保护

防止第一个利用请求

BitFire 在漏洞被公开之前以及其他供应商有时间开发签名或补丁之前,在零天保护 WordPress 服务器。

01 · 验证停止未知客户端

在之前未知的漏洞代码到达 WordPress 之前,机器人控制和浏览器验证会阻止不受信任的自动化客户端。

02·检测阻止恶意行为

常规 WAF 保护可识别危险的请求行为和恶意负载,而无需等待特定于漏洞的签名。

03 · 预防遏制运行时攻击

RASP 遵循 PHP 内部的执行,防止对受保护的文件、帐户和数据库内容进行未经授权的更改。

BitFire · WordPress 保护零日准备就绪
BitFire 结合了经过验证的客户端控制、基于行为的 WAF 检测和运行时 RASP 实施,可在漏洞利用名称、CVE、签名或供应商补丁之前保护 WordPress。
关于作者

科里·马什

Cory 拥有 20 多年的互联网安全经验,是 BitFire 项目的首席开发人员。

阅读 BitFire 安全研究 →
保护您的 WordPress 网站

在下一个漏洞到来之前添加保护。

BitFire 将机器人控制、请求检查、恶意软件检测和运行时保护结合在一个 WordPress 安全平台中。

Protect my site free →