Opened 5 years ago

Closed 4 years ago

#8158 closed defect (fixed)

left shift of negative value bug in libavcodec/wmavoice.c

Reported by: Suhwan Owned by:
Priority: minor Component: avcodec
Version: git-master Keywords: wmavoice ubsan
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

Summary of the bug:
There is left shift of negative value bug in libavcodec/wmavoice.c:1523

libavcodec/wmavoice.c:1523:50: runtime error: left shift of negative value -2
SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior libavcodec/wmavoice.c:1523:50 in 

How to reproduce:

% ./ffmpeg_g -y -r 86 -i wmv3-wmaspeeech.wmv -loglevel 99 -map 0 -vframes 43 -aframes 60 -r 101 -ac 30 -strict 1 output/tmp.wtv

ffmpeg version N-94887-ge55018ee11 (git master)
built on ubuntu 18.04 with clang-6 and UBSAN option.

Attachments (2)

wmv3-wmaspeeech.wmv (42.9 KB ) - added by Suhwan 5 years ago.
poc
gdb-wmavoice (49.3 KB ) - added by Suhwan 5 years ago.

Download all attachments as: .zip

Change History (4)

by Suhwan, 5 years ago

Attachment: wmv3-wmaspeeech.wmv added

poc

by Suhwan, 5 years ago

Attachment: gdb-wmavoice added

comment:1 by Michael Niedermayer, 4 years ago

I suspect this was fixed by cf323f4d38f5756ecdb8fb4f72c80a8069da832e

comment:2 by Carl Eugen Hoyos, 4 years ago

Component: undeterminedavcodec
Keywords: wmavoice added
Priority: normalminor
Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.