Injection in Redcarpet
Key facts
- Attack vector
- Network
- Privileges required
- Low
- User interaction
- Required
- Attack complexity
- Low
- Impact type
- Cross-site scripting
- Confidentiality · integrity · availability
- None · High · None
- Fix status
- Partial Red Hat: 1 without a fix
Attack profile from CVSS 3.1 · CNA. Fix status from CNA, GitHub and Red Hat. Impact type from CWE-79.
Summary
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.
Why it matters now
SSVC decision points
Not available: CISA has not published SSVC decision points for this record.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| vmg | redcarpet | before 3.5.1 | 3.5.1 | Patch available | CNA |
| — | redcarpet (RubyGems) | before 3.5.1 | 3.5.1 | Patch available | GHSA-q3wr-qw3g-3p4h |
- redcarpet Vendorvmg Affected before 3.5.1 Fixed in 3.5.1 Patch available CNA
- redcarpet (RubyGems) Vendor— Affected before 3.5.1 Fixed in 3.5.1 Patch available GHSA-q3wr-qw3g-3p4h
CPE configurations NVD · 3
| CPE | Versions | Role | Vendor |
|---|---|---|---|
| cpe:2.3:a:redcarpet_project:redcarpet:*:*:*:*:*:ruby:*:* | before 3.5.1 | Vulnerable | Redcarpet Project |
| cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:* | 9.0 | Vulnerable | Debian |
| cpe:2.3:o:debian:debian_linux:10.0:*:*:*:*:*:*:* | 10.0 | Vulnerable | Debian |
- cpe:2.3:a:redcarpet_project:redcarpet:*:*:*:*:*:ruby:*:* Versions before 3.5.1 Vulnerable ·Redcarpet Project
- cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:* Versions 9.0 Vulnerable ·Debian
- cpe:2.3:o:debian:debian_linux:10.0:*:*:*:*:*:*:* Versions 10.0 Vulnerable ·Debian
Remediation
- Fix · CNA redcarpet (vmg) Fixed in 3.5.1
- Fix · GHSA-q3wr-qw3g-3p4h redcarpet (RubyGems) Fixed in 3.5.1 Advisory →
Vendor assessments
Red Hat
Red Hat rating: Moderate. Red Hat's page for this CVE →
| Product | Status | Plan or fix |
|---|---|---|
| Red Hat 3scale API Management Platform 2 | Affected | No fix yet |
Timeline
- 2026-10-02 Threatist record created from CVE-2020-26298
- 2026-10-03 Alias added: GHSA-q3wr-qw3g-3p4h
References
Advisory 9
- https://github.com/advisories/GHSA-q3wr-qw3g-3p4h
- https://rubygems.org/gems/redcarpet
- https://github.com/vmg/redcarpet/blob/master/CHANGELOG.md#version-351-security
- [debian-lts-announce] 20210115 [SECURITY] [DLA 2526-1] ruby-redcarpet security update
- DSA-4831
- FEDORA-2023-597f13ffb9
- FEDORA-2023-8682a0e17d
- FEDORA-2023-44daa9c1d4
- https://nvd.nist.gov/vuln/detail/CVE-2020-26298
Other 5
- https://github.com/rubysec/ruby-advisory-db/blob/master/gems/redcarpet/CVE-2020-26298.yml
- https://github.com/vmg/redcarpet
- https://lists.fedoraproject.org/archives/list/[email protected]/message/BFMYDIONVWATY7EB6EARDVXT47AYCRNM
- https://lists.fedoraproject.org/archives/list/[email protected]/message/FNO4ZZUPGAEUXKQL4G2HRIH7CUZKPCT6
- https://lists.fedoraproject.org/archives/list/[email protected]/message/PXNNWHHAPREDM3XJDACYRTK7DBMUONBI
Sources
- CVE-2020-26298 · CVE Program
- CVE-2020-26298 · NVD
- FIRST EPSS
- GHSA-q3wr-qw3g-3p4h · GitHub Advisory Database · CC BY 4.0
- CVE-2020-26298 · Red Hat security data · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences