{"schema_version":"1.7.5","id":"GHSA-q3wr-qw3g-3p4h","published":"2021-01-11T19:06:10Z","modified":"2026-07-08T05:59:45.900047476Z","aliases":["CVE-2020-26298"],"summary":"Injection/XSS in Redcarpet","details":"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.","affected":[{"package":{"name":"redcarpet","ecosystem":"RubyGems","purl":"pkg:gem/redcarpet"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"3.5.1"}]}],"versions":["1.0.0","1.0.1","1.1.0","1.1.1","1.10.0","1.10.1","1.11.0","1.11.1","1.11.2","1.11.3","1.11.4","1.12.0","1.12.1","1.12.2","1.13.0","1.13.1","1.13.2","1.14.0","1.14.1","1.14.2","1.15.0","1.15.1","1.15.2","1.16.0","1.17.0","1.17.1","1.17.2","1.2.0","1.2.1","1.2.2","1.3.0","1.3.1","1.3.2","1.3.3","1.5.0","1.5.1","1.5.2","1.5.3","1.6.0","1.7.0","1.7.1","1.8.0","1.8.1","1.8.2","1.9.0","2.0.0","2.0.0b","2.0.0b3","2.0.0b4","2.0.0b5","2.0.1","2.1.0","2.1.1","2.2.0","2.2.1","2.2.2","2.3.0","3.0.0","3.1.0","3.1.1","3.1.2","3.2.0","3.2.1","3.2.2","3.2.3","3.3.0","3.3.1","3.3.2","3.3.3","3.3.4","3.4.0","3.5.0"],"database_specific":{"source":"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2021/01/GHSA-q3wr-qw3g-3p4h/GHSA-q3wr-qw3g-3p4h.json"}}],"references":[{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2020-26298"},{"type":"WEB","url":"https://github.com/vmg/redcarpet/commit/a699c82292b17c8e6a62e1914d5eccc252272793"},{"type":"ADVISORY","url":"https://github.com/advisories/GHSA-q3wr-qw3g-3p4h"},{"type":"WEB","url":"https://github.com/rubysec/ruby-advisory-db/blob/master/gems/redcarpet/CVE-2020-26298.yml"},{"type":"PACKAGE","url":"https://github.com/vmg/redcarpet"},{"type":"WEB","url":"https://github.com/vmg/redcarpet/blob/master/CHANGELOG.md#version-351-security"},{"type":"WEB","url":"https://lists.debian.org/debian-lts-announce/2021/01/msg00014.html"},{"type":"WEB","url":"https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/BFMYDIONVWATY7EB6EARDVXT47AYCRNM"},{"type":"WEB","url":"https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/FNO4ZZUPGAEUXKQL4G2HRIH7CUZKPCT6"},{"type":"WEB","url":"https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/PXNNWHHAPREDM3XJDACYRTK7DBMUONBI"},{"type":"WEB","url":"https://rubygems.org/gems/redcarpet"},{"type":"WEB","url":"https://www.debian.org/security/2021/dsa-4831"}],"database_specific":{"cwe_ids":["CWE-74","CWE-79"],"github_reviewed":true,"github_reviewed_at":"2021-01-11T19:05:42Z","nvd_published_at":"2021-01-11T19:15:00Z","severity":"MODERATE"},"severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:N/I:H/A:N"}]}