{"id":"CVE-2020-26298","published":"2021-01-11T00:00:00Z","modified":"2025-02-13T16:27:42Z","title":"Injection in Redcarpet","vendor":"vmg","product":"redcarpet","tier":"tail","description":{"text":"Redcarpet is a Ruby library for Markdown processing. In Redcarpet before version 3.5.1, there is an injection vulnerability which can enable a cross-site scripting attack. In affected versions no HTML escaping was being performed when processing quotes. This applies even when the `:escape_html` option was being used. This is fixed in version 3.5.1 by the referenced commit.","provenance":"source","from":"CVE.org"},"cvss":{"score":6.8,"severity":"MEDIUM","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:N/I:H/A:N","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.01589,"percentile":0.76236,"provenance":"source"},"cwes":[{"id":"CWE-74","name":"Improper Neutralization of Special Elements in Output Used by a Downstream Component"},{"id":"CWE-79","name":"Improper Neutralization of Input During Web Page Generation"}],"references":[{"url":"https://github.com/advisories/GHSA-q3wr-qw3g-3p4h","tags":[]},{"url":"https://github.com/vmg/redcarpet/commit/a699c82292b17c8e6a62e1914d5eccc252272793","tags":[]},{"url":"https://rubygems.org/gems/redcarpet","tags":[]},{"url":"https://github.com/vmg/redcarpet/blob/master/CHANGELOG.md#version-351-security","tags":[]},{"url":"https://lists.debian.org/debian-lts-announce/2021/01/msg00014.html","tags":["mailing-list"]},{"url":"https://www.debian.org/security/2021/dsa-4831","tags":["vendor-advisory"]},{"url":"https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/FNO4ZZUPGAEUXKQL4G2HRIH7CUZKPCT6/","tags":["vendor-advisory"]},{"url":"https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/BFMYDIONVWATY7EB6EARDVXT47AYCRNM/","tags":["vendor-advisory"]},{"url":"https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/PXNNWHHAPREDM3XJDACYRTK7DBMUONBI/","tags":["vendor-advisory"]}],"priority":{"score":20.0,"factors":[{"name":"EPSS percentile","points":15.25},{"name":"CVSS severity","points":4.76}]},"vendorSlug":"vmg","affectedVersions":[{"vendor":"vmg","product":"redcarpet","versions":["< 3.5.1"]}],"affected":[{"ecosystem":"RubyGems","package":"redcarpet","vulnerableRanges":["<3.5.1"],"patched":["3.5.1"],"from":["GHSA-q3wr-qw3g-3p4h"],"provenance":"source"}],"summary":{"text":"The flaw is an injection vulnerability in the quote-processing code of Redcarpet, a Ruby library for Markdown processing, where HTML output is not escaped, including when the :escape_html option is set. An attacker who can get Markdown content processed by an affected version can inject script that leads to cross-site scripting, and this requires network access, low privileges, and a user to interact with the crafted content.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T07:15:51Z"},"euvd":{"id":"EUVD-2021-0511","exploited":false,"provenance":"source"},"lineage":{"familyId":"fam-vmg-redcarpet-cve-2015-5147","parents":[{"from":"CVE-2015-5147","to":"CVE-2020-26298","relation":"related","confidence":"medium","kind":"lineage","evidence":[{"kind":"same-code","provenance":"machine","files":["ext/redcarpet/html.c"],"commits":["https://github.com/vmg/redcarpet/commit/2cee777c1e5babe8a1e2683d31ea75cc4afe55fb","https://github.com/vmg/redcarpet/commit/a699c82292b17c8e6a62e1914d5eccc252272793"],"basis":"shared function","functions":["buf"]},{"kind":"similar","provenance":"machine","score":0.38,"basis":"same package + description similarity"}]}]}}