# CVE-2021-46872: An issue was discovered in Nim before 1.6.2.

- Severity: Medium 6.1 (CVSS:3.1, scored by CISA-ADP) `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N`
- 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): 0.58%, higher than 49% of CVEs (2026-12-01)
- Published: 2023-01-13T00:00:00.000Z
- Modified: 2026-06-17T04:15:41.963Z
- Weaknesses: CWE-79
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: mitre

## Description

An issue was discovered in Nim before 1.6.2. The RST module of the Nim language stdlib, as used in NimForum and other products, permits the javascript: URI scheme and thus can lead to XSS in some applications. (Nim versions 1.6.2 and later are fixed; there may be backports of the fix to some earlier versions. NimForum 2.2.0 is fixed.)

(As written by CVE List.)

## Affected

- Unspecified product: n/a
- nim-lang nim: before 1.6.2
- nim-lang nimforum: before 2.2.0

## Every score

- CISA-ADP: CVSS:3.1 6.1 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N`
- NVD: CVSS:3.1 6.1 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N`

## References

- <https://github.com/nim-lang/nimforum> (third-party-advisory)
- <https://forum.nim-lang.org/t/8852> (issue-tracking, vendor-advisory)
- <https://github.com/nim-lang/Nim/pull/19134> (patch, third-party-advisory)
- <https://github.com/nim-lang/Nim/compare/v1.6.0...v1.6.2> (third-party-advisory)
- <https://github.com/nim-lang/Nim/commit/46275126b89218e64844eee169e8ced05dd0e2d7> (patch, third-party-advisory)

## Sources

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

---

Page: https://cve.day/CVE-2021-46872 · Whole record: https://cve.day/CVE-2021-46872.json · Rebuilt by cve.day 2026-11-25T22:58:08.123Z
