Bug 1882344 (CVE-2020-24890)

Summary: CVE-2020-24890 libraw: null pointer dereference in parse_tiff_ifd in src/metadata/tiff.cpp
Product: [Other] Security Response Reporter: Dhananjay Arunesh <darunesh>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED NOTABUG QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: dchen, debarshir, gwync, hobbes1069, jridky, manisandro, nphilipp, siddharth.kde, siddhesh, than
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-09-25 20:40:55 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1882349, 1882350, 1882351    
Bug Blocks: 1882348    

Description Dhananjay Arunesh 2020-09-24 10:54:28 UTC
A vulnerability was found in libraw 20.0 has a null pointer dereference vulnerability in parse_tiff_ifd in src/metadata/tiff.cpp, which may result in context-dependent arbitrary code execution.

References:
https://github.com/LibRaw/LibRaw/issues/335

Comment 1 Dhananjay Arunesh 2020-09-24 10:56:57 UTC
Created LibRaw tracking bugs for this issue:

Affects: epel-6 [bug 1882351]
Affects: fedora-all [bug 1882349]


Created mingw-LibRaw tracking bugs for this issue:

Affects: fedora-all [bug 1882350]

Comment 2 Todd Cullum 2020-09-25 00:26:08 UTC
L#13165 of internal/dcraw_common.cpp is where the subject code is in 0.19.5.

Comment 3 Todd Cullum 2020-09-25 18:27:20 UTC
I get no such segfault using LibRaw 0.19.5 as built with g++ 9.3.1 on Fedora. I also do not get it on RHEL7 using g++ 4.8.5 or on RHEL8 using g++ 8.3.1 with the respectively shipped LibRaw rpms. The upstream maintainer identified this as a compiler problem as built by the reporter as the code in LibRaw is correct[1].

1. https://github.com/LibRaw/LibRaw/issues/335#issuecomment-677637276

Comment 4 Todd Cullum 2020-09-25 19:09:15 UTC
Statement:

LibRaw as shipped in Red Hat Enterprise Linux 7 and 8 are not affected by this flaw - the flaw seems to be isolated to the specific compiler version used to build LibRaw by the reporter. Versions of g++ and LibRaw as shipped did not exhibit the flaw.

Comment 5 Product Security DevOps Team 2020-09-25 20:40:55 UTC
This bug is now closed. Further updates for individual products will be reflected on the CVE page(s):

https://access.redhat.com/security/cve/cve-2020-24890