Commit Graph

191 Commits

Author SHA1 Message Date
Michael Niedermayer
5dae33bb39 tools/target_dec_fuzzer: Adjust VQA threshold
Fixes: Timeout (169sec -> 9sec)
Fixes: 23745/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_VQA_fuzzer-5638172179693568

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-09-19 00:40:56 +02:00
Michael Niedermayer
a12864938d tools/target_dec_fuzzer: Adjust threshold for WMV3IMAGE
Fixes: Timeout (1131sec -> 1sec)
Fixes: 24727/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_WMV3IMAGE_fuzzer-5754167793287168

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-09-07 23:05:25 +02:00
Michael Niedermayer
d08c3f56ec tools/target_dec_fuzzer: Adjust threshold for DST
Fixes: Timeout (too long -> 3sec)
Fixes: 24239/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DST_fuzzer-5189061015502848

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Reviewed-by: Peter Ross <pross@xvid.org>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-08-18 14:56:04 +02:00
Michael Niedermayer
4b7189848f tools/target_dec_fuzzer: Adjust threshold for AGM
Fixes: Timeout (142sec -> 2sec)
Fixes: 24426/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_AGM_fuzzer-5639724379930624

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-08-11 14:21:56 +02:00
Michael Niedermayer
0b182ff66d tools/target_dec_fuzzer: Adjust threshold for lagarith
Fixes: Timeout (3minute 49 sec -> 3sec)
Fixes: 22020/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_LAGARITH_fuzzer-5708544679870464

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-06-11 14:59:04 +02:00
Michael Niedermayer
3371d0611f tools/target_dec_fuzzer: enable mjpeg for tiff or tdsc
This is needed for fuzzing tiff/tdsc and should increase coverage

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-06-08 20:45:56 +02:00
Michael Niedermayer
6d4fdb4f5a tools/target_dec_fuzzer: Adjust max_pixels for AV_CODEC_ID_HAP
Fixes: Timeout (170sec -> 6sec)
Fixes: 20956/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_HAP_fuzzer-5713643025203200

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-05-27 23:52:46 +02:00
Michael Niedermayer
d6824ef905 tools/target_dec_fuzzer: Reduce maxpixels for HEVC
high resolutions with only small blocks appear to be rather
slow with the fuzzer + sanitizers.
A solution which makes this run faster is welcome.

Fixes: Timeout (did not wait -> 17sec)
Fixes: 21006/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_HEVC_fuzzer-6002552539971584

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-05-27 23:52:46 +02:00
Michael Niedermayer
05d364dccc tools/target_dec_fuzzer: Do not test AV_CODEC_FLAG2_FAST with AV_CODEC_ID_H264
This combination skips allocating large padding which can read out of array

Fixes: 20978/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_H264_fuzzer-5746381832847360

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-05-27 23:52:46 +02:00
Michael Niedermayer
4f54982773 tools/target_dec_fuzzer: Adjust threshold for PNG and APNG
Fixes: Timeout (84sec -> 2sec)
Fixes: 21127/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_APNG_fuzzer-5098412367413248

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-05-10 01:09:13 +02:00
Michael Niedermayer
2db37bf4cd tools/target_dec_fuzzer: Adjust threshold for zerocodec
Fixes: Timeout (147sec -> 1sec)
Fixes: 20764/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_ZEROCODEC_fuzzer-5068274603917312

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-04-12 16:36:47 +02:00
Michael Niedermayer
8dee1d7a30 tools/target_dec_fuzzer: Adjust threshold for screenpresso
Fixes: Timeout (332 -> 21 sec)
Fixes: 20280/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_SCREENPRESSO_fuzzer-6238663432470528

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-04-07 18:27:40 +02:00
Michael Niedermayer
32522b5307 tools/target_dec_fuzzer: limit per frame samples for APE
APE in its highest compression mode is really slow so even one frame
of millions of samples takes a long time

