What’s Vulnerable › Vulnerabilities
CVE-2023-29196: HTML injection via topic embedding in Discourse
- Severity: medium (CVSS 6.1 v3.1)
- Exploited in the wild: not listed in CISA KEV
- EPSS: 0.3% probability of exploitation in the next 30 days
- Public exploit or detection template: none known
- Published: 2023-04-18 · updated 2026-06-17
- Weakness: CWE-79
Description
Discourse is an open source platform for community discussion. This vulnerability is not exploitable on the default install of Discourse. A custom feature must be enabled for it to work at all, and the attacker’s payload must pass the CSP to be executed. However, if an attacker succeeds in embedding Javascript that does pass the CSP, it could result in session hijacking for any users that view the attacker’s post. The vulnerability is patched in the latest tests-passed, beta and stable branches. Users are advised to upgrade. Users unable to upgrade should enable and/or restore your site's CSP to the default one provided with Discourse. Remove any embed-able hosts configured.
Affected products
- discourse: before 3.0.3; before 3.1.0; 3.1.0-beta1, 3.1.0-beta2, 3.1.0-beta3 — fixed in 3.0.3, 3.1.0
How to fix
Upgrade to a fixed version: discourse 3.0.3, 3.1.0. Check the vendor advisory for mitigations.
References
- https://github.com/discourse/discourse/security/advisories/GHSA-986p-4x8q-8f48
- https://github.com/discourse/discourse/security/advisories/GHSA-986p-4x8q-8f48
Get alerted when CVE-2023-29196 or the next vulnerability affects your stack