CVE-2026-27166

Discourse vulnerable to HTML injection via prohibited iframe URLs

State
Published
Severity
4.1 Medium
Published
Mar 19, 2026
Updated
Mar 21, 2026
Reserved
Feb 18, 2026

Read the record on cve.org

Description

Discourse is an open source discussion platform. Prior to versions 2026.3.0-latest.1, 2026.2.1 and 2026.1.2, insufficient cleanup in the default Codepen allowed iframes value allows an attacker to trick a user into changing the URL of the main page. This issue has been fixed in versions 2026.3.0-latest.1, 2026.2.1 and 2026.1.2. To workaround this issue, remove Codepen from the list of allowed iframes.

Scores

CVSSScoreVectorSource
3.14.1 MediumCVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:N/I:L/A:NGitHub_M

Weaknesses

  • CWE-80 Improper Neutralization of Script-Related HTML Tags in a Web Page (Basic XSS)

Affected Products

ProductVersions
discoursediscourse
  • < 2026.3.0-latest.1Affected
  • >= 2026.2.0-latest, < 2026.2.1Affected
  • >= 2026.1.0-latest, < 2026.1.2Affected

References

Every record here comes from the CVE Program’s CVE List. © 1999–2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.