Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessSupply music file with malicious metadata tag
-
DeliveryImport into beets library via CLI or API
-
ExploitVictim opens web UI with web plugin enabled
-
ExecutionUnderscore template renders raw payload via `<%= ... %>`
-
PersistjQuery `.html()` inserts active HTML into DOM
-
ImpactArbitrary JavaScript executes in victim browser session
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 beets web UI plugin must be explicitly enabled by adding |
| Impact | The CVSS 4.0 score of 6.0 with vector AV:N/AC:L/AT:P/PR:N/UI:P/VC:N/VI:H/VA:N reflects a network-exploitable flaw with high integrity impact to the vulnerable system, but tempered by specific attack requirements (AT:P - attacker must have previously written malicious metadata) and required user interaction (UI:P). EPSS at 0.05% (14th percentile) strongly aligns with SSVC's 'Exploitation: none' finding, indicating no current threat actor activity. SSVC also rates the flaw 'Automatable: no,' consistent with the two-phase prerequisite: metadata poisoning followed by victim browsing. The CVE is not in CISA KEV. The net picture is a genuine but low-urgency vulnerability: real JavaScript execution is achievable, but the attacker must first gain write access to library metadata and the victim must actively use the web UI, which is not enabled by default. Defenders running beets with the web plugin exposed to untrusted users or networks should prioritize patching; air-gapped or single-user deployments face minimal realistic risk. |
| Exploit ScenarioDerived | An attacker with write access to the beets library - for example, by supplying a music file with a crafted ID3 title tag such as |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Jul 24, 2026
Stored XSS in the beets music library web UI (versions prior to 2.10.0) allows arbitrary JavaScript execution in a victim's browser when metadata fields such as title, lyrics, or comments contain attacker-controlled HTML payloads. The flaw stems from Underscore.js raw template interpolation (<%= ... %>) feeding untrusted metadata directly into jQuery's .html() DOM insertion method in beetsplug/web/static/beets.js. No active exploitation is confirmed - SSVC rates exploitation as none and EPSS sits at 0.05% (14th percentile) - but the attack is persistent once metadata is poisoned and does not require repeated attacker access.
RemediationAI
Vendor-released patch: beets 2.10.0. Upgrade via pip install --upgrade beets and verify with beet version; the release notes at https://github.com/beetbox/beets/releases/tag/v2.10.0 confirm this release. The fix replaces raw Underscore interpolation (<%= ... %>) with HTML-escaped syntax (<%- ... %>) for untrusted metadata fields and eliminates the unsafe .html() DOM insertion path. Debian LTS users can follow the announcement at https://lists.debian.org/debian-lts-announce/2026/06/msg00030.html for distribution-packaged backports. If immediate upgrade is blocked, the most effective compensating control is disabling the web UI plugin entirely by removing web from the plugins list in your beets configuration file - this eliminates the attack surface with no impact to CLI music-management workflows. Do not expose the beets web UI to untrusted networks as an interim measure; binding it to localhost or placing it behind authenticated reverse proxy reduces but does not eliminate risk if shared metadata is writable by untrusted parties.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in pypi
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
beets (pkg:pip/beets) is a Python-based music collection management tool that includes an optional web UI plugin (beetsplug/web). The web interface renders music item data using Backbone.js models and Underscore.js templates. CWE-79 (Improper Neutralization of Input During Web Page Generation) is the root cause class: Underscore defines two interpolation modes - <%= ... %> for raw, unescaped output and <%- ... %> for HTML-escaped output - and the templates at beetsplug/web/templates/index.html:42-46,87-91 use the unsafe raw form for user-controlled metadata fields. The rendered string is then passed to jQuery's .html() at beetsplug/web/static/beets.js:182,208,220, which parses and activates any embedded HTML/script content. The vulnerable commit is 80cd21554124da07d17a4f962c7d770a4f70d0f2; all releases packaging beets < 2.10.0 are affected per EUVD-2026-27055 and GHSA-3gxm-wfjx-m847.
Know when the next one hits your stack
- 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
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N
Network-accessible web UI, no attacker auth required to plant metadata via file import, scope changes to victim browser, with low C/I impact limited to session context.
Primary rating from Vendor (https://github.com/beetbox/beets).
CVSS VectorVendor: https://github.com/beetbox/beets
Lifecycle Timeline
3DescriptionCVE.org
During code logic analyis, an area that may lead to unintended behavior under specific conditions was discovered.
Overview
- Verified Version:
80cd21554124da07d17a4f962c7d770a4f70d0f2 - Vulnerability Type: Stored XSS
- Affected Location:
beetsplug/web/templates/index.html:42 - Trigger Scenario: Metadata fields such as
title,lyrics, orcommentsare rendered with raw template interpolation and inserted into DOM via.html(...).
Root Cause
The bundled web UI uses Underscore template interpolation mode <%= ... %> for untrusted metadata fields. In this runtime, <%= ... %> is raw insertion and HTML escaping is only performed by <%- ... %>. Rendered output is then inserted with .html(...), allowing attacker-controlled markup to become active DOM.
Source-to-Sink Chain
- Source (attacker-controlled input)
- Item metadata values (for example
title,lyrics,comments) can contain attacker HTML payload.
- Data flow
- Templates in
beetsplug/web/templates/index.html:42-46,87-91render metadata with<%= ... %>. - Underscore runtime defines
<%= ... %>as raw interpolation (beetsplug/web/static/underscore.js:890-907).
- Sink (security-sensitive action)
- Frontend inserts rendered template output into DOM via
$(this.el).html(this.template(this.model.toJSON()));inbeetsplug/web/static/beets.js:182,208,220.
Exploitation Preconditions
- Victim opens the web UI page that renders attacker-controlled metadata.
- Metadata includes executable HTML/JS payload.
Risk
Stored payload executes in the web UI context and can perform actions available to that origin.
Impact
Attacker can run arbitrary JavaScript in the victim browser, exfiltrate viewable data, and perform UI-driven actions as the victim session.
Remediation
- Replace raw interpolation
<%= ... %>with escaped output<%- ... %>for untrusted fields. - Avoid
.html(...)for untrusted template output; use text-safe rendering. - Sanitize metadata values on ingest and before rendering, including attribute contexts.
Threat Intelligence Overview
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.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.
EUVD-2026-27055
GHSA-3gxm-wfjx-m847
NVD
CVE.org
EPSS
Vulnrichment
VulDB
Exploit-DB