CVE-2026-2707

weForms <= 1.6.27 - Authenticated (Subscriber+) Stored Cross-Site Scripting via Hidden Field Value via REST API

2026-03-10 17:12
Muhammad Sharief

Strategic Overview

Status
Patched in 1.6.28
Affected Version
<= 1.6.27
CVSS
6.4Medium
Weakness type
CWE-79 · Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
CVE
CVE-2026-2707
View all weForms – Easy Drag & Drop Contact Form Builder For WordPress vulnerabilities

At a glance

CVE-2026-2707 is a medium-severity Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') vulnerability in the weForms WordPress plugin, affecting versions <= 1.6.27. It carries a CVSS score of 6.4 (reachable over the network; low attack complexity). Exploitation requires an authenticated account at Subscriber level or above. The issue is fixed in version 1.6.28; sites on affected versions should update now. Disclosed March 2026, reported by Muhammad Sharief.

Vulnerability Overview

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.

Technical Analysis

The vector marks this flaw as remotely reachable over the network, with low attack complexity — no special timing or configuration is needed, and no interaction from a victim user.

CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')

weForms <= 1.6.27 carries this weakness at prepare_entry(), and reaching it takes an account at Subscriber level or above. Cross-site scripting happens when input from a request is written into a page without being escaped for the context it lands in, so the browser parses attacker-supplied text as markup or script.

Injected script runs with the privileges of whoever views the affected page, which is how these flaws turn into administrator session theft, silent account creation or persistent backdoors in page content. For weForms the fix is 1.6.28: builds <= 1.6.27 are affected, anything from 1.6.28 onward is not.

Remediation

Update to version 1.6.28, or a newer patched version

How does WordSec protect against this?

An attacker needs Subscriber access first, so the firewall sees the attempt as traffic from a logged-in account: WordSec's web application firewall inspects request payloads before WordPress loads them. None of that substitutes for the fix: weForms 1.6.28 closes this, and updating the plugin is the step that ends it.

  • Firewall
  • Alerts

External References

Related records

Vulnerability data © Defiant, Inc., provided under the Wordfence Intelligence T&C