{"id":"CVE-2026-42052","aliases":["DEBIAN-CVE-2026-42052","EUVD-2026-27055","GHSA-3gxm-wfjx-m847","PYSEC-2026-2397","UBUNTU-CVE-2026-42052","USN-8747-1","openSUSE-SU-2026:10865-1","openSUSE-SU-2026:21383-1"],"status":"published","title":"beets is Vulnerable to XSS","description":"Beets is the media library management system. Prior to version 2.10.0, the bundled web UI uses Underscore template interpolation mode \u003c%= ... %\u003e for untrusted metadata fields. In this runtime, \u003c%= ... %\u003e is raw insertion and HTML escaping is only performed by \u003c%- ... %\u003e. Rendered output is then inserted with .html(...), allowing attacker-controlled markup to become active DOM. This issue has been patched in version 2.10.0.","severity":{"version":"4.0","score":6,"vector":"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","level":"medium","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-10","score":0.003,"percentile":0.22993,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"cwes":["CWE-79"],"published":"2026-04-29T18:29:00Z","modified":"2026-10-28T02:30:42Z","fixes":[{"ecosystem":"PyPI","package":"beets","fixed_in":["2.10.0"],"sources":["ghsa","osv"]},{"ecosystem":"Debian:12","package":"beets","fixed_in":["1.6.0-4+deb12u1"],"sources":["osv"]},{"ecosystem":"Debian:13","package":"beets","fixed_in":["2.2.0-3+deb13u1"],"sources":["osv"]},{"ecosystem":"Debian:14","package":"beets","fixed_in":["2.11.0-1"],"sources":["osv"]},{"ecosystem":"Ubuntu:Pro:16.04:LTS","package":"beets","fixed_in":["1.3.8+dfsg-2ubuntu0.1~esm1"],"sources":["osv"]},{"ecosystem":"Ubuntu:Pro:18.04:LTS","package":"beets","fixed_in":["1.4.6-2ubuntu0.1~esm1"],"sources":["osv"]},{"ecosystem":"Ubuntu:Pro:20.04:LTS","package":"beets","fixed_in":["1.4.9-4ubuntu0.1~esm1"],"sources":["osv"]},{"ecosystem":"Ubuntu:Pro:22.04:LTS","package":"beets","fixed_in":["1.6.0-1ubuntu0.1~esm1"],"sources":["osv"]},{"ecosystem":"Ubuntu:Pro:24.04:LTS","package":"beets","fixed_in":["1.6.0-8ubuntu0.1~esm1"],"sources":["osv"]},{"ecosystem":"Ubuntu:Pro:26.04:LTS","package":"beets","fixed_in":["2.5.1-4ubuntu0.1~esm1"],"sources":["osv"]},{"ecosystem":"openSUSE:Tumbleweed","package":"beets","fixed_in":["2.11.0-1.1"],"sources":["osv"]},{"ecosystem":"openSUSE:Leap 16.0","package":"beets","fixed_in":["2.2.0-bp160.2.1"],"sources":["osv"]}],"affected":[{"source":"ghsa","ecosystem":"PyPI","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.10.0"}]}]},{"source":"osv","ecosystem":"Debian:12","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.6.0-4+deb12u1"}]}],"versions":["1.6.0-4"]},{"source":"osv","ecosystem":"Debian:13","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.2.0-3+deb13u1"}]}],"versions":["2.2.0-3"]},{"source":"osv","ecosystem":"Debian:14","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.11.0-1"}]}],"versions":["2.2.0-3","2.5.1-1","2.5.1-2","2.5.1-3","2.5.1-4","2.6.2-1","2.7.1-1","2.8.0-1"]},{"source":"osv","ecosystem":"PyPI","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.10.0"}]}],"versions":["1.0.0","1.0b1","1.0b10","1.0b11","1.0b12","1.0b13","1.0b14","1.0b15","1.0b2","1.0b3","1.0b4","1.0b5","1.0b6","1.0b7","1.0b8","1.0b9","1.0rc1","1.0rc2","1.1.0","1.2.0","1.2.1","1.2.2","1.3.0","1.3.1","1.3.10","1.3.11","1.3.12","1.3.13","1.3.14","1.3.15","1.3.16","1.3.17","1.3.18","1.3.19","1.3.2","1.3.3","1.3.4","1.3.5","1.3.6","1.3.7","1.3.8","1.3.9","1.4.0","1.4.1","1.4.2","1.4.3","1.4.4","1.4.5","1.4.6","1.4.7","1.4.8","1.4.9","1.5.0","1.6.0","1.6.1","2.0.0","2.1.0","2.2.0","2.3.0","2.3.1","2.4.0","2.5.0","2.5.1","2.6.0","2.6.1","2.6.2","2.7.0","2.7.1","2.8.0","2.9.0"]},{"source":"osv","ecosystem":"PyPI","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.10.0"}]}],"versions":["1.0.0","1.0b1","1.0b10","1.0b11","1.0b12","1.0b13","1.0b14","1.0b15","1.0b2","1.0b3","1.0b4","1.0b5","1.0b6","1.0b7","1.0b8","1.0b9","1.0rc1","1.0rc2","1.1.0","1.2.0","1.2.1","1.2.2","1.3.0","1.3.1","1.3.10","1.3.11","1.3.12","1.3.13","1.3.14","1.3.15","1.3.16","1.3.17","1.3.18","1.3.19","1.3.2","1.3.3","1.3.4","1.3.5","1.3.6","1.3.7","1.3.8","1.3.9","1.4.0","1.4.1","1.4.2","1.4.3","1.4.4","1.4.5","1.4.6","1.4.7","1.4.8","1.4.9","1.5.0","1.6.0","1.6.1","2.0.0","2.1.0","2.2.0","2.3.0","2.3.1","2.4.0","2.5.0","2.5.1","2.6.0","2.6.1","2.6.2","2.7.0","2.7.1","2.8.0","2.9.0"]},{"source":"osv","ecosystem":"Ubuntu:Pro:16.04:LTS","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.3.8+dfsg-2ubuntu0.1~esm1"}]}],"versions":["1.3.8+dfsg-2"]},{"source":"osv","ecosystem":"Ubuntu:Pro:18.04:LTS","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.4.6-2ubuntu0.1~esm1"}]}],"versions":["1.3.19-2.1","1.4.6-2"]},{"source":"osv","ecosystem":"Ubuntu:Pro:20.04:LTS","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.4.9-4ubuntu0.1~esm1"}]}],"versions":["1.4.7-2","1.4.7-2ubuntu1","1.4.9-2","1.4.9-4"]},{"source":"osv","ecosystem":"Ubuntu:Pro:22.04:LTS","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.6.0-1ubuntu0.1~esm1"}]}],"versions":["1.4.9-7","1.5.0-1","1.6.0-1"]},{"source":"osv","ecosystem":"Ubuntu:Pro:24.04:LTS","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.6.0-8ubuntu0.1~esm1"}]}],"versions":["1.6.0-4","1.6.0-7","1.6.0-8"]},{"source":"osv","ecosystem":"Ubuntu:25.10","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["2.2.0-2ubuntu1","2.2.0-3"]},{"source":"osv","ecosystem":"Ubuntu:Pro:26.04:LTS","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.5.1-4ubuntu0.1~esm1"}]}],"versions":["2.2.0-3","2.5.1-4"]},{"source":"osv","ecosystem":"Ubuntu:Pro:16.04:LTS","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.3.8+dfsg-2ubuntu0.1~esm1"}]}],"versions":["1.3.8+dfsg-2"]},{"source":"osv","ecosystem":"Ubuntu:Pro:18.04:LTS","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.4.6-2ubuntu0.1~esm1"}]}],"versions":["1.3.19-2.1","1.4.6-2"]},{"source":"osv","ecosystem":"Ubuntu:Pro:20.04:LTS","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.4.9-4ubuntu0.1~esm1"}]}],"versions":["1.4.7-2","1.4.7-2ubuntu1","1.4.9-2","1.4.9-4"]},{"source":"osv","ecosystem":"Ubuntu:Pro:22.04:LTS","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.6.0-1ubuntu0.1~esm1"}]}],"versions":["1.4.9-7","1.5.0-1","1.6.0-1"]},{"source":"osv","ecosystem":"Ubuntu:Pro:24.04:LTS","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.6.0-8ubuntu0.1~esm1"}]}],"versions":["1.6.0-4","1.6.0-7","1.6.0-8"]},{"source":"osv","ecosystem":"Ubuntu:Pro:26.04:LTS","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.5.1-4ubuntu0.1~esm1"}]}],"versions":["2.2.0-3","2.5.1-4"]},{"source":"osv","ecosystem":"openSUSE:Tumbleweed","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.11.0-1.1"}]}]},{"source":"osv","ecosystem":"openSUSE:Leap 16.0","package":"beets","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.2.0-bp160.2.1"}]}]}],"products":[{"vendor":"beetbox","product":"beets"}],"references":[{"url":"https://github.com/beetbox/beets/security/advisories/GHSA-3gxm-wfjx-m847","tags":["x_refsource_CONFIRM","advisory","web","report"]},{"url":"https://github.com/beetbox/beets/releases/tag/v2.10.0","tags":["x_refsource_MISC","web"]},{"url":"https://lists.debian.org/debian-lts-announce/2026/06/msg00030.html","tags":["web"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-42052","tags":["advisory"]},{"url":"https://github.com/advisories/GHSA-3gxm-wfjx-m847","tags":["advisory"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/42xxx/CVE-2026-42052.json","tags":["advisory"]},{"url":"https://security-tracker.debian.org/tracker/CVE-2026-42052","tags":["advisory"]},{"url":"https://github.com/beetbox/beets","tags":["package"]},{"url":"https://pypi.org/project/beets","tags":["package"]},{"url":"https://ubuntu.com/security/CVE-2026-42052","tags":["report"]},{"url":"https://www.cve.org/CVERecord?id=CVE-2026-42052","tags":["report"]},{"url":"https://ubuntu.com/security/notices/USN-8747-1","tags":["advisory"]},{"url":"","tags":["advisory"]},{"url":"https://www.suse.com/security/cve/CVE-2026-42052","tags":["web"]},{"url":"https://bugzilla.suse.com/1263988","tags":["report"]}],"sources":{"cve":[{"id":"CVE-2026-42052","title":"beets is Vulnerable to XSS","description":"Beets is the media library management system. Prior to version 2.10.0, the bundled web UI uses Underscore template interpolation mode \u003c%= ... %\u003e for untrusted metadata fields. In this runtime, \u003c%= ... %\u003e is raw insertion and HTML escaping is only performed by \u003c%- ... %\u003e. Rendered output is then inserted with .html(...), allowing attacker-controlled markup to become active DOM. This issue has been patched in version 2.10.0.","status":"published","published":"2026-05-04T17:06:23.162Z","modified":"2026-06-23T21:33:30.608Z","cvss":[{"version":"4.0","score":6,"vector":"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","level":"medium","assessor":"cna"}],"cwes":["CWE-79"],"updated_at":"2026-11-02T13:40:12.486331Z"}],"euvd":[{"id":"EUVD-2026-27055","description":"Beets is the media library management system. Prior to version 2.10.0, the bundled web UI uses Underscore template interpolation mode \u003c%= ... %\u003e for untrusted metadata fields. In this runtime, \u003c%= ... %\u003e is raw insertion and HTML escaping is only performed by \u003c%- ... %\u003e. Rendered output is then inserted with .html(...), allowing attacker-controlled markup to become active DOM. This issue has been patched in version 2.10.0.","status":"published","published":"2026-05-04T17:06:23Z","modified":"2026-06-23T21:33:30Z","cvss":[{"version":"4.0","score":6,"vector":"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","level":"medium"}],"updated_at":"2026-11-02T18:20:31.123469Z"}],"ghsa":[{"id":"GHSA-3gxm-wfjx-m847","title":"beets has a Cross-site Scripting vulnerability","description":"During code logic analyis, an area that may lead to unintended behavior under specific conditions was discovered. \n\n## Overview\n- Verified Version: `80cd21554124da07d17a4f962c7d770a4f70d0f2`\n- Vulnerability Type: Stored XSS\n- Affected Location: `beetsplug/web/templates/index.html:42`\n- Trigger Scenario: Metadata fields such as `title`, `lyrics`, or `comments` are rendered with raw template interpolation and inserted into DOM via `.html(...)`.\n\n## Root Cause\nThe bundled web UI uses Underscore template interpolation mode `\u003c%= ... %\u003e` for untrusted metadata fields. In this runtime, `\u003c%= ... %\u003e` is raw insertion and HTML escaping is only performed by `\u003c%- ... %\u003e`. Rendered output is then inserted with `.html(...)`, allowing attacker-controlled markup to become active DOM.\n\n## Source-to-Sink Chain\n1. Source (attacker-controlled input)\n- Item metadata values (for example `title`, `lyrics`, `comments`) can contain attacker HTML payload.\n\n2. Data flow\n- Templates in `beetsplug/web/templates/index.html:42-46,87-91` render metadata with `\u003c%= ... %\u003e`.\n- Underscore runtime defines `\u003c%= ... %\u003e` as raw interpolation (`beetsplug/web/static/underscore.js:890-907`).\n\n3. Sink (security-sensitive action)\n- Frontend inserts rendered template output into DOM via `$(this.el).html(this.template(this.model.toJSON()));` in `beetsplug/web/static/beets.js:182,208,220`.\n\n## Exploitation Preconditions\n1. Victim opens the web UI page that renders attacker-controlled metadata.\n2. Metadata includes executable HTML/JS payload.\n\n## Risk\nStored payload executes in the web UI context and can perform actions available to that origin.\n\n## Impact\nAttacker can run arbitrary JavaScript in the victim browser, exfiltrate viewable data, and perform UI-driven actions as the victim session.\n\n## Remediation\n1. Replace raw interpolation `\u003c%= ... %\u003e` with escaped output `\u003c%- ... %\u003e` for untrusted fields.\n2. Avoid `.html(...)` for untrusted template output; use text-safe rendering.\n3. Sanitize metadata values on ingest and before rendering, including attribute contexts.","status":"published","published":"2026-04-29T18:29:00Z","modified":"2026-06-24T00:30:30Z","cvss":[{"version":"4.0","score":6,"vector":"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/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X","level":"medium"}],"cwes":["CWE-79"],"updated_at":"2026-11-02T14:40:32.744157Z"}],"nvd":[{"id":"CVE-2026-42052","description":"Beets is the media library management system. Prior to version 2.10.0, the bundled web UI uses Underscore template interpolation mode \u003c%= ... %\u003e for untrusted metadata fields. In this runtime, \u003c%= ... %\u003e is raw insertion and HTML escaping is only performed by \u003c%- ... %\u003e. Rendered output is then inserted with .html(...), allowing attacker-controlled markup to become active DOM. This issue has been patched in version 2.10.0.","status":"published","published":"2026-05-04T18:16:30.063Z","modified":"2026-10-26T19:10:00.163Z","cvss":[{"version":"4.0","score":6,"vector":"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/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X","level":"medium","assessor":"secondary"}],"cwes":["CWE-79"],"updated_at":"2026-11-02T14:12:17.022502Z"}],"osv":[{"id":"CVE-2026-42052","title":"beets is Vulnerable to XSS","description":"Beets is the media library management system. Prior to version 2.10.0, the bundled web UI uses Underscore template interpolation mode \u003c%= ... %\u003e for untrusted metadata fields. In this runtime, \u003c%= ... %\u003e is raw insertion and HTML escaping is only performed by \u003c%- ... %\u003e. Rendered output is then inserted with .html(...), allowing attacker-controlled markup to become active DOM. This issue has been patched in version 2.10.0.","status":"published","published":"2026-05-04T17:06:23.162Z","modified":"2026-10-28T02:30:42.436402049Z","cvss":[{"version":"4.0","score":6,"vector":"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","level":"medium"}],"cwes":["CWE-79"],"updated_at":"2026-11-02T15:45:04.117819Z"},{"id":"DEBIAN-CVE-2026-42052","description":"Beets is the media library management system. Prior to version 2.10.0, the bundled web UI uses Underscore template interpolation mode \u003c%= ... %\u003e for untrusted metadata fields. In this runtime, \u003c%= ... %\u003e is raw insertion and HTML escaping is only performed by \u003c%- ... %\u003e. Rendered output is then inserted with .html(...), allowing attacker-controlled markup to become active DOM. This issue has been patched in version 2.10.0.","status":"published","published":"2026-05-04T18:16:30.063Z","modified":"2026-10-27T09:47:42.972050651Z","cvss":[{"version":"4.0","score":6,"vector":"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/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X","level":"medium"}],"updated_at":"2026-11-02T15:45:54.892385Z"},{"id":"GHSA-3gxm-wfjx-m847","title":"beets has a Cross-site Scripting vulnerability","description":"During code logic analyis, an area that may lead to unintended behavior under specific conditions was discovered. \n\n## Overview\n- Verified Version: `80cd21554124da07d17a4f962c7d770a4f70d0f2`\n- Vulnerability Type: Stored XSS\n- Affected Location: `beetsplug/web/templates/index.html:42`\n- Trigger Scenario: Metadata fields such as `title`, `lyrics`, or `comments` are rendered with raw template interpolation and inserted into DOM via `.html(...)`.\n\n## Root Cause\nThe bundled web UI uses Underscore template interpolation mode `\u003c%= ... %\u003e` for untrusted metadata fields. In this runtime, `\u003c%= ... %\u003e` is raw insertion and HTML escaping is only performed by `\u003c%- ... %\u003e`. Rendered output is then inserted with `.html(...)`, allowing attacker-controlled markup to become active DOM.\n\n## Source-to-Sink Chain\n1. Source (attacker-controlled input)\n- Item metadata values (for example `title`, `lyrics`, `comments`) can contain attacker HTML payload.\n\n2. Data flow\n- Templates in `beetsplug/web/templates/index.html:42-46,87-91` render metadata with `\u003c%= ... %\u003e`.\n- Underscore runtime defines `\u003c%= ... %\u003e` as raw interpolation (`beetsplug/web/static/underscore.js:890-907`).\n\n3. Sink (security-sensitive action)\n- Frontend inserts rendered template output into DOM via `$(this.el).html(this.template(this.model.toJSON()));` in `beetsplug/web/static/beets.js:182,208,220`.\n\n## Exploitation Preconditions\n1. Victim opens the web UI page that renders attacker-controlled metadata.\n2. Metadata includes executable HTML/JS payload.\n\n## Risk\nStored payload executes in the web UI context and can perform actions available to that origin.\n\n## Impact\nAttacker can run arbitrary JavaScript in the victim browser, exfiltrate viewable data, and perform UI-driven actions as the victim session.\n\n## Remediation\n1. Replace raw interpolation `\u003c%= ... %\u003e` with escaped output `\u003c%- ... %\u003e` for untrusted fields.\n2. Avoid `.html(...)` for untrusted template output; use text-safe rendering.\n3. Sanitize metadata values on ingest and before rendering, including attribute contexts.","status":"published","published":"2026-04-29T18:29:00Z","modified":"2026-07-13T16:43:02.90324588Z","cvss":[{"version":"4.0","score":6,"vector":"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/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X","level":"medium"}],"cwes":["CWE-79"],"updated_at":"2026-11-02T15:46:35.747385Z"},{"id":"PYSEC-2026-2397","title":"beets has a Cross-site Scripting vulnerability","description":"During code logic analyis, an area that may lead to unintended behavior under specific conditions was discovered. \n\n## Overview\n- Verified Version: `80cd21554124da07d17a4f962c7d770a4f70d0f2`\n- Vulnerability Type: Stored XSS\n- Affected Location: `beetsplug/web/templates/index.html:42`\n- Trigger Scenario: Metadata fields such as `title`, `lyrics`, or `comments` are rendered with raw template interpolation and inserted into DOM via `.html(...)`.\n\n## Root Cause\nThe bundled web UI uses Underscore template interpolation mode `\u003c%= ... %\u003e` for untrusted metadata fields. In this runtime, `\u003c%= ... %\u003e` is raw insertion and HTML escaping is only performed by `\u003c%- ... %\u003e`. Rendered output is then inserted with `.html(...)`, allowing attacker-controlled markup to become active DOM.\n\n## Source-to-Sink Chain\n1. Source (attacker-controlled input)\n- Item metadata values (for example `title`, `lyrics`, `comments`) can contain attacker HTML payload.\n\n2. Data flow\n- Templates in `beetsplug/web/templates/index.html:42-46,87-91` render metadata with `\u003c%= ... %\u003e`.\n- Underscore runtime defines `\u003c%= ... %\u003e` as raw interpolation (`beetsplug/web/static/underscore.js:890-907`).\n\n3. Sink (security-sensitive action)\n- Frontend inserts rendered template output into DOM via `$(this.el).html(this.template(this.model.toJSON()));` in `beetsplug/web/static/beets.js:182,208,220`.\n\n## Exploitation Preconditions\n1. Victim opens the web UI page that renders attacker-controlled metadata.\n2. Metadata includes executable HTML/JS payload.\n\n## Risk\nStored payload executes in the web UI context and can perform actions available to that origin.\n\n## Impact\nAttacker can run arbitrary JavaScript in the victim browser, exfiltrate viewable data, and perform UI-driven actions as the victim session.\n\n## Remediation\n1. Replace raw interpolation `\u003c%= ... %\u003e` with escaped output `\u003c%- ... %\u003e` for untrusted fields.\n2. Avoid `.html(...)` for untrusted template output; use text-safe rendering.\n3. Sanitize metadata values on ingest and before rendering, including attribute contexts.","status":"published","published":"2026-07-13T15:02:54.913237Z","modified":"2026-07-13T16:31:38.628627327Z","cvss":[{"version":"4.0","score":6,"vector":"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/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X","level":"medium"}],"updated_at":"2026-11-02T15:52:55.961245Z"},{"id":"UBUNTU-CVE-2026-42052","description":"Beets is the media library management system. Prior to version 2.10.0, the bundled web UI uses Underscore template interpolation mode \u003c%= ... %\u003e for untrusted metadata fields. In this runtime, \u003c%= ... %\u003e is raw insertion and HTML escaping is only performed by \u003c%- ... %\u003e. Rendered output is then inserted with .html(...), allowing attacker-controlled markup to become active DOM. This issue has been patched in version 2.10.0.","status":"published","published":"2026-05-04T18:16:00Z","modified":"2026-09-10T21:30:17.138152777Z","cvss":[{"version":"4.0","score":6,"vector":"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","level":"medium"}],"updated_at":"2026-11-02T16:56:18.393417Z"},{"id":"openSUSE-SU-2026:10865-1","title":"beets-2.11.0-1.1 on GA media","description":"These are all security issues fixed in the beets-2.11.0-1.1 package on the GA media of openSUSE Tumbleweed.","status":"published","published":"2026-05-27T00:00:00Z","modified":"2026-05-28T08:15:07.357942619Z","updated_at":"2026-11-02T16:58:38.95195Z"},{"id":"openSUSE-SU-2026:21383-1","title":"Security update for beets","description":"This update for beets fixes the following issues:\n\nChanges in beets:\n\n- CVE-2026-42052: Prior to version 2.10.0, the bundled web UI uses Underscore\n  template interpolation mode \u003c%= ... %\u003e for untrusted metadata fields. (boo#1263988)\n","status":"published","published":"2026-07-20T14:36:24Z","modified":"2026-07-22T18:25:11.723677795Z","updated_at":"2026-11-02T16:58:41.885092Z"},{"id":"USN-8747-1","title":"beets vulnerability","description":"It was discovered that Beets incorrectly escaped untrusted media metadata\nin its web interface. An attacker could possibly use this issue to inject\narbitrary HTML or execute arbitrary JavaScript code in a user's browser.","status":"published","published":"2026-09-10T15:56:46Z","modified":"2026-09-10T21:42:34.946020692Z","updated_at":"2026-11-02T16:58:26.907654Z"}]}}
