Vulnerabilities in pkg:gem/kramdown
PACKAGECVE-2020-14001 is a CRITICAL (CVSS 9.8) unintended read access vulnerability (CWE-862: Missing Authorization) affecting Kramdown libraries in the RubyGems ecosystem. The issue involves unintended read access in kramdown gem. Remediation is available by upgrading affected packages to version 2.3.0.
pkg:gem/kramdown
Vulnerability advisories affecting package pkg:gem/kramdown. Select an advisory below to view technical details or fixes.
| Advisory ID | CVE / NVD | Severity | Summary |
|---|---|---|---|
| GHSA-mqm2-cgpr-p4m6 | CVE-2020-14001 | CRITICAL | Unintended read access in kramdown gem |
| GHSA-52p9-v744-mwjj | CVE-2021-28834 | HIGH | Remote code execution in Kramdown |
CVE-2020-14001 at a Glance
Security Impact
CVSS: 9.8
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H).
How to Fix CVE-2020-14001
To remediate this vulnerability, upgrade all affected Kramdown dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade kramdown to 2.3.0
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for kramdown
How to Check if You Are Affected
To determine whether your application is affected by CVE-2020-14001, inspect your project dependencies for Kramdown:
inspect dependencies for kramdown
Analyze the terminal output to locate any version of Kramdown in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.3.0), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-862: Missing Authorization, where the product does not perform an authorization check when an actor attempts to access a resource or perform an action. In Kramdown, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2020-14001 Affected Kramdown Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
kramdown
|
RubyGems |
< 2.3.0
|
2.3.0
|
References
Frequently Asked Questions
What is CVE-2020-14001?
Which Kramdown versions are affected?
What version fixes CVE-2020-14001?
Is kramdown affected?
What is the CVSS score of CVE-2020-14001?
What CWE is associated with CVE-2020-14001?
How can I check RubyGems dependencies for CVE-2020-14001?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-mqm2-cgpr-p4m6",
"modified" : "2022-04-29T20:26:19Z",
"published" : "2020-08-07T22:27:41Z",
"aliases" : [ "CVE-2020-14001" ],
"summary" : "Unintended read access in kramdown gem",
"details" : "The kramdown gem before 2.3.0 for Ruby processes the template option inside Kramdown documents by default, which allows unintended read access (such as template=\"/etc/passwd\") or unintended embedded Ruby code execution (such as a string that begins with template=\"string://<%= `). NOTE: kramdown is used in Jekyll, GitLab Pages, GitHub Pages, and Thredded Forum.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "RubyGems",
"name" : "kramdown"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "2.3.0"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2020-14001"
}, {
"type" : "WEB",
"url" : "https://github.com/gettalong/kramdown/commit/1b8fd33c3120bfc6e5164b449e2c2fc9c9306fde"
}, {
"type" : "ADVISORY",
"url" : "https://github.com/advisories/GHSA-mqm2-cgpr-p4m6"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/gettalong/kramdown"
}, {
"type" : "WEB",
"url" : "https://github.com/gettalong/kramdown/compare/REL_2_2_1...REL_2_3_0"
}, {
"type" : "WEB",
"url" : "https://github.com/rubysec/ruby-advisory-db/blob/master/gems/kramdown/CVE-2020-14001.yml"
}, {
"type" : "WEB",
"url" : "https://kramdown.gettalong.org"
}, {
"type" : "WEB",
"url" : "https://kramdown.gettalong.org/news.html"
}, {
"type" : "WEB",
"url" : "https://lists.apache.org/thread.html/r96df7899fbb456fe2705882f710a0c8e8614b573fbffd8d12e3f54d2@%3Cnotifications.fluo.apache.org%3E"
}, {
"type" : "WEB",
"url" : "https://lists.debian.org/debian-lts-announce/2020/08/msg00014.html"
}, {
"type" : "WEB",
"url" : "https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/ENMMGKHRQIZ3QKGOMBBBGB6B4LB5I7NQ"
}, {
"type" : "WEB",
"url" : "https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/KBLTGBYU7NKOUOHDKVCU4GFZMGA6BP4L"
}, {
"type" : "WEB",
"url" : "https://rubygems.org/gems/kramdown"
}, {
"type" : "WEB",
"url" : "https://security.netapp.com/advisory/ntap-20200731-0004"
}, {
"type" : "WEB",
"url" : "https://usn.ubuntu.com/4562-1"
}, {
"type" : "WEB",
"url" : "https://www.debian.org/security/2020/dsa-4743"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-862" ],
"severity" : "CRITICAL",
"github_reviewed" : true,
"github_reviewed_at" : "2020-08-07T22:27:22Z",
"nvd_published_at" : "2020-07-17T16:15:00Z"
}
}