Summary
CVE-2026-54721 is a high-severity server-side code injection vulnerability in the Silverstripe UserForms visual form builder. An authenticated CMS user who can configure a UserForms email recipient may place a crafted value in the subject field, causing executable server-side code to run and potentially compromising the application.
Affected context
The vulnerability occurs in Silverstripe CMS deployments using UserForms email recipient configuration. It becomes risky when an authenticated CMS user has permission to configure a recipient and the subject field is processed in a way that interprets specially crafted content as server-side code rather than treating it strictly as data.
Exploit preconditions
- Attack surface: The Silverstripe CMS UserForms administration interface
- Required access: An authenticated CMS account with permission to configure a UserForms email recipient
- Trigger point: Processing or sending a UserForms email whose recipient subject contains crafted content
- Why exploitation is possible: Subject input is insufficiently separated from server-side code execution contexts
Why this happens
The underlying issue is a failure to maintain a strict separation between user-controlled subject data and executable server-side expressions. When specially crafted input is evaluated by a server-side templating or execution mechanism, an authorized user may influence application behavior beyond the intended email subject value. This maps to CWE-94: Improper Control of Generation of Code, commonly called code injection.
Potential impact
- An attacker may execute arbitrary code with the privileges of the Silverstripe application
- Confidential data could be accessed or exfiltrated
- Application content and configuration could be modified
- The CMS or underlying server could become unavailable
- Compromised credentials or application access could support further attacks
General mitigation guidance
Mitigation generally focuses on preventing user-controlled values from reaching server-side code evaluation paths.
Common defensive patterns include:
- Treating email subject fields strictly as data and disabling expression evaluation
- Applying context-appropriate output encoding and allowlist-based validation
- Separating template rendering from administrative input and using inert data-binding APIs
- Limiting UserForms configuration permissions according to least privilege
- Running the application with minimal operating-system and database privileges
- Adding regression tests for code-injection behavior in form configuration fields
How teams detect issues like this
Organizations can look for this vulnerability through:
- Static analysis rules identifying dynamic evaluation, unsafe template interpolation, or executable rendering of CMS fields
- Code review checks for administrative inputs passed into template engines, interpreters, or command-construction APIs
- Monitoring unusual changes to UserForms email recipient settings and unexpected server-side errors
- Policy enforcement requiring allowlisted validation and non-executable rendering for configurable text fields
- Automated security review tools that flag CWE-94 patterns in server-side code

