Skip to content
OpenAdvisories
High GHSA-9r27-994c-4xch

discord-html not escaping HTML code blocks when lacking a language identifier

Published Feb 24, 2020 · Updated Feb 21, 2020 · Assigned by GHSA

Description

### Impact
Any website using discord-markdown with user-generated markdown is vulnerable to having code injected into the page where the markdown is displayed.

### Patches
This has been patched in version 2.3.1

### Workarounds
Escape the characters `<>&` before sending plain code blocks to discord-markdown.

### References
https://github.com/brussell98/discord-markdown/issues/13

Affected packages

EcosystemPackageAffectedFixedRecord
npm discord-markdown < 2.3.1 2.3.1 GHSA-9r27-994c-4xch

References