Fixes: Timeout (too long -> 3sec)
Fixes: 19937/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_APE_fuzzer-5751668818051072

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-01-30 19:59:10 +01:00
Michael Niedermayer
48b6947821 tools/target_dec_fuzzer: Add threshold for ALS
Fixes: Timeout (253sec -> 16sec)
Fixes: 18668/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_ALS_fuzzer-6227155369590784

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-01-30 19:40:26 +01:00
Michael Niedermayer
04e524c34b tools/target_dec_fuzzer: Add threshold for IFF_ILBM
Fixes: Timeout (32 -> 1sec)
Fixes: 20138/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_IFF_ILBM_fuzzer-5634665251864576

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Reviewed-by: Peter Ross <pross@xvid.org>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-01-29 13:06:26 +01:00
Michael Niedermayer
cc7bf7e05c tools/target_dec_fuzzer: Sort threshold list alphabetically
This also removes the comments as they are hard to maintain
together with sorted lists

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-01-29 13:06:26 +01:00
Michael Niedermayer
5f7727e1c9 tools/target_dec_fuzzer: Use codec_tags list
This should make it much quicker for the fuzzer to test
real relevant codec_tags

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-01-22 21:50:49 +01:00
Michael Niedermayer
00447b6f52 tools/target_dec_fuzzer: Also Fuzz with CPU optimizations disabled
This should improve coverage of *_c()

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-01-21 21:38:38 +01:00
Michael Niedermayer
4b733a7f5f tools/target_dec_fuzzer: Fuzz private options of AC3/E-AC3
This should improve AC-3 coverage

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-01-21 21:38:38 +01:00
Michael Niedermayer
48083f1890 tools/target_dec_fuzzer: Fuzz idct_algo value
This should improve coverage

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-01-21 21:38:38 +01:00
Michael Niedermayer
029cc9883f tools/target_dec_fuzzer: Adjust threshold for RASC
Fixes: Timeout(35sec -> 4sec)
Fixes: 19289/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_RASC_fuzzer-5676526398078976

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-01-11 23:31:18 +01:00
Michael Niedermayer
c1411a1132 tools/target_dec_fuzzer: Stop negative block_align and sampling rate
These are checked for early in avcodec_open2() and do not really test the decoder
but instead waste resources which could be better spend fuzzing the actual decoder

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-12-31 12:37:47 +01:00
Michael Niedermayer
5a8877da35 tools/target_dec_fuzzer: Adjust threshold for dst
Fixes: Timeout (400sec -> 14sec)
Fixes: 18989/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DST_fuzzer-5175008116867072

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-12-15 01:01:22 +01:00
Michael Niedermayer
e3dddf2142 tools/target_dec_fuzzer: Also fuzz request_channel_layout
This should improve coverage

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-12-08 13:08:23 +01:00
Michael Niedermayer
5ac8675cb1 tools/target_dec_fuzzer: Support setting AV_CODEC_FLAG2_FAST
This should improve coverage

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-12-03 16:06:33 +01:00
Michael Niedermayer
3ae87bb3c1 tools/target_dec_fuzzer: Support fuzzing error detection
This should increase coverage

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-12-03 16:06:20 +01:00
Michael Niedermayer
e21ec54fdf tools/target_dec_fuzzer: Adjust threshold for VP9
The threshold is chosen so that the worse frames would together not take
excessive time.
A better solution is welcome!

Fixes: Timeout (308sec ->102ms)
Fixes: 18314/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_VP9_fuzzer-5701689176227840

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-11-24 22:56:32 +01:00
Michael Niedermayer
de1d3b0925 tools/target_dec_fuzzer: Adjust threshold for smacker
Fixes: Timeout (65sec -> 0.5sec)
Fixes: 18072/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_SMACKER_fuzzer-5722709366931456

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-11-09 15:23:06 +01:00
Michael Niedermayer
fd3ee7a92e tools/target_dec_fuzzer: Adjust threshold for G2M
G2M allows large images from small input and also reallocates
multiple buffers on any resolution change.

Fixes: Timeout (22sec -> 5sec)
Fixes: 18022/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_G2M_fuzzer-5089192530411520

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-11-01 20:15:33 +01:00
Michael Niedermayer
8caa716667 tools/target_dec_fuzzer: Adjust threshold for CFHD
Fixes: Timeout (18sec -> 5sec)
Fixes: 17977/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_CFHD_fuzzer-5186112762413056

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-10-25 00:22:33 +02:00
Michael Niedermayer
000494fed9 tools/target_dec_fuzzer: Adjust ffwavesynth threshold
ffwavesynth can produce large amounts of data relatively slowly on very small input

