drupal/smart_trim - SA-CONTRIB-2026-332
This module implements a field formatter for text fields that improves the Summary or Trimmed formatter built into Drupal core.
The module doesn't sufficiently escape unsafe HTML when passed through the module's Twig filter.
This vulnerability is mitigated by the fact that an attacker must have a role with the ability to post content that gets passed through a Twig template with one of the |smart_trim_* filters provided by this module.
If a site uses only use the field formatter without the Twig filter, it is not vulnerable.
Affected software
Click a technology to see all vulnerabilities affecting it.
| Platform | Package | Vulnerable versions | Fixed in |
|---|---|---|---|
| Composer package | drupal/smart_trim | < 2.2.2, >= 2.3.0, < 2.3.2 | 2.2.2, 2.3.2 |
| Drupal module | drupal/smart_trim | < 2.2.2, >= 2.3.0, < 2.3.2 | 2.2.2, 2.3.2 |
References
- Weakness (CWE)
-- Platform
- Composer, Drupal
- Package
drupal/smart_trim- Disclosed
- 11.11.2026
- Updated
- 11.11.2026 20:17
Sources and licenses
OSV / GitHub Advisory Database - DRUPAL-CONTRIB-2026-332 - CC BY-SA 2.0; code GPL-2.0-or-later
Vulnerability history: drupal/smart_trim
All published vulnerabilities of this package (Drupal module), newest first. Shows whether this is a one-off slip or a package that needs watching.
- Total entries
- 2
- First → latest
- 12.2019 11.2026
- Without a fix
- 0
- Exploited in attacks
- 0
Severity breakdown
- Unrated 2
Disclosures per year
- 2019: 1
- 2020: 0
- 2021: 0
- 2022: 0
- 2023: 0
- 2024: 0
- 2025: 0
- 2026: 1
-
drupal/smart_trim - SA-CONTRIB-2026-332 this entry
Know which vulnerabilities affect your application
With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.