Bug 1934699 (CVE-2021-25292)

Summary: CVE-2021-25292 python-pillow: Regular expression DoS in PDF format parser
Product: [Other] Security Response Reporter: Guilherme de Almeida Suckevicz <gsuckevi>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED ERRATA QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: bdettelb, cstratak, kaycoth, lbalhar, manisandro, miminar, orion, paul, python-maint, rhel8-maint, tomckay, torsava
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: python-pillow 8.1.1 Doc Type: If docs needed, set a value
Doc Text:
A flaw was found in python-pillow. The PDF parser has a catastrophic backtracking regex that could be used as a DOS attack.
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-10-19 14:08:58 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: 1934700, 1934701, 1934702, 1934703, 1935584, 1939589, 1939590    
Bug Blocks: 1934710    

Description Guilherme de Almeida Suckevicz 2021-03-03 17:11:33 UTC
The PDF parser has a catastrophic backtracking regex that could be used as a DOS attack.

Reference:
https://pillow.readthedocs.io/en/stable/releasenotes/8.1.1.html

Comment 1 Guilherme de Almeida Suckevicz 2021-03-03 17:12:52 UTC
Created mingw-python-pillow tracking bugs for this issue:

Affects: fedora-all [bug 1934702]


Created python-pillow tracking bugs for this issue:

Affects: fedora-all [bug 1934700]


Created python2-pillow tracking bugs for this issue:

Affects: fedora-all [bug 1934701]


Created python3-pillow tracking bugs for this issue:

Affects: epel-7 [bug 1934703]

Comment 3 Jason Shepherd 2021-03-08 03:02:59 UTC
Mitigation:

Disable the invoice generation feature to mitigate this vulnerability in Red Hat Quay.

Comment 7 Lumír Balhar 2021-04-08 15:20:31 UTC
Upstream does not have an example of the crafted pdf file to reproduce the issue. Do you plan to create a reproducer?

Comment 8 Lumír Balhar 2021-04-09 13:42:37 UTC
See a new upstream test: https://github.com/python-pillow/Pillow/pull/5393/files

Comment 9 errata-xmlrpc 2021-10-19 12:10:59 UTC
This issue has been addressed in the following products:

  Red Hat Quay 3

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

Comment 10 Product Security DevOps Team 2021-10-19 14:08:58 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-2021-25292

Comment 11 errata-xmlrpc 2021-11-09 17:24:23 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8

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