Fixes: Timeout (60sec -> 9sec)
Fixes: 17970/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_FFWAVESYNTH_fuzzer-5689121279836160

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-10-25 00:22:33 +02:00
Michael Niedermayer
fe63ace98e tools/target_dec_fuzzer: Adjust threshold for DXV
Fixes: TImeout (20sec -> 4sec)
Fixes: 17735/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DXV_fuzzer-5723368317255680

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-10-20 19:57:51 +02:00
Michael Niedermayer
1d3f7e6a72 tools/target_dec_fuzzer: Adjust threshold for EATGV
Fixes: Timeout (26sec -> 9sec)
Fixes: 17645/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_EATGV_fuzzer-5717065922510848

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-10-16 19:17:57 +02:00
Michael Niedermayer
9e32c47102 tools/target_dec_fuzzer: Adjust threshold for SCPR
Fixes: Timeout (46sec -> 7sec)
Fixes: 17644/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_SCPR_fuzzer-5715704283660288

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-10-16 19:17:57 +02:00
Michael Niedermayer
cf7f35ace5 tools/target_dec_fuzzer: Adjust threshold for MSZH
Fixes: Timeout (250sec -> 6sec)
Fixes: 17627/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_MSZH_fuzzer-5643017129558016

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-10-16 19:17:57 +02:00
Michael Niedermayer
ec9d48da19 tools/target_dec_fuzzer: Also fuzz keyframe & disposal flags
This should improve coverage

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-10-15 17:09:22 +02:00
Michael Niedermayer
cc50d113c8 tools/target_dec_fuzzer: Also fuzz codec_tag
This should improve coverage

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-10-14 21:16:00 +02:00
Michael Niedermayer
2d3ccfa863 tools/target_dec_fuzzer: Also fuzz FF_COMPLIANCE_EXPERIMENTAL
This should improve coverage

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-10-14 21:16:00 +02:00
Michael Niedermayer
0c07eb5205 tools/target_dec_fuzzer: Also fuzz block_align
This should improve coverage

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-10-14 21:16:00 +02:00
Michael Niedermayer
47b0d0812e tools/target_dec_fuzzer: Adjust VP7 threshold
Fixes: Timeout (110sec -> 10sec)
Fixes: 17705/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_VP7_fuzzer-5765834135306240

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Reviewed-by: Peter Ross <pross@xvid.org>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-09-29 22:18:58 +02:00
Michael Niedermayer
ec4ad6fb9e tools/target_dec_fuzzer: Print samples decoded like pixels
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-09-26 21:02:34 +02:00
Michael Niedermayer
db614008bc tools/target_dec_fuzzer: Check number of all samples decoded too, like max pixels
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-09-26 21:02:34 +02:00
Michael Niedermayer
68c80dc312 tools/target_dec_fuzzer: Set max_samples
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-09-25 17:18:37 +02:00
Michael Niedermayer
59163731e9 tools/target_dec_fuzzer: consider potential padding/edge in pixel threshold
Fixes: Timeout (73sec ->30ms)
Fixes: 16921/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DIRAC_fuzzer-5689384594046976

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-09-24 17:53:39 +02:00
Michael Niedermayer
5fe6a9db15 tools/target_dec_fuzzer: Adjust threshold for MSS2
The decoder is slow

Fixes: Timeout (94sec -> 7sec)
Fixes: 16417/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_MSS2_fuzzer-5711668050395136

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-09-24 17:53:39 +02:00
Michael Niedermayer
87a7fc692d tools/target_dec_fuzzer: fuzz channels and sample_rate too
This should increase coverage over more audio decoders.

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-09-20 23:26:34 +02:00
Michael Niedermayer
65589ad553 tools/target_dec_fuzzer: Adjust threshold for binkvideo
Fixes: Timeout (89sec -> 7sec)
Fixes: 17035/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_BINK_fuzzer-5737222422134784

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Reviewed-by: Peter Ross <pross@xvid.org>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-09-17 14:45:08 +02:00
Michael Niedermayer
305f6dbb06 tools/target_dec_fuzzer: increase snows threshold
snow allows creating large output from tiny input, like other
wavelet codecs

