CVE-2026-2707
Vulnérabilité moyenne dans weForms – Easy Drag & Drop Contact Form Builder For WordPress (boldgrid)
Description
The weForms plugin for WordPress is vulnerable to Stored Cross-Site Scripting via the REST API entry submission endpoint in all versions up to, and including, 1.6.27. This is due to inconsistent input sanitization between the frontend AJAX handler and the REST API endpoint. When entries are submitted via the REST API (`/wp-json/weforms/v1/forms/{id}/entries/`), the `prepare_entry()` method in `class-abstract-fields.php` receives the WP_REST_Request object as `$args`, bypassing the `weforms_clean()` fallback that sanitizes `$_POST` data for frontend submissions. The base field handler only applies `trim()` to the value. This makes it possible for authenticated attackers, with Subscriber-level access and above, to inject arbitrary web scripts into form entry hidden field values via the REST API that execute when an administrator views the form entries page, where data is rendered using a Vue.js `v-html` directive without escaping.
Gravité et risque d'exploitation
CVE-2026-2707 obtient un score CVSS de 6.4/10, soit une gravité moyenne. Selon le modèle EPSS, la probabilité qu'elle soit exploitée dans les 30 prochains jours est de 0.39 %, ce qui la place devant 31.5 % des CVE référencées.
Que faire ?
- Vérifiez si weForms – Easy Drag & Drop Contact Form Builder For WordPress (versions 0, <=1.6.27) 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/e97854ca-b24f-4893-862d-f8e975752175?source=cve
- https://plugins.trac.wordpress.org/browser/weforms/tags/1.6.27/includes/fields/class-abstract-fields.php#L542
- https://plugins.trac.wordpress.org/browser/weforms/tags/1.6.27/assets/js-templates/spa-components.php#L80
- https://plugins.trac.wordpress.org/browser/weforms/trunk/includes/fields/class-abstract-fields.php#L542
- https://plugins.trac.wordpress.org/browser/weforms/trunk/assets/js-templates/spa-components.php#L80
- https://github.com/BoldGrid/weforms/pull/263
- https://plugins.trac.wordpress.org/changeset?sfp_email=&sfph_mail=&reponame=&new=3475812%40weforms%2Ftrunk&old=3457241%40weforms%2Ftrunk&sfp_email=&sfph_mail=
