# CVE-2026-54681: DiscordChatExporter: HTML attribute injection via unescaped emoji name in HTML export

- Severity: Medium 4.1 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:L/AC:H/PR:N/UI:R/S:C/C:L/I:L/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.13%, higher than 2% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2026-08-21T18:41:45.861Z
- Modified: 2026-10-14T19:10:00.297Z
- Weaknesses: CWE-79
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact partial
- Assigned by: GitHub_M

## Description

DiscordChatExporter saves Discord chat logs to a file. Prior to 2.47.2, the VisitEmojiAsync method in DiscordChatExporter.Core/Exporting/HtmlMarkdownVisitor.cs interpolates emoji.Name into the alt attribute and emoji.Code into the title attribute without HTML entity encoding. This affects HTML exports regardless of the markdown setting. Discord's current custom emoji name validation normally excludes attribute-breaking characters, but tampered offline input, a relaxed upstream validation rule, or another future metadata source can inject an HTML attribute and execute script when a user opens the export. This issue is fixed in version 2.47.2.

(As written by CVE List.)

## Affected

- Tyrrrz DiscordChatExporter: < 2.47.2

## References

- <https://github.com/Tyrrrz/DiscordChatExporter/security/advisories/GHSA-r7qm-wg9p-pjfc> (exploit)
- <https://github.com/Tyrrrz/DiscordChatExporter/pull/1544>
- <https://github.com/Tyrrrz/DiscordChatExporter/commit/f4d1e630f7f27120c3be4320d92cc8b932e78688>
- <https://github.com/Tyrrrz/DiscordChatExporter/releases/tag/2.47.2>

## Sources

- CVE List: [CVE-2026-54681](https://www.cve.org/CVERecord?id=CVE-2026-54681), CVE Terms of Use, modified 2026-08-21
- NVD: [CVE-2026-54681](https://nvd.nist.gov/vuln/detail/CVE-2026-54681), Public domain, modified 2026-10-14

---

Page: https://cve.day/CVE-2026-54681 · Whole record: https://cve.day/CVE-2026-54681.json · Rebuilt by cve.day 2026-11-25T22:59:34.813Z
