{"id":"CVE-2023-30538","aliases":["CVE-2023-30538","BIT-DISCOURSE-2023-30538","GHSA-w5mv-4pjf-xj43"],"related":[],"kind":"vulnerability","state":"published","title":"Stored Cross-site Scripting via improper sanitization of svg files in Discourse","summary":"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).","summarySource":"cvelist","descriptions":[{"lang":"en","text":"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).","source":"cvelist"}],"published":"2023-04-18T21:25:58.848Z","modified":"2026-09-08T08:46:11.389Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N","score":5.4,"rating":"MEDIUM"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N","score":5.4,"rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N","score":5.4,"rating":"MEDIUM"},{"scorer":"Bitnami Vulnerability Database","scheme":"rating","rating":"MEDIUM"}],"cwes":["CWE-79"],"affected":[{"ranges":[{"version":"stable: < 3.0.3","status":"affected"},{"version":"beta: < 3.1.0.beta4","status":"affected"}],"vendor":"discourse","product":"discourse","source":"cvelist"},{"ranges":[{"status":"affected","lastAffected":"3.0.2"},{"status":"affected","fixed":"3.1.0"},{"status":"affected","version":"3.1.0"},{"status":"affected","version":"3.1.0"},{"status":"affected","version":"3.1.0"}],"vendor":"discourse","product":"discourse","cpe":"cpe:2.3:a:discourse:discourse:*:*:*:*:stable:*:*:*","source":"nvd"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"3.1.0"},{"type":"semver","introduced":"0","status":"affected","lastAffected":"3.0.2"}],"ecosystem":"Bitnami","package":"discourse","purl":"pkg:bitnami/discourse","source":"bitnami"}],"references":[{"url":"https://github.com/discourse/discourse/security/advisories/GHSA-w5mv-4pjf-xj43","tags":["advisory","mitigation","third-party-advisory","x-refsource-confirm","x-transferred"],"sources":["cvelist","nvd","bitnami"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2023-30538","tags":["web"],"sources":["bitnami"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"total","date":"2025-02-06T16:33:06.431Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2023-30538","url":"https://www.cve.org/CVERecord?id=CVE-2023-30538","licence":"CVE Terms of Use","modified":"2025-02-06T16:33:27.722Z"},{"source":"nvd","name":"NVD","id":"CVE-2023-30538","url":"https://nvd.nist.gov/vuln/detail/CVE-2023-30538","licence":"Public domain","modified":"2026-06-17T05:54:58.467Z"},{"source":"bitnami","name":"Bitnami Vulnerability Database","id":"BIT-DISCOURSE-2023-30538","url":"https://osv.dev/vulnerability/BIT-DISCOURSE-2023-30538","licence":"Apache-2.0","modified":"2026-09-08T08:46:11.389Z"}],"updatedAt":"2026-11-25T22:58:23.624Z","epss":{"score":0.00364,"percentile":0.32238,"date":"2026-12-01T12:00:22.000Z"}}