Lemmy: Stored XSS via markdown image alt-text in lemmy-ui html5-embed
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- Passive
- Attack complexity
- Low
- Attack requirements
- None
- Impact type
- Cross-site scripting
- Confidentiality · integrity · availability
- None · None · None
- Fix status
- Fixed
Attack profile from CVSS 4.0 · CNA. Fix status from CNA. Impact type from CWE-79.
Summary
Lemmy is a link aggregator and forum for the fediverse. Prior to lemmy-ui 0.19.19-beta.1, LemmyNet/lemmy-ui renders Markdown in src/shared/markdown.ts for post bodies, comment bodies, private messages, and community and site sidebars through mdToHtml, which returns a raw __html object that Inferno injects without a sanitizer pass. setupMarkdown configures html as false but registers [email protected] with useImageSyntax enabled, so an image targeting video media becomes a video element whose fallback incorporates the image alt text through unescaped string replacement. The html setting does not apply to plugin-generated output, allowing crafted alt text to reach the DOM as live HTML in contexts that do not use mdToHtmlNoImages. An approved member or a remote federated instance can store such content, and a viewer who renders it may execute JavaScript in the lemmy-ui origin, exposing the viewer's session and authenticated actions. The advisory notes that Content Security Policy prevents the described exploit in production, but also states that the tested default self-hosted deployment serves no Content-Security-Policy. This issue is fixed in lemmy-ui version 0.19.19-beta.1.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- Poc
- Automatable
- No
- Technical impact
- Partial
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
Remediation
- Fix · CNA lemmy (LemmyNet) Fixed in 0.19.19-beta.1
Timeline
- 2026-10-02 Threatist record created from CVE-2026-54743
References
More LemmyNet vulnerabilities
- TI-2026-23295 Lemmy: Unauthenticated SSRF via file_type query parameter injection in image endpoint CVSS 4.0HIGH 7.7
- TI-2026-26073 Lemmy's Activitypub-Federation has SSRF via 0.0.0.0 bypass in activitypub-federation-rust v4_is_invalid() CVSS 3.1MEDIUM 6.5
- TI-2026-39552 Lemmy: Lower-ranked federated moderator can remove higher-ranked moderators CVSS 3.1MEDIUM 6.5
- TI-2026-30504 Lemmy: SSRF and internal image disclosure in post link metadata via unvalidated og:image CVSS 3.1MEDIUM 6.5
- TI-2026-39553 Lemmy: Blocked users can edit private messages sent before the block CVSS 4.0MEDIUM 5.3
- TI-2026-39554 Lemmy: `CollectionAdd::Featured` does not check the post is in the community CVSS 4.0MEDIUM 5.1
Sources
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences