# CVE-2021-27671: Cross site scripting in comrak

- Severity: Medium 6.1 (CVSS:3.1, scored by NVD) `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.69%, higher than 54% of CVEs (2026-12-01)
- Published: 2021-02-21T12:00:00.000Z
- Modified: 2026-06-17T03:45:19.750Z
- Also known as: GHSA-xmr7-v725-2jjr, RUSTSEC-2021-0026
- Weaknesses: CWE-79
- Assigned by: mitre

## Description

An issue was discovered in the comrak crate before 0.9.1 for Rust. XSS can occur because the protection mechanism for data: and javascript: URIs is case-sensitive, allowing (for example) Data: to be used in an attack.

(As written by CVE List.)

## Affected

- Unspecified product: n/a
- comrak (crates.io): before 0.9.1; from 0.0.0-0 before 0.9.1
- comrak_project comrak: before 0.9.1

## Every score

- GitHub: 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`
- RustSec Advisory Database: 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`
- NVD: CVSS:2.0 4.3 Medium `AV:N/AC:M/Au:N/C:N/I:P/A:N`

## References

- <https://rustsec.org/advisories/RUSTSEC-2021-0026.html> (advisory, third-party-advisory, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2021-27671> (advisory)
- <https://github.com/kivikakk/comrak/commit/b3efbb6e427bcd33bb14db45753ad4fd98e0f5bf> (web)
- <https://github.com/kivikakk/comrak> (package)
- <https://github.com/kivikakk/comrak/releases/tag/0.9.1> (web)
- <https://crates.io/crates/comrak> (package)

## Sources

- CVE List: [CVE-2021-27671](https://www.cve.org/CVERecord?id=CVE-2021-27671), CVE Terms of Use, modified 2024-08-03
- GitHub Advisory Database: [GHSA-xmr7-v725-2jjr](https://github.com/advisories/GHSA-xmr7-v725-2jjr), CC-BY-4.0, modified 2023-11-08
- RustSec Advisory Database: [RUSTSEC-2021-0026](https://rustsec.org/advisories/RUSTSEC-2021-0026.html), CC0-1.0, modified 2023-11-08
- NVD: [CVE-2021-27671](https://nvd.nist.gov/vuln/detail/CVE-2021-27671), Public domain, modified 2026-06-17

---

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