Fixes: Timeout (82sec -> 1.5sec)
Fixes: 9520/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_SNOW_fuzzer-6286612576075776

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-09-16 00:53:18 +02:00
Michael Niedermayer
9fd62b84d5 tools/target_dec_fuzzer: Adjust motionpixels threshold
Fixes: Timeout (151sec -> 173ms)
Fixes: 16053/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_MOTIONPIXELS_fuzzer-5647069169057792
Fixes: 16053/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_MOTIONPIXELS_fuzzer-5108957126852608

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-09-16 00:04:18 +02:00
Michael Niedermayer
9d1e98afee tools/target_dec_fuzzer: Adjust threshold for LSCR
Fixes: Timeout (12sec -> 3sec)
Fixes: 15327/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_LSCR_fuzzer-5702887719567360

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-09-09 23:04:53 +02:00
Michael Niedermayer
5a3dee65d4 tools/target_dec_fuzzer: adjust pixel threshold for TRUEMOTION2, as it allows coding gigantic images on tiny input
Fixes: Timeout (137sec -> 6sec)
Fixes: 16090/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_TRUEMOTION2_fuzzer-5674245178261504

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-08-31 18:34:05 +02:00
Michael Niedermayer
a370582ba9 tools/target_dec_fuzzer: Init parsepkt
Fixes: memory corruption
Fixes: 16702/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_PNG_fuzzer-5768418552184832

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Reviewed-by: James Almer <jamrial@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-08-31 17:33:56 +02:00
Michael Niedermayer
ba823394f6 tools/target_dec_fuzzer: Adjust maxpixels for indeo4
Fixes: Timeout (131sec -> 4sec)
Fixes: 15581/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_INDEO4_fuzzer-5651105515569152

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-08-29 15:57:54 +02:00
Michael Niedermayer
96efaa9a1a tools/target_dec_fuzzer: Adjust GDV pixel threshold down by a factor of 2
Fixes: Timeout (7sec -> 1sec)
Fixes: 14709/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_GDV_fuzzer-5704215281795072

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-08-29 15:57:54 +02:00
Michael Niedermayer
738ff94f7c tools/target_dec_fuzzer: adjust pixel threshold for SANM, as it allows coding gigantic images on tiny input
Fixes: Timeout (13sec ->1sec)
Fixes: 16122/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_SANM_fuzzer-5724944247291904

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-08-29 15:57:54 +02:00
Michael Niedermayer
02a44ed0c8 tools/target_dec_fuzzer: Increase maxpixels threshold for dirac
wavelets allow significant size expansion and they are also not
very fast.

Fixes: Timeout
Fixes: 16480/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DIRAC_fuzzer-5659892689403904 (108sec -> 17ms)
Fixes: 16480/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DIRAC_fuzzer-5749422717140992 (big ->15sec)

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Reviewed-by: Tomas Härdin <tjoppen@acc.umu.se>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-08-26 10:36:40 +02:00
Michael Niedermayer
5af613cc48 tools/target_dec_fuzzer: Do not corrupt the packet size return
Fixes: Timeout (infinite)
Fixes: 16732/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_TAK_fuzzer-5642166377906176

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Reviewed-by: James Almer <jamrial@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-08-26 10:36:40 +02:00
James Almer
92c32b0f0c tools/target_dec_fuzzer: use refcounted packets
Should reduce allocations and data copying.

Signed-off-by: James Almer <jamrial@gmail.com>
2019-08-23 11:08:36 -03:00
Michael Niedermayer
ac77c5492f tools/target_dec_fuzzer: Do not increase max_pixels
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-08-23 14:38:42 +02:00
Michael Niedermayer
df7e79a5c3 tools/target_dec_fuzzer: adjust pixel threshold for MSRLE, as it allows coding gigantic images on tiny input
Fixes: Timeout (12sec ->2sec)
Fixes: 16125/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_MSRLE_fuzzer-5650846364205056

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>
2019-08-15 01:26:21 +02:00
Michael Niedermayer
1e2e47e348 tools/target_dec_fuzzer: Print max_pixels and iterations at the end
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-08-13 16:48:38 +02:00
Michael Niedermayer
faa9cd312f tools/target_dec_fuzzer: Add missing breaks
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-08-12 08:51:09 +02:00
Michael Niedermayer
9e0e9a5f36 tools/target_dec_fuzzer: Limit number off all pixels decoded
This should reduces the number of uninteresting timeouts encountered

