# CVE-2022-46162: Discourse BBCode plugin vulnerable to arbitrary CSS injection

- Severity: High 8.8 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 1.34%, higher than 72% of CVEs (2026-12-02)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2022-11-30T00:00:00.000Z
- Modified: 2026-06-17T05:11:20.207Z
- Weaknesses: CWE-74, CWE-79
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact total
- Assigned by: GitHub_M

## Description

discourse-bbcode is the official BBCode plugin for Discourse. Prior to commit 91478f5, CSS injection can occur when rendering content generated with the discourse-bccode plugin. This vulnerability only affects sites which have the discourse-bbcode plugin installed and enabled. This issue is patched in commit 91478f5. As a workaround, ensure that the Content Security Policy is enabled and monitor any posts that contain bbcode.

(As written by CVE List.)

## Affected

- discourse discourse-bbcode: < 91478f5cfecdcc43cf85b997168a8ecfd0f8df90
- discourse discourse_bbcode: before 2022-11-30

## Every score

- GitHub_M: CVSS:3.1 8.8 High `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:3.1 9.8 Critical `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`

## References

- <https://github.com/discourse/discourse-bbcode/security/advisories/GHSA-8c87-xpqv-c7mp> (exploit, vendor-advisory)
- <https://github.com/discourse/discourse-bbcode/commit/91478f5cfecdcc43cf85b997168a8ecfd0f8df90> (patch, third-party-advisory)

## Sources

- CVE List: [CVE-2022-46162](https://www.cve.org/CVERecord?id=CVE-2022-46162), CVE Terms of Use, modified 2025-04-22
- NVD: [CVE-2022-46162](https://nvd.nist.gov/vuln/detail/CVE-2022-46162), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2022-46162 · Whole record: https://cve.day/CVE-2022-46162.json · Rebuilt by cve.day 2026-11-25T22:58:17.149Z
