Bug 1945033 (CVE-2019-19004) - CVE-2019-19004 autotrace: integer overflow in input-bmp.c
Summary: CVE-2019-19004 autotrace: integer overflow in input-bmp.c
Alias: CVE-2019-19004
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact:
Depends On: 1945034 1950140 1950141
Blocks: 1945039
TreeView+ depends on / blocked
Reported: 2021-03-31 09:33 UTC by Dhananjay Arunesh
Modified: 2022-04-17 21:15 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2021-11-09 22:52:34 UTC

Attachments (Terms of Use)

System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2021:4519 0 None None None 2021-11-09 19:05:02 UTC

Description Dhananjay Arunesh 2021-03-31 09:33:41 UTC
A biWidth*biBitCnt integer overflow in input-bmp.c in autotrace 0.31.1 allows
attackers to provide an unexpected input value to malloc via a malformed bitmap


Comment 1 Dhananjay Arunesh 2021-03-31 09:34:19 UTC
Created autotrace tracking bugs for this issue:

Affects: fedora-all [bug 1945034]

Comment 3 Marco Benatto 2021-04-15 20:29:33 UTC
There's no upstream fix for that, although the pull request was created it was never committed.

Comment 4 Marco Benatto 2021-05-03 19:49:53 UTC
A crafted image with big width or bit counting can cause the bytes per row counting in input_bmp_header() to overflow. This value is further used in ReadImage() as parameter for the malloc() function through XMALLOC wrapper macro. As malloc's size parameter is handled as unsigned always, an eventual overflow on bytes per row variable will be handled as close to MAX_SIZE_T and probably failing the memory allocation, leading malloc() to return a NULL pointer. The XMALLOC macro assert's the malloc's returned pointer and finishes the process in such scenario, causing a DoS for the application consuming autotrace library.

Comment 9 errata-xmlrpc 2021-11-09 19:05:01 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8

Via RHSA-2021:4519 https://access.redhat.com/errata/RHSA-2021:4519

Comment 10 Product Security DevOps Team 2021-11-09 22:52:32 UTC
This bug is now closed. Further updates for individual products will be reflected on the CVE page(s):


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