Michael Niedermayer
532ba2e4ae
avformat/mov: Only set pkt->duration to non negative values
...
Reviewed-by: Sasi Inguva <isasi@google.com >
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 8176799f31
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
78fe6f7c32
avcodec/h264_slice: Fix overflow in recovery_frame computation
...
Fixes: signed integer overflow: 15 + 2147483646 cannot be represented in type 'int'
Fixes: 8381/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_H264_fuzzer-6225533137321984
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 8c20ea8ee0
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
3be0549029
avcodec/h264_ps: Move MAX_LOG2_MAX_FRAME_NUM to header so it can be used in h264_sei
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit b796c5ae92
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
28f0449659
avcodec/h264_mc_template: Only prefetch motion if the list is used.
...
Fixes: index 59 out of bounds for type 'H264Ref [48]'
Fixes: 8232/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_H264_fuzzer-5703295145345024
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 8b55591757
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
5d6d0d20fe
avcodec/xwddec: Use ff_set_dimensions()
...
Fixes: OOM
Fixes: 8178/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_XWD_fuzzer-4844793342459904
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Reviewed-by: Paul B Mahol <onemda@gmail.com >
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit c2852e4e00
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
b60a750af7
avcodec/wavpack: Fix overflow in adding tail
...
Fixes: signed integer overflow: 2146907204 + 26846088 cannot be represented in type 'int'
Fixes: 8105/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_WAVPACK_fuzzer-6233036682166272
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit d13379fb79
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
5d61400740
avcodec/shorten: Fix multiple integer overflows
...
Fixes: signed integer overflow: 3 * 1006632960 cannot be represented in type 'int'
Fixes: 8278/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_SHORTEN_fuzzer-5692857166856192
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit f2abd36b38
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
62e1c5db4a
avcodec/shorten: Fix undefined shift in fix_bitshift()
...
Fixes: left shift of negative value -9
Fixes: 8571/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_SHORTEN_fuzzer-5715966875926528
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 606c714823
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
8b6c773fe8
avcodec/shorten: Fix a negative left shift in shorten_decode_frame()
...
Fixes: left shift of negative value -9057
Fixes: 8527/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_SHORTEN_fuzzer-5666853924896768
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit a711efe922
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
3f5bc91be3
avcodec/shorten: Sanity check nmeans
...
Fixes: OOM
Fixes: 8195/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_SHORTEN_fuzzer-5179785826271232
The reference software appears to use longs for 32bits and it uses int for nmeans
hinting that the intended maximum size was not 32bit.
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit d91a0b503d
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
7598b161f4
avcodec/shorten: Check non COMM chunk len before skip in decode_aiff_header()
...
Fixes: signed integer overflow: 2147483647 + 1 cannot be represented in type 'int'
Fixes: 8024/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_SHORTEN_fuzzer-5109204648984576
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 424a81df10
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
aa30aa8c13
avcodec/mjpegdec: Fix integer overflow in ljpeg_decode_rgb_scan()
...
Fixes: signed integer overflow: 32768 + 2147450880 cannot be represented in type 'int'
Fixes: 7885/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_THP_fuzzer-5298834394578944
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 936f4a2c2e
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
c4c56eb839
avcodec/truemotion2: Fix overflow in tm2_apply_deltas()
...
Fixes: signed integer overflow: 1077952576 + 1077952576 cannot be represented in type 'int'
Fixes: 7712/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_TRUEMOTION2_fuzzer-5056281753681920
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 79c6047c36
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
df7d70272e
avcodec/opus_silk: Change silk_lsf2lpc() slightly toward silk/NLSF2A.c
...
Fixes: runtime error: signed integer overflow: -1440457022 - 785819492 cannot be represented in type 'int'
Fixes: 7700/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_OPUS_fuzzer-6595838684954624
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit e7dda51150
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
f0c60a91ae
avcodec/amrwbdec: Fix division by 0 in find_hb_gain()
...
This restructures the code slightly toward D_UTIL_dec_synthesis()
Fixes: 7420/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_AMRWB_fuzzer-6577305112543232
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit dce80a4b47
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
adea365be9
avformat/mov: replace a value error by clipping into valid range in mov_read_stsc()
...
Fixes : #7165
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit fe84f70819
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
ce7be9cdc5
avformat/mov: Break out early if chunk_count is 0 in mov_build_index()
...
Without this some operations might overflow (undefined behavior)
even though the index adding loop would never execute
No testcase known
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 56e76bd057
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
26667dc5ba
avcodec/fic: Avoid some magic numbers related to cursors
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit c6a11714c4
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
12f0cfede6
avcodec/g2meet: ask for sample with overflowing RGB
...
Suggested-by: Tomas Härdin <tjoppen@acc.umu.se >
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit ab834b8f36
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
ada22c1c0f
avcodec/aacdec_fixed: use 64bit to avoid overflow in rounding in apply_dependent_coupling_fixed()
...
Fixes: signed integer overflow: -2141499320 + -14469590 cannot be represented in type 'int'
Fixes: 7351/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_AAC_FIXED_fuzzer-6351214791884800
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 90475db97e
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
b7b178fd0f
oavcodec/aacpsdsp_template: Use unsigned for hs0X to prevent undefined behavior
...
Fixes: signed integer overflow: 1073741842 + 1784008138 cannot be represented in type 'int'
Fixes: 6792/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_AAC_FIXED_fuzzer-5677589835284480
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 62cb6fadf3
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
c91f199f5d
avcodec/g723_1dec: Clip bits2 in both directions
...
Fixes: shift exponent 33 is too large for 32-bit type 'int'
Fixes: 6743/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_G723_1_fuzzer-5823772687859712
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 53f241218d
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
bd1fd3ff4b
avcodec/mpeg4videoenc: Use 64 bit for times in mpeg4_encode_gop_header()
...
Fixes truncation
Fixes Assertion n <= 31 && value < (1U << n) failed at libavcodec/put_bits.h:169
Fixes: ffmpeg_crash_2.avi
Found-by: Thuan Pham <thuanpv@comp.nus.edu.sg >, Marcel Böhme, Andrew Santosa and Alexandru RazvanCaciulescu with AFLSmart
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit e1182fac1a
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
4cbd92baa3
avcodec/mlpdec: Only change noise_type if the related fields are valid
...
Fixes: inconsistency
Fixes:runtime error: index 8 out of bounds for type 'int32_t [8]'
Fixes: 6686/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_TRUEHD_fuzzer-5191383498358784
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 63c4a4b0d6
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
9d3ae90516
indeo4: Decode all or nothing of a band header.
...
This avoids inconsistent value combinations.
Alternatively it would be possible to add more checks and careful use of
temporary variables, but my try of this quickly seemed to become
a rather large change.
The disadvantage of this, is that the struct is copied back and forth.
Fixes: index 6 out of bounds for type 'const uint16_t [5][16]'
Fixes: 6557/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_INDEO4_fuzzer-4787296550256640
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 10c8521265
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
3712d4da1e
avformat/mov: Only fail for STCO/STSC contradictions if both exist
...
Fixes regression with playback of GF9720Repeal20the20Eighth20with20Helen20Linehan.m4a
See: crbug 822666
Found-by: "Mattias Wadman <mattias.wadman@gmail.com >
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 2c2d689c56
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
22b3e924df
avcodec/dirac_dwt: Fix integer overflow in COMPOSE_DD97iH0 / COMPOSE_DD137iL0
...
Fixes: negation of -2147483648 cannot be represented in type 'int32_t' (aka 'int');
Fixes: 6500/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DIRAC_fuzzer-4523620274536448
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit cb944fc7f1
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
14cea44018
avcodec/fic: Check available input space for cursor
...
Fixes: out of array read
Fixes: 6546/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_FIC_fuzzer-6317064647081984
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit cb2f7ea96b
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
b802baadfd
avcodec/g2meet: Check RGB upper limit
...
Fixes: runtime error: left shift of 1876744317 by 16 places cannot be represented in type 'int'
Fixes: 6799/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_G2M_fuzzer-5115274731716608
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 4dd2c8b9ea
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
022c8c07f8
avcodec/jpeg2000dec: Fix undefined shift in the jpeg2000_decode_packets_po_iteration() CPRL case
...
Fixes: shift exponent 47 is too large for 32-bit type 'int'
Fixes: 7955/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_JPEG2000_fuzzer-6016721977606144
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 652ba72ed3
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
f4d90a36c5
avcodec/jpeg2000dec: Skip init for component in CPRL if nothing is to be done
...
Fixes: assertion failure
Fixes: 7949/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_JPEG2000_fuzzer-4819602782552064
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit a96c131eb5
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
2cb3dff0f9
avcodec/g2meet: Change order of operations to avoid undefined behavior
...
Fixes: signed integer overflow: 65280 * 196032 cannot be represented in type 'int'
Fixes: 7279/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_G2M_fuzzer-5977332473921536
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 0a47451458
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
5d1c783bf0
avcodec/flac_parser: Fix infinite loop
...
Fixes: crbug/827204
Reported-by: Frank Liberato <liberato@google.com >
Reviewed-by: Frank Liberato <liberato@google.com >
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 15a2e35e9e
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
909c1aa0ec
avcodec/wavpack: Fix integer overflow in DEC_MED() / INC_MED()
...
Fixes: runtime error: signed integer overflow: 2147483637 + 128 cannot be represented in type 'int'
Fixes: 6701/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_WAVPACK_fuzzer-5358324934508544
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 6e95d80e6f
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
c437510d5c
avcodec/wavpack: Fix integer overflow in wv_unpack_stereo()
...
Fixes: runtime error: signed integer overflow: 2147483531 + 16384 cannot be represented in type 'int'
Fixes: 6615/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_WAVPACK_fuzzer-5165715515506688
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit da038c07f0
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
30ec2357c9
avcodec/error_resilience: Fix integer overflow in filter181()
...
Fixes: runtime error: signed integer overflow: 197710 * 10923 cannot be represented in type 'int'
Fixes: 7010/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_MPEG4_fuzzer-5667127596941312
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 1c97035e3b
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
3b23dd4b91
avcodec/h263dec: Check slice_ret in mspeg4 slice loop
...
Fixes infinite loop
Fixes: 6858/clusterfuzz-testcase-ffmpeg_AV_CODEC_ID_MSMPEG4V3_fuzzer-4681563766784000
Fixes: 6890/clusterfuzz-testcase-ffmpeg_AV_CODEC_ID_WMV1_fuzzer-4756103142309888
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit de841fbea7
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
24947b3f7d
avcodec/elsdec: Fix memleaks
...
Fixes: 6798/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_G2M_fuzzer-5135899701542912
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 0bd0401336
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
f31ead3f76
avcodec/vc1_block: simplify ac_val computation
...
also fixes: runtime error: index 1456 out of bounds for type 'int16_t [16]'
Found-by: durandal_1707
Reviewed-by: Paul B Mahol <onemda@gmail.com >
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit d06b01fc2d
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Michael Niedermayer
be9c4cc0e6
avcodec/ffv1enc: Check that the crc + version combination is supported
...
The crc flag is only stored since version 3 thus before this crcs do not
work. We increase the version as needed same as we do with pix_fmts
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit d9706f79c1
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:04 +02:00
Stephan Holljes
1d5694ba11
lavf/http.c: Free allocated client URLContext in case of error.
...
Signed-off-by: Stephan Holljes <klaxa1337@googlemail.com >
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 7b6b8c9265
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:03 +02:00
Michael Niedermayer
f93d7a0c0a
avcodec/dsicinvideo: Fail if there is only a small fraction of the data available that comprises a full frame
...
Fixes: Timeout
Fixes: 6306/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DSICINVIDEO_fuzzer-5079253549842432
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 5549488bbf
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:03 +02:00
Michael Niedermayer
81d8bd6f42
avcodec/dsicinvideo: Propagate errors from cin_decode_rle()
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 942217b153
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:03 +02:00
Michael Niedermayer
86c7035646
avcodec/dfa: Check dimension against maximum
...
The headers from where the dimensions are read in actual files
are limited to 16bit per component.
Fixes: Timeout
Fixes: 6305/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DFA_fuzzer-4824270749302784
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 9d5a4fcfbb
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:03 +02:00
Michael Niedermayer
a6db663a31
avcodec/cinepak: Skip empty frames
...
Speeds up decoding from 3 to 0.1 seconds for 6302/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_CINEPAK_fuzzer-5626371985375232
Fixes: Timeout
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 9033920bec
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:03 +02:00
Michael Niedermayer
205e93fa0d
avcodec/cinepak: move some checks prior to frame allocation
...
Speeds up decoding from 8 to 3 seconds for 6302/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_CINEPAK_fuzzer-5626371985375232
Fixes: Timeout
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 2324ef1ff3
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:03 +02:00
Rahul Chaudhry
47c3d2459e
swresample/arm: remove unintentional relocation.
...
Branch to global symbol results in reference to PLT, and when compiling
for THUMB-2 - in a R_ARM_THM_JUMP19 relocation. Some linkers don't
support this relocation (ld.gold), while others can end up truncating
the relocation to fit (ld.bfd).
Convert this branch through PLT into a direct branch that the assembler
can resolve locally.
See https://github.com/android-ndk/ndk/issues/337 for background.
The current workaround is to disable neon during gstreamer build,
which is not optimal and can be reverted after this patch:
41556c4157
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit b22db4f465
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:03 +02:00
Michael Niedermayer
86a6e700e1
doc/APIchanges: Fix typos in hashes
...
Thanks-to: Moritz Barsnick <barsnick@gmx.net > for finding the correct ones
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit ec8a5262b0
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:03 +02:00
Michael Niedermayer
0b5a2c9a52
avformat/utils: Check cur_dts in update_initial_timestamps() more
...
Fixes: runtime error: signed integer overflow: 18133149658382192 - -9223090561878065151 cannot be represented in type 'long long'
Fixes: crbug 831552
Reported-by: Matt Wolenetz <wolenetz@google.com >
Reviewed-by: Matt Wolenetz <wolenetz@google.com >
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 37d46dc21d
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:03 +02:00
Michael Niedermayer
22a4b599f0
avcodec/utils: Enforce minimum width also for VP5/6
...
Fixes: out of array access
Fixes: poc_0411
Found-by: GwanYeong Kim <gy741.kim@gmail.com >
Tested-by: GwanYeong Kim <gy741.kim@gmail.com >
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 544324827e
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2018-06-18 01:16:03 +02:00