CVE-2026-91119

Discourse: Encode action_code_who in mention URLs

Published Sep 24, 2026 CVSS 3.1 · 6.4 Medium EPSS < 1% KEV · Not listed
Description
Discourse is an open-source discussion platform. Prior to 2026.1.8, 2026.6.3, 2026.7.2, and 2026.8.0, the topic small-action and nested-activity-log components interpolated the free-form action_code_who value into mention-link href attributes without URL encoding. A quote-bearing display name could terminate the intended URL attribute and inject attacker-controlled elements into the trusted rendered markup. Although the visible mention text was escaped, the unencoded path component allowed stored HTML injection when another user viewed the affected topic action or activity log. This issue is fixed in versions 2026.1.8, 2026.6.3, 2026.7.2, and 2026.8.0.

Analysis

AI-generated

Technical impact

The vulnerability is a classic CWE-79 (Cross‑Site Scripting) flaw in the Discourse platform's URL construction for user mentions. The system embeds the action_code_who value directly into the href attribute of a mention link without URL encoding. The visible mention text is escaped, but because the path component is unencoded, an attacker can provide a quote-bearing display name that terminates the URL. This allows the injection of attacker-controlled HTML or script fragments into the trusted rendered markup presented to other users. The stored injection can trigger arbitrary client-side code when any user views the affected topic action or activity log.

Affected Systems

Discourse, the open‑source discussion platform, is affected. Versions prior to 2026.1.8, 2026.6.3, 2026.7.2, and 2026.8.0 contain the vulnerability. The fix is included in those four releases and later versions.

Risk and Exploitability

The CVSS score of 6.4 indicates a moderate severity. An attacker can exploit the flaw by creating or altering a user display name that contains a quote character to terminate the URL attribute. Because the injected content is stored in the activity log or topic action, the malicious markup will be served to every user who views the post, enabling cross‑site scripting attacks. The EPSS score is not available, and the vulnerability is not listed in CISA’s KEV catalog, implying there is no publicly known exploit yet but the potential remains high for systems exposed to untrusted users who can create forum accounts or posts. Due to the stored nature of the injection, protection against this attack requires remediation rather than defenses at runtime.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade to Discourse version 2026.1.8 or later, including 2026.6.3, 2026.7.2, and 2026.8.0, which encode the action_code_who value in mention URLs.
  • If an upgrade cannot be applied immediately, enforce a stricter character whitelist on user display name fields or strip quote characters to prevent URL termination in the rendered markup.
  • Implement or tighten a Content Security Policy that disallows inline script execution on the forum page as a layer of defense while awaiting the official patch.
  • Audit and revoke any accounts that have created malicious display names or posts containing injected URLs prior to applying the patch.

Generated by OpenCVE AI on September 25, 2026 at 07:12 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
First Time appeared Discourse
Discourse discourse
Vendors & Products Discourse
Discourse discourse
Type Values Removed Values Added
Description Discourse is an open-source discussion platform. Prior to 2026.1.8, 2026.6.3, 2026.7.2, and 2026.8.0, the topic small-action and nested-activity-log components interpolated the free-form action_code_who value into mention-link href attributes without URL encoding. A quote-bearing display name could terminate the intended URL attribute and inject attacker-controlled elements into the trusted rendered markup. Although the visible mention text was escaped, the unencoded path component allowed stored HTML injection when another user viewed the affected topic action or activity log. This issue is fixed in versions 2026.1.8, 2026.6.3, 2026.7.2, and 2026.8.0.
Title Discourse: Encode action_code_who in mention URLs
Weaknesses CWE-79
References
Metrics cvssV3_1

{'score': 6.4, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:L/A:N'}

Weaknesses
  • CWE-79

    Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Sep 28, 2026, 3:00 PM
Reserved
Sep 14, 2026, 7:36 PM
Status
Deferred
Published
Sep 24, 2026, 6:19 PM
Modified
Sep 28, 2026, 4:17 PM