Skip to main content

Term Reference Tree CVE-2026-4093

| EUVDEUVD-2026-31377 MEDIUM
Cross-site Scripting (XSS) (CWE-79)
2026-05-21 mlhess@drupal.org GHSA-q6w2-7g3j-5vg3
5.1
CVSS 4.0 · Vendor: drupal
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Authenticate as low-privilege term-editor
  2. Delivery
    Inject JS payload into taxonomy term name or description
  3. Exploit
    Victim with elevated privileges views form containing widget
  4. Execution
    Stored XSS payload executes in victim's browser
  5. Impact
    Attacker captures session token or performs privileged actions

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Output encoding, context-aware escaping
MITRE ATT&CK

2 techniques across 2 tactics: Initial Access, Execution

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

The attacker must hold a Drupal 7 user account with at least the 'edit terms' or 'administer taxonomy' permission for the vocabulary referenced by the Term Reference Tree field - this is PR:L (low privilege) per the CVSS 4.0 vector and is not default for anonymous or basic authenticated users. A victim user must passively view a form or page that renders the Term Reference Tree widget after the payload is stored (UI:P per CVSS). For Vector A specifically, the Token module must be installed and enabled on the Drupal site, and a token display template must be configured for the relevant Term Reference Tree field - this is a non-default configuration. For Vector B, no additional module or configuration is required beyond the Term Reference Tree widget being present on a form. Exploitation is limited to Drupal 7 installations running Term Reference Tree 7.x-1.11 or earlier; sites where only fully trusted administrators manage taxonomy terms are at significantly reduced risk because the low-privilege attacker precondition cannot be met by untrusted users.

Impact

The CVSS 4.0 score of 5.1 (Moderate) reflects a realistic, calibrated risk profile. The vector AV:N/AC:L/AT:N/PR:L/UI:P accurately captures the two limiting factors: low but non-zero privilege (PR:L - the attacker must hold taxonomy term edit rights) and passive user interaction (UI:P - a victim must render the affected form or page). Impact is bounded at Low across all confidentiality and integrity dimensions (VC:L/VI:L/SC:L/SI:L), consistent with typical stored XSS where the immediate payload is session hijacking or credential theft rather than direct data exfiltration or system compromise. No EPSS score was provided in the source data, so exploitation probability cannot be quantified. The vulnerability is not listed in CISA KEV and no public exploit code has been identified at time of analysis, suggesting it has not yet attracted widespread attacker tooling. However, the persistent (stored) nature of both vectors meaningfully increases real-world risk relative to reflected XSS: a single successful injection survives across sessions and can target high-privilege editors or administrators. In organizations running Drupal 7 beyond its end-of-life date with untrusted contributors holding term-edit permissions, this should be treated as a genuine priority. For sites where only administrators manage taxonomy, the practical risk is substantially reduced.

Exploit ScenarioDerived

An attacker with a contributor-level Drupal account holding the 'edit terms' permission navigates to the taxonomy term administration interface and injects a JavaScript payload - for example a cookie-stealing script - into a taxonomy term's name or description field used by a Term Reference Tree widget. When an editor or site administrator subsequently views any content creation or editing form that includes that Term Reference Tree field, the stored payload executes silently in their browser session, allowing the attacker to steal the administrator's session cookie and escalate to full site control. No public exploit code has been identified at time of analysis, but the attack requires no specialized tooling beyond a browser and a valid low-privilege account.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
No patch listed yet 0.0% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – May 21, 2026

Stored cross-site scripting in the Drupal 7 Term Reference Tree module (versions 7.x-1.x through 7.x-1.11) exposes two distinct injection vectors in its widget and formatter rendering pipeline, both exploitable by any authenticated user with taxonomy term edit permissions. Vector A triggers when the Token module is enabled and token display templates are configured, allowing attacker-controlled term description output to render unsanitized. Vector B targets the widget itself, where taxonomy term labels are written to form output without sanitization, executing injected scripts in the browsers of users who view any form containing the widget. No public exploit code has been identified at time of analysis and the vulnerability is not listed in CISA KEV, but the low privilege bar and persistent nature of stored XSS make this a meaningful risk in multi-user Drupal 7 deployments.