A single threshold for all codecs did not work

Fixes: 13979/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_QTRLE_fuzzer-5629872380051456 (14sec -> 4sec)
Fixes: 14709/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_GDV_fuzzer-5704215281795072 (179sec -> 7sec)
Fixes: 16296/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_HNM4_VIDEO_fuzzer-5756304521428992 (108sec -> 9sec)
Fixes: 15620/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_GIF_fuzzer-5657214435459072 (26sec -> 26ms)

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-08-12 08:45:07 +02:00
Michael Niedermayer
42a2edcc1d tools/target_dec_fuzzer: fix memleak of extradata
Fixes: memleak
Fixes: 15535/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_SMACKER_fuzzer-5692162424963072

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-07-31 20:35:07 +02:00
Michael Niedermayer
508ce5839e tools/target_dec_fuzzer: Free parser in case of avcodec_open2() failure
Fixes: memleak
Fixes: part of 15529/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_LIBVPX_VP8_fuzzer-5140143700180992

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-07-21 12:33:35 +02:00
Michael Niedermayer
9b5249a441 tools/target_dec_fuzzer: Remove redundant av_free()
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-07-13 14:42:57 +02:00
Michael Niedermayer
6f2625aafc tools/target_dec_fuzzer: Also fuzz extradata
This should improve coverage

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-06-14 21:36:39 +02:00
Michael Niedermayer
0a2b768d3e tools/target_dec_fuzzer: Limit error concealment on pixels instead of just frames
This should reduce the amount of timeout issues overall

Fixes: Timeout (34->10sec)
Fixes: 14682/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_WMV2_fuzzer-5728608414334976

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-06-05 13:19:59 +02:00
Carl Eugen Hoyos
1a6cca1989 configure: Make sure libpostproc can be found if -rpath-link doesn't work.
Solaris ld takes "-rpath-link=libpostproc" as indication to search in "-link=libpostproc".
2018-12-28 00:22:13 +01:00
Michael Niedermayer
5c0fd9df87 tools/target_dec_fuzzer: set parser codec id to avoid assertion failure
Fixes: 9211/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_GSM_fuzzer-5680396581732352
Fixes: assertion failure

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-07-07 12:09:34 +02:00
Michael Niedermayer
9f0077cc03 tools/target_dec_fuzzer: Fix parser_avctx memleak on error path
Fixes: oss-fuzz issue 9195

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-06-30 16:13:48 +02:00
Michael Niedermayer
310a49f71d tools/target_dec_fuzzer: Also optionally fuzz with a parser
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-06-28 21:35:01 +02:00
Michael Niedermayer
42f40d36b7 avcodec/allcodecs: Provide empty codec_list in allcodecs when ossfuzz is used
The last workaround is not sufficient to make oss fuzz work with the iterate API
as it did not provide a FFmpeg that external libs can be linked to.

This patch does not fully restore the pre iterate functionality. My attempts to
do this have so far failed.

The problem with this solution is that it renders the fuzzers virtual system
ffmpeg (libs) non functional. Which differs from a real system compared to the
virtual system tested by the fuzzer.
It should theoretically not matter as the system ffmpeg wouldnt be used.
But with more cases being fuzzed we likely will hit a case where a external
lib is involved and it does matter ...

Working around this may be possible with weak symbols but so far my attempts
failed

Alternatively multiple ffmpeg could be built, this becomes messy though
quickly as they need to be all linked together. That is we need a FFmpeg
that has the iterate API modified so it can work with the resources
available to ossfuzz. And at the same time we need a ffmpeg that has
its full functionality for any external libs which use ffmpeg and are
used by ffmpeg.

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-05-28 23:17:32 +02:00
Michael Niedermayer
64f59a21b3 avcodec: Disable new iterate API for ossfuzz
A few days ago ossfuzz stoped testing new FFmpeg as it run out of diskspacee

