CVE-2023-30538

Stored Cross-site Scripting via improper sanitization of svg files in Discourse

MEDIUM
5.4
CVSS Score
Published: April 18, 2023 at 09:25 PM UTC
Updated: June 17, 2026 at 05:54 AM UTC
1 product affected across 1 vendorDiscourse

Using discourse by discourse?

Get instant alerts when new vulnerabilities affect discourse - before attackers find them.

Real-time alertsTrack your software stackFree plan available
Severity
MEDIUM5.4
Exploit prediction
EPSS 0.4%
SSVC
No known exploit

Description

Discourse is an open source platform for community discussion. Due to the improper sanitization of SVG files, an attacker can execute arbitrary JavaScript on the users’ browsers by uploading a crafted SVG file. This issue is patched in the latest stable and tests-passed versions of Discourse. Users are advised to upgrade. For users unable to upgrade there are two possible workarounds: enable CDN handing of uploads (and ensure the CDN sanitizes SVG files) or disable SVG file uploads by ensuring that the `authorized extensions` site setting does not include `svg` (or reset that setting to the default, by default Discourse doesn't enable SVG uploads by users).

Affected

Our own answer: ranges merged, affected separated from platform-only, with confidence and review flags.

v ≤ 3.0.2v < 3.0.3v < 3.1.0v < 3.1.0.beta43.1.0 beta13.1.0 beta23.1.0 beta3
Affected range stops below 3.0.3, so it looks safe — our inference, not a vendor statement
Affected range stops below 3.1.0, so it looks safe — our inference, not a vendor statement
Affected range stops below 3.1.0.beta4, so it looks safe — our inference, not a vendor statement

Remediation

No guide yet

No remediation guidance has been written for this CVE yet. What the record does show:

References (1)

SSVC — Action Prioritization

SSVCNo known exploitNot automatableTotal impact

SSVC signals action urgency (what to patch first), separate from CVSS which measures severity.

CVSS

5.4MEDIUMGitHub_M
Attack Vector
NETWORK
Complexity
LOW
Privileges
NONE
User Interaction
REQUIRED
Scope
UNCHANGED
Confidentiality
LOW
Integrity
LOW
Availability
NONE
Vector?

Quick Info

StatusMODIFIED
CWE
CWE-79

Get alerted

Stop reading CVE feeds looking for your own stack

Track the products you run and VulnTracker tells you when a new CVE affects them — with what is known about fixing it, and nothing about the rest.

Free plan, no card