RemediationAI

The primary remediation is to upgrade the Term Reference Tree module to a version beyond 7.x-1.11 that includes output sanitization fixes; consult the Tag1 d7es advisory at https://d7es.tag1.com/security-advisories/taxonomy-term-reference-tree-widget-moderately-critical-cross-site-scripting or the HeroDevs advisory at https://www.herodevs.com/vulnerability-directory/cve-2026-4093 for the exact patched release, as no specific fix version was identified in the available data. If a patched module version is not immediately available or cannot be deployed, the following compensating controls should be applied in order of preference: restrict the 'edit terms' and 'administer taxonomy' Drupal permissions to fully trusted administrative roles only, eliminating the low-privilege attack path; if Vector A is the primary concern, disable the Token module integration or remove token display template configurations for Term Reference Tree fields, which eliminates that specific rendering path while preserving basic widget functionality; apply Drupal's built-in text format restrictions to taxonomy term description fields to strip HTML on save, reducing the persistence window for injected payloads. Note that restricting permissions may break contributor workflows that rely on taxonomy management. Given that Drupal 7 is end-of-life, organizations should also evaluate migration to Drupal 10/11 as a long-term remediation path.

Affected VersionsENISA

Term Reference Tree 7.x-1.x ≤7.x-1.11

Affected Packages

euvd term_reference_tree no fix

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

The Term Reference Tree module (Drupal project page, 7.x-1.x branch) provides a hierarchical tree widget for referencing taxonomy terms in Drupal 7 content. It relies on Drupal's Form API and Taxonomy API for rendering term labels inside widgets, and optionally integrates with the Token module to allow customizable display templates using token substitution. The root cause is CWE-79 (Improper Neutralization of Input During Web Page Generation), manifesting in two places: (1) token-substituted values from term descriptions passed into template output without HTML encoding, and (2) raw taxonomy term label strings rendered into widget markup without escaping. Because Drupal 7's taxonomy system allows any user with the 'edit terms' or 'administer taxonomy' permission to modify term names and descriptions, the trust boundary is breached - contributor-level principals can inject persistent payloads that execute in administrative or editor contexts. Drupal 7 itself reached end-of-life on January 5, 2025; ongoing patches for this module are expected only through commercial LTS providers such as Tag1 (d7es) and HeroDevs.

Know when Taxonomy Term Reference Tree Widget gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (drupal) PRIMARY 5.1 MEDIUM
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:P/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N

Primary rating from Vendor (drupal) · only source for this CVE.

CVSS VectorVendor: drupal

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
Low
User Interaction
Passive
Vulnerable system: Confidentiality
Low
Vulnerable system: Integrity
Low
Vulnerable system: Availability
None
Subsequent system: Confidentiality
Low
Subsequent system: Integrity
Low
Subsequent system: Availability
None

DescriptionCVE.org

In the Drupal 7 Term Reference Tree module, two stored XSS vectors exist in the widget/formatter rendering pipeline.

Vector A (token display templates): When the Token module is enabled and token display templates are configured, attacker-controlled token output (e.g., term description) is rendered without proper sanitization. Any user who can edit the referenced taxonomy terms can inject HTML/JS that executes when the field is rendered.

Vector B (term label rendering): Taxonomy term labels are not properly sanitized before being rendered in the widget, allowing a user with permission to create or edit taxonomy terms to inject scripts into the term name that execute when a form containing the widget is viewed.

Exploit affects versions 7.x-1.x up to and including 7.x-1.11.

Threat Intelligence Overview

EPSS Score
0.0%
Top 85% exploitable
Data Quality
5 sources
Confidence: Medium

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.0%
Patch available No
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
No
Human Impact· derived
Medium
Technical Impact
Partial

Priority Score

26
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +26
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy