
Cloud Vulnerability DB
A community-led vulnerabilities database
CVE-2026-27570 is a stored Cross-Site Scripting (XSS) vulnerability in Discourse, an open-source discussion platform, affecting the SharedAiConversation model's onebox method. The vulnerability arises because conversation titles and usernames are rendered directly into HTML without proper sanitization. Affected versions include Discourse 2026.1.0 through 2026.1.1, 2026.2.0, and 2026.3.0-latest (unpatched). It was disclosed on March 19, 2026, with patches released shortly after. The CVSS v3.1 base score is 6.1 (Medium) and the CVSS v4.0 base score is 5.1 (Medium) (GitHub Advisory, Feedly).
The root cause is CWE-79 (Improper Neutralization of Input During Web Page Generation — Cross-Site Scripting). Specifically, the onebox method in plugins/discourse-ai/app/models/shared_ai_conversation.rb interpolated the conversation title and post username directly into an HTML heredoc string without escaping, allowing arbitrary HTML/JavaScript injection. An attacker with low privileges (sufficient to create or share an AI conversation) can craft a malicious conversation title containing a payload such as <script>alert("x")</script> or an <img src=x onerror=...> tag; when another user views the shared conversation onebox, the script executes in their browser. The fix applies ERB::Util.html_escape() to both the title and username fields before HTML interpolation (GitHub Commit, GitHub Advisory).
Successful exploitation allows an attacker to inject and persistently store malicious JavaScript that executes in the browsers of other users who view the compromised shared AI conversation. This can lead to session hijacking, credential theft, unauthorized actions performed on behalf of victims, and exposure of sensitive information accessible within the victim's Discourse session. Availability is not impacted, but both confidentiality and integrity are affected with a changed scope, meaning the attack can impact users beyond the attacker's own session (GitHub Advisory, Feedly).
There is no public proof-of-concept exploit code and no evidence of in-the-wild exploitation at this time. The EPSS score is approximately 0.047%, indicating a low probability of exploitation in the near term. The vulnerability is not listed in the CISA Known Exploited Vulnerabilities (KEV) catalog. Exploitation requires the attacker to have low-level privileges (ability to create or share AI conversations) and requires a victim to interact with the malicious shared conversation (GitHub Advisory, Feedly).
ai_bot_public_sharing_allowed_groups).title</a><script>alert("x")</script> or a username containing user"><img src=x onerror=alert(1)>./shared-ai-conversations/...) by multiple users in a short timeframe; server-side rendering of onebox content containing unescaped HTML special characters (<, >, ") in conversation titles.Upgrade Discourse to one of the patched versions: 2026.1.2 (for 2026.1.x branch), 2026.2.1 (for 2026.2.x branch), or 2026.3.0-latest.1 (for the latest branch). As an immediate workaround prior to patching, administrators should restrict the ai_bot_public_sharing_allowed_groups site setting to limit which user groups can create or share AI conversations, reducing the attack surface. The patch applies ERB::Util.html_escape() to both the conversation title and post usernames before HTML rendering in the onebox method (GitHub Advisory, GitHub Commit).
The vulnerability was reported by security researcher nlgbao1340 and patched by Discourse maintainers romanrizzi and davidtaylorhq. No significant broader media coverage or notable community commentary beyond the GitHub security advisory has been identified at this time (GitHub Advisory).
Source: This report was generated using AI
Free Vulnerability Assessment
Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.
Get a personalized demo
"Best User Experience I have ever seen, provides full visibility to cloud workloads."
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
"We know that if Wiz identifies something as critical, it actually is."