Bug 1416066 (CVE-2017-5502) - CVE-2017-5502 jasper: Left shift of negative value in jp2_validate() in jp2_dec.c
Summary: CVE-2017-5502 jasper: Left shift of negative value in jp2_validate() in jp2_d...
Alias: CVE-2017-5502
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact:
Depends On:
Blocks: 1449402
TreeView+ depends on / blocked
Reported: 2017-01-24 14:03 UTC by Andrej Nemec
Modified: 2019-09-29 14:05 UTC (History)
19 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2017-03-13 21:59:28 UTC

Attachments (Terms of Use)

Description Andrej Nemec 2017-01-24 14:03:44 UTC
A vulnerability was found in jasper. A crafted file could cause a left shift of negative value.



Comment 1 Andrej Nemec 2017-01-24 14:23:44 UTC
Created mingw-jasper tracking bugs for this issue:

Affects: epel-7 [bug 1406409]

Comment 2 Andrej Nemec 2017-01-24 14:23:57 UTC
Created jasper tracking bugs for this issue:

Affects: epel-5 [bug 1406406]

Comment 3 Tomas Hoger 2017-03-13 21:49:22 UTC
Upstream bug report:


This issue has not been resolved upstream yet (the current upstream version is 2.0.12).

Reporter's advisory:


Relevant information from the advisory:

With the undefined behavior sanitizer enabled, jasper crashes showing some left shift and some signed integer overflow.


Affected version / Tested on: 1.900.17
Fixed version: N/A
Commit fix: N/A


Relevant part of the stacktrace:

# imginfo -f $FILE
/tmp/portage/media-libs/jasper-1.900.17/work/jasper-1.900.17/src/libjasper/jp2/jp2_dec.c:485:49: runtime error: left shift of negative value -26

CVE: CVE-2017-5502

Comment 4 Tomas Hoger 2017-03-13 21:59:28 UTC
The important information form the advisory is that this crash only occurs when jasper is compiles with undefined behaviour sanitizer (ubsan) enabled.  That is a development tool aimed to identify possible code bugs related to undefined behaviour.  There is no crash as described by this CVE in builds not using ubsan.  ubsan findings may indicate a relevant bug, but does not seem to have any other security impact.

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