https://oss-fuzz-build-logs.storage.googleapis.com/index.html

An alternative would be to revert the API.

This changes for example
-rwxr-x--- 1 michael michael 144803654 May 14 12:54 tools/target_dec_ac3_fixed_fuzzer*
to
-rwxr-x--- 1 michael michael  30333852 May 14 12:51 tools/target_dec_ac3_fixed_fuzzer*

Which should massively decrease space requirements

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-05-16 00:39:52 +02:00
Michael Niedermayer
c23209f63d tools/target_dec_fuzzer: Fix build after AV_CODEC_CAP_HWACCEL_VDPAU was removed
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-10-25 21:50:37 +02:00
Michael Niedermayer
e6debcaaed tools/target_dec_fuzzer: Fix build after FF_INPUT_BUFFER_PADDING_SIZE was removed
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-10-25 21:50:37 +02:00
Diego Biurrun
fd502f4f5f build: Generalize yasm/nasm-related variable names
None of them are specific to the YASM assembler.

(Cherry-picked from libav commit 39e208f4d4)

Signed-off-by: James Almer <jamrial@gmail.com>
2017-06-21 17:00:29 -03:00
Michael Niedermayer
718f8a01df tools/target_dec_fuzzer: Move the hwaccel check outside the initialization if
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-05-29 03:40:47 +02:00
Michael Niedermayer
38e79d9d9c tools/target_dec_fuzzer: Do not attempt to fuzz VDPAU, its not supported
Fixes: 1364/clusterfuzz-testcase-minimized-6459843441328128
Fixes: 1392

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-05-06 15:15:14 +02:00
Michael Niedermayer
d58fe01774 tools/target_dec_fuzzer: Do not use codec_id to look up decoder, but use selected decoder directly
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-05-06 15:12:05 +02:00
Michael Niedermayer
390c6ee42c tools/target_dec_fuzzer: Fix memleak on open failure
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-05-04 13:51:50 +02:00
Michael Niedermayer
dec2fa8cc7 tools/target_dec_fuzzer: Use decoder and not codec_id as argument
This allows fuzzing decoders with the same codec_id
We also avoid register all to allow the linker to prune unused sections and symbols

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-05-03 17:22:13 +02:00
Michael Niedermayer
56ddb923c6 tools/target_dec_fuzzer: Use avcodec_register_all() instead of register_all()
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-05-02 00:55:19 +02:00
Michael Niedermayer
a9b5b6a97f tools: Eliminate codec_type complexity from fuzzer
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-04-30 14:24:51 +02:00
Michael Niedermayer
966cbfbc83 tools/target_dec_fuzzer: Fix return code on open failure
Fixes: 1271/clusterfuzz-testcase-minimized-6095220498235392

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-04-27 04:25:31 +02:00
Michael Niedermayer
550a9c547e tools/target_dec_fuzzer: Remove FuzzerInterface.h dependancy
The header is not always available in the docker build environment

Suggested-by: Kostya Serebryany
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-04-25 03:13:00 +02:00
Michael Niedermayer
d976d2ec78 tools/target_dec_fuzzer: Fix build with default FFmpeg build flags
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-04-24 23:16:53 +02:00
Michael Niedermayer
164758a831 tools/target_dec_fuzzer: Fuzz video decoder related fields in context.
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-04-19 23:52:20 +02:00
Michael Niedermayer
c87ea47481 tools/target_dec_fuzzer: Fix misaligned read
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-02-24 14:12:13 +01:00
Michael Niedermayer
8bdba1092f tools/target_dec_fuzzer: Only audio uses the return value to decode packets in pieces, correct the code to match that
Fixes: Timeout
Fixes: 483/fuzz-0-ffmpeg_VIDEO_AV_CODEC_ID_H263I_fuzzer

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-01-31 23:43:41 +01:00
Rostislav Pehlivanov
e05d2dd86a doc/examples/decoder_targeted: move to tools/target_dec_fuzzer.c
Name and purpose are more appropriate there since the code isn't
an ideal example.

Reviewed-by: wm4 <nfxjfg@googlemail.com>
Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
2017-01-29 16:14:18 +00:00