CVE-2026-126727: Composer/drupal/texts vulnerability
The Texts module provides key-based strings and translations for Drupal, including Twig filters for displaying translated text.
The module does not sufficiently validate translation HTML and can display stored translations without sufficient filtering. A user who can create or edit string translations could inject JavaScript into pages that render those translations.
This vulnerability is mitigated by the fact that an attacker must have the "Create string translation" or "Edit string translation" permission, and a site must render the affected text using the module’s Twig filters.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
composer/drupal/textsto a version that resolves this vulnerability.Fixed in 1.0.17
Event History
Frequently Asked Questions
Who can exploit this issue?
An attacker must have either the "Create string translation" or "Edit string translation" permission. Users without one of those permissions cannot use this issue to inject translation content.
When is a site exposed?
The site must use the Texts module and render the affected translated text through the module's Twig filters. If injected translations are rendered in pages viewed by other users, the injected JavaScript can execute in those pages.
What can be done while waiting to patch?
Remove the "Create string translation" and "Edit string translation" permissions from untrusted accounts. Review existing translations created or edited by accounts with those permissions, particularly translations rendered through the module's Twig filters.