Bug 2060662 (CVE-2022-24724) - CVE-2022-24724 cmark-gfm: possible RCE due to integer overflow
Summary: CVE-2022-24724 cmark-gfm: possible RCE due to integer overflow
Keywords:
Status: NEW
Alias: CVE-2022-24724
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
high
high
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact:
URL:
Whiteboard:
Depends On: 2060667 2060668 2060663 2060664 2060665 2060666 2074997 2074998
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-03-03 23:31 UTC by Anten Skrabec
Modified: 2022-07-18 14:30 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2022:5597 0 None None None 2022-07-18 14:30:19 UTC

Description Anten Skrabec 2022-03-03 23:31:40 UTC
cmark-gfm is GitHub's extended version of the C reference implementation of CommonMark. Prior to versions 0.29.0.gfm.3 and 0.28.3.gfm.21, an integer overflow in cmark-gfm's table row parsing `table.c:row_from_string` may lead to heap memory corruption when parsing tables who's marker rows contain more than UINT16_MAX columns. The impact of this heap corruption ranges from Information Leak to Arbitrary Code Execution depending on how and where `cmark-gfm` is used. If `cmark-gfm` is used for rendering remote user controlled markdown, this vulnerability may lead to Remote Code Execution (RCE) in applications employing affected versions of the `cmark-gfm` library. This vulnerability has been patched in the following cmark-gfm versions 0.29.0.gfm.3 and 0.28.3.gfm.21. A workaround is available. The vulnerability exists in the table markdown extensions of cmark-gfm. Disabling the table extension will prevent this vulnerability from being triggered.

https://github.com/github/cmark-gfm/security/advisories/GHSA-mc3g-88wq-6f4x

Comment 1 Anten Skrabec 2022-03-03 23:32:56 UTC
Created ghc-cmark-gfm tracking bugs for this issue:

Affects: fedora-34 [bug 2060663]
Affects: fedora-35 [bug 2060665]


Created ghostwriter tracking bugs for this issue:

Affects: fedora-34 [bug 2060664]
Affects: fedora-35 [bug 2060666]

Comment 8 errata-xmlrpc 2022-07-18 14:30:18 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8

Via RHSA-2022:5597 https://access.redhat.com/errata/RHSA-2022:5597


Note You need to log in before you can comment on or make changes to this bug.