CVE-2026-104021
Vulnérabilité élevée dans Fastcache by Host.it (hostspa)
Description
The Fastcache by Host.it plugin for WordPress is vulnerable to Code Injection in all versions up to, and including, 1.7.4 via the `fastcache_settings[cache_cookie_exclude][]` parameter. This is due to the plugin registering the `cache_cookie_exclude` setting via `register_setting()` without a `sanitize_callback`, while `buildSiteHtaccessRules()` applies only `trim()` to each cookie value before interpolating it directly into an Apache `RewriteCond` line — a normalization that strips surrounding whitespace but leaves embedded newlines intact, allowing an attacker to break out of the capture group and append arbitrary directives. This makes it possible for authenticated attackers, with administrator-level access and above, to inject arbitrary Apache directives into the site's `.htaccess` file via `file_put_contents()`, enabling server-level configuration changes such as setting `php_value auto_prepend_file` to execute attacker-controlled PHP code on every request.
Gravité et risque d'exploitation
CVE-2026-104021 obtient un score CVSS de 7.2/10, soit une gravité élevée. Selon le modèle EPSS, la probabilité qu'elle soit exploitée dans les 30 prochains jours est de 0.40 %, ce qui la place devant 32.7 % des CVE référencées.
Que faire ?
- Vérifiez si Fastcache by Host.it (versions <=1.7.4, 0) est présent sur votre parc.
- Appliquez le correctif ou la version corrigée indiqués dans les références de l'éditeur.
- À défaut de correctif, limitez l'exposition (filtrage réseau, désactivation du composant).
- Automatisez la détection : les agents CVE Heimdall (gratuits, open source) corrèlent l'inventaire de vos serveurs avec la base CVE.
Références
- https://www.wordfence.com/threat-intel/vulnerabilities/id/d72d7a21-0bea-4a32-b92b-326f47998b80?source=cve
- https://plugins.trac.wordpress.org/browser/fastcache-by-host-it/tags/1.7.4/src/Core/Platform/Utility.php#L545
- https://plugins.trac.wordpress.org/browser/fastcache-by-host-it/tags/1.7.4/src/Core/Platform/Utility.php#L420
- https://plugins.trac.wordpress.org/browser/fastcache-by-host-it/tags/1.7.4/src/Core/Platform/Utility.php#L521
- https://plugins.trac.wordpress.org/browser/fastcache-by-host-it/tags/1.7.4/src/Dispatcher.php#L480
- https://plugins.trac.wordpress.org/browser/fastcache-by-host-it/tags/1.7.4/src/Admin.php#L73
- https://plugins.trac.wordpress.org/changeset?reponame=&old=3735944%40fastcache-by-host-it&new=3735944%40fastcache-by-host-it
