CVE-2026-45697: Formie Pre-authenticated Server-side Template Injection Vulnerability
CRITICALCVE-2026-45697 is a CRITICAL (CVSS 9.8) pre-authenticated server-side template injection vulnerability (CWE-693: Protection Mechanism Failure) affecting Formie libraries in the Packagist ecosystem. The issue involves pre-authenticated server-side template injection in hidden fields. Remediation is available by upgrading affected packages to version 3.1.24, 2.2.20.
CVE-2026-45697 at a Glance
Security Impact
CVSS: 9.8
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H).
How to Fix CVE-2026-45697
To remediate this vulnerability, upgrade all affected Formie dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade verbb/formie to 3.1.24
Upgrade verbb/formie to 2.2.20
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for verbb/formie
How to Check if You Are Affected
To determine whether your application is affected by CVE-2026-45697, inspect your project dependencies for Formie:
inspect dependencies for verbb/formie
Analyze the terminal output to locate any version of Formie in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 3.1.24), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-693: Protection Mechanism Failure, where the product does not use or incorrectly uses a protection mechanism that provides sufficient defense against directed attacks against the product. In Formie, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2026-45697 Affected Formie Versions
2 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
verbb/formie
|
Packagist |
≥ 3.0.0-beta.1
< 3.1.24
|
3.1.24
|
|
verbb/formie
|
Packagist |
< 2.2.20
|
2.2.20
|
References
Frequently Asked Questions
What is CVE-2026-45697?
Which Formie versions are affected?
What version fixes CVE-2026-45697?
Is verbb/formie affected?
What is the CVSS score of CVE-2026-45697?
What CWE is associated with CVE-2026-45697?
How can I check Packagist dependencies for CVE-2026-45697?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-x7m9-mwc2-g6w2",
"modified" : "2026-06-09T10:32:38Z",
"published" : "2026-05-18T17:23:39Z",
"aliases" : [ "CVE-2026-45697" ],
"summary" : "Formie: Pre-authenticated server-side template injection in Hidden fields",
"details" : "### Impact\n- Unauthenticated users could submit crafted values into Hidden fields (with Default value → Custom) that were evaluated as Twig during submission handling, which could lead to serious compromise of the Craft site (depending on template/sandbox behavior).\n- Sites with public Formie forms that include at least one Hidden field with that configuration.\n- No CP login for the reported chain.\n\n### Patches\n- [2.2.20](https://github.com/verbb/formie/releases/tag/2.2.20), [3.1.24](https://github.com/verbb/formie/releases/tag/3.1.24)\n\n### Workarounds\n- Temporarily remove Hidden fields from public forms or switch Hidden default away from Custom where feasible\n- Otherwise, upgrade to patched versions",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "Packagist",
"name" : "verbb/formie"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "3.0.0-beta.1"
}, {
"fixed" : "3.1.24"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Packagist",
"name" : "verbb/formie"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "2.2.20"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/verbb/formie/security/advisories/GHSA-x7m9-mwc2-g6w2"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-45697"
}, {
"type" : "WEB",
"url" : "https://github.com/verbb/formie/commit/f690d5623163ce2a95da305238d6367575486ee3"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/verbb/formie"
}, {
"type" : "WEB",
"url" : "https://github.com/verbb/formie/releases/tag/2.2.20"
}, {
"type" : "WEB",
"url" : "https://github.com/verbb/formie/releases/tag/3.1.24"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-1336", "CWE-693", "CWE-94" ],
"severity" : "CRITICAL",
"github_reviewed" : true,
"github_reviewed_at" : "2026-05-18T17:23:39Z",
"nvd_published_at" : "2026-05-29T20:16:27Z"
}
}