Michael Niedermayer
334d24b539
INSTALL: explain the circular dependency issue and solution
...
Sponsored-by: Sovereign Tech Fund
Reviewed-by: James Almer <jamrial@gmail.com >
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit df00705e00 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:12 +01:00
Michael Niedermayer
b612d3634c
avformat/mpegts: Initialize predefined_SLConfigDescriptor_seen
...
Fixes: use of uninitialized variable
Fixes: 368729566/clusterfuzz-testcase-minimized-ffmpeg_dem_MPEGTS_fuzzer-6044501804646400
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 db7b4fc89f )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:11 +01:00
Michael Niedermayer
6c14d8e338
avformat/mxfdec: Fix overflow in midpoint computation
...
Fixes: signed integer overflow: 4611686016549392399 + 9223372033098784800 cannot be represented in type 'long long'
Fixes: 368503277/clusterfuzz-testcase-minimized-ffmpeg_dem_MXF_fuzzer-5928227458056192
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 23088a5ff2 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:11 +01:00
Michael Niedermayer
9bef02015e
swscale/output: used unsigned for bit accumulation
...
Fixes: Integer overflow
Fixes: 368725672/clusterfuzz-testcase-minimized-ffmpeg_SWS_fuzzer-5009093023563776
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 3fe3014405 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:11 +01:00
Michael Niedermayer
d1ea5ab824
avcodec/rangecoder: only perform renorm check/loop for callers that need it
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit d147b3d7ec )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:10 +01:00
Michael Niedermayer
e958e49b31
avcodec/ffv1dec: Fix end computation with ec=2
...
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 10e5af15bf )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:10 +01:00
Michael Niedermayer
a24784d504
avcodec/ffv1enc: Prevent generation of files with broken slices
...
Fixes: Ticket5548
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit b7ff66a358 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:10 +01:00
Michael Niedermayer
71885a72b6
avformat/matroskadec: Check desc_bytes so bits fit in 64bit
...
Likely a tighter check can be done
Fixes: signed integer overflow: 3305606804154370442 * 8 cannot be represented in type 'long'
Fixes: 70449/clusterfuzz-testcase-minimized-ffmpeg_dem_WEBM_DASH_MANIFEST_fuzzer-4771166007918592
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 c4122406f6 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:09 +01:00
Michael Niedermayer
736791b4e2
avcodec/ffv1enc: Correct error message about unsupported version
...
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 556c767786 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:09 +01:00
Michael Niedermayer
c02c96b93d
avcodec/ffv1enc: Slice combination is unsupported
...
We always write minimal slices, the size calculation is wrong in some
corner cases but as its always 1x1 (minus1) we can for now just hard-code it
This helps with ticket 5548
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 7d514655bf )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:09 +01:00
Michael Niedermayer
50a5c2f75d
avcodec/ffv1enc: 2Pass mode is not possible with golomb coding
...
"Fixes" Ticket7063
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 417b163c00 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:08 +01:00
Michael Niedermayer
95b2b8393d
avcodec/ffv1enc: Fix >8bit context size
...
Fixes: Ticket5405
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit a9c83e43f2 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:08 +01:00
Michael Niedermayer
3c005e89b2
avcodec/xan: Add basic input size check
...
Fixes: Timeout
Fixes: 71739/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_XAN_WC3_fuzzer-6170301405134848
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpe
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 56bef2fd58 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:07 +01:00
Michael Niedermayer
ab42cdfd0e
avcodec/svq3: Check for minimum size input
...
Fixes: Timeout
Fixes: 71295/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_SVQ3_fuzzer-4999941125111808
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 050b5e85cb )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:07 +01:00
Michael Niedermayer
8d3f10011d
avcodec/eacmv: Check input size for intra frames
...
Fixes: Timeout
Fixes: 71135/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_EACMV_fuzzer-6251879028293632
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 c3a1cbbf5d )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:07 +01:00
Michael Niedermayer
a51d618e8b
avcodec/jfdctint_template: use unsigned z* in row_fdct()
...
Fixes: signed integer overflow: 856827136 + 2123580416 cannot be represented in type 'int'
Fixes: 70772/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_PRORES_KS_fuzzer-5180569961431040
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 f27c8b04d3 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:06 +01:00
Michael Niedermayer
8bc1b2ee5d
avformat/mxfdec: Check timecode for overflow
...
Fixes: signed integer overflow: 9223372036840103968 + 538976288 cannot be represented in type 'long'
Fixes: 70604/clusterfuzz-testcase-minimized-ffmpeg_dem_MXF_fuzzer-4844090340999168
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 6be3786c82 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:06 +01:00
Michael Niedermayer
9912935062
avformat/mxfdec: More offset_temp checks
...
Fixes: signed integer overflow: 9223372036854775807 - -1927491430256034080 cannot be represented in type 'long'
Fixes: 70607/clusterfuzz-testcase-minimized-ffmpeg_dem_MXF_fuzzer-5282235077951488
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Reviewed-by: Tomas Härdin <git@haerdin.se >
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 5a96aa435a )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:06 +01:00
Michael Niedermayer
795cec23b2
swscale/output: Fix undefined integer overflow in yuv2rgba64_2_c_template()
...
Fixes: signed integer overflow: -1082982400 + -1083218484 cannot be represented in type 'int'
Fixes: 70657/clusterfuzz-testcase-minimized-ffmpeg_SWS_fuzzer-6707819712675840
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 bd80c97391 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:05 +01:00
Michael Niedermayer
f0442346e6
swscale/swscale: Use unsigned operation to avoid undefined behavior
...
I have not checked that the constant is correct, this just fixes the undefined behavior
Fixes: signed integer overflow: -646656 * 3517 cannot be represented in type 'int
Fixes: 70559/clusterfuzz-testcase-minimized-ffmpeg_SWS_fuzzer-5209368631508992
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 44c5641ae8 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:05 +01:00
Michael Niedermayer
dfdb353fff
avcodec/vc2enc: basic sanity check on slice_max_bytes
...
Fixes: left shift of 896021632 by 3 places cannot be represented in type 'int'
Fixes: 70544/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_VC2_fuzzer-6685593652756480
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 6df9a0292c )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:05 +01:00
Michael Niedermayer
d0a7da4874
avformat/mvdec: Check if name was fully read
...
Fixes: use of uninitialized value
Fixes: 70901/clusterfuzz-testcase-minimized-ffmpeg_dem_MV_fuzzer-6341913949569024
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 4e39795c75 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:04 +01:00
Michael Niedermayer
5a6bfec33d
avcodec/wmavoice: Do not use uninitialized pitch[0]
...
Fixes: use of uninitialized value
Fixes: 70850/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_WMAVOICE_fuzzer-4806127362048000
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 5338707930 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:04 +01:00
Michael Niedermayer
4c9978124d
avcodec/notchlc: Check bytes left before reading
...
Fixes: Use of uninitialized value
Fixes: 71230/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_NOTCHLC_fuzzer-4624502095413248
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 b9c7f50c7d )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:04 +01:00
Michael Niedermayer
a0e85cda1d
avcodec/vc1_block: propagate error codes
...
Fixes: use of uninitialized value
Fixes: 71228/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_VC1IMAGE_fuzzer-6188476880453632
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 01910ca603 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:03 +01:00
Michael Niedermayer
c84b693703
avformat/apetag: Check APETAGEX
...
Fixes: Use of uninitialized value
Fixes: 71074/clusterfuzz-testcase-minimized-ffmpeg_IO_DEMUXER_fuzzer-5697034877730816
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 796ff2d599 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:03 +01:00
Michael Niedermayer
c5b3a3f969
avcodec/avcodec: Warn about data returned from get_buffer*()
...
Text based on suggestion by: epirat07@gmail.com
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 93444c46fce195e378c4ebb1a20ea662e7f0123b)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:03 +01:00
Michael Niedermayer
985ee23665
avcodec/aic: Clear slice_data
...
Fixes: use-of-uninitialized-value
Fixes: 70865/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_AIC_fuzzer-4874102695854080
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 de3f6c8888 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:02 +01:00
Michael Niedermayer
9b7d4ad167
avcodec/vc1dec: Clear mb_type_base and ttblk_base
...
Fixes: two use-of-uninitialized-value
Fixes: 70856/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_VC1IMAGE_fuzzer-5539349918187520
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 50471f96c4 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:02 +01:00
Michael Niedermayer
a3431f279e
avcodec/shorten: clear padding
...
Fixes: use-of-uninitialized-value
Fixes: 70854/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_SHORTEN_fuzzer-5533480570650624
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 e44349ee88 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:02 +01:00
Michael Niedermayer
c9a2d48c2e
avformat/mpeg: Check an avio_read() for failure
...
Fixes: use-of-uninitialized-value
Fixes: 70849/clusterfuzz-testcase-minimized-ffmpeg_dem_MPEGPS_fuzzer-4684401009557504
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 66ee75d76c )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:01 +01:00
Michael Niedermayer
4eceda7528
avcodec/mvha: Clear remaining space after inflate()
...
Fixes: use-of-uninitialized-value
Fixes: 70838/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_MVHA_fuzzer-4878509466517504
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 cba4e2e40d )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:01 +01:00
Michael Niedermayer
0e4eaa307f
avformat/segafilm: Set keyframe
...
Fixes: use of uninitialized value
Fixes: 70871/clusterfuzz-testcase-minimized-ffmpeg_dem_SEGAFILM_fuzzer-5883617752973312
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 4dc7dfe65a )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:01 +01:00
Michael Niedermayer
e102dfd331
avcodec/dxva2: initialize hr in ff_dxva2_common_end_frame()
...
Related: CID1591924 Uninitialized scalar variable
Related: CID1591938 Uninitialized scalar variable
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 1d6a2aebae )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:00 +01:00
Michael Niedermayer
e6a6343976
avcodec/dxva2: initialize validate
...
Related: CID1591915 Uninitialized scalar variable
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 2232c4cc8c )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:00 +01:00
Michael Niedermayer
cb57b8352d
avcodec/dxva2: Initialize ConfigBitstreamRaw
...
Related: CID1591894 Uninitialized scalar variable
Related: CID1591906 Uninitialized scalar variable
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 489c05b9c3 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:53:00 +01:00
Michael Niedermayer
5b82c7c04c
avcodec/dxva2: Initialize dxva_size and check it
...
Related: CID1591878 Uninitialized scalar variable
Related: CID1591928 Uninitialized pointer read
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit c8c59e9929 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:52:59 +01:00
Michael Niedermayer
a24f1e1f7a
avfilter/vf_xfade: Compute w2, h2 with float
...
Fixes: CID1458148 Result is not floating-point
Fixes: CID1458149 Result is not floating-point
Fixes: CID1458150 Result is not floating-point
Fixes: CID1458151 Result is not floating-point
Fixes: CID1458152 Result is not floating-point
Fixes: CID1458154 Result is not floating-point
Fixes: CID1458155 Result is not floating-point
Fixes: CID1458156 Result is not floating-point
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit b98125e5a5 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:52:59 +01:00
Michael Niedermayer
072d22d402
avfilter/vf_v360: Assert that vf was initialized
...
Maybe helps: CID1504571 Uninitialized scalar variable
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit f802d65de0 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:52:59 +01:00
Michael Niedermayer
156ed79d28
avfilter/vf_tonemap_opencl: Dereference after NULL check
...
Fixes: CID1437472 Dereference before null check
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit e5c0f56ca0 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:52:58 +01:00
Michael Niedermayer
418c7e221d
avfilter/vf_xfade_opencl: Check ff_inlink_consume_frame() for failure
...
Fixes: CID1458127 Unchecked return value
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 43b62b7e0c )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:52:58 +01:00
Michael Niedermayer
b583dd4e44
avformat/lmlm4: Eliminate some AVERROR(EIO)
...
Found by code review related to CID732224 Overflowed constant
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
(cherry picked from commit 191a685010 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:52:58 +01:00
Michael Niedermayer
aea5aadc20
avformat/wtvdec: Check length of read mpeg2_descriptor
...
Fixes: Use of uninitialized value
Fixes: 70900/clusterfuzz-testcase-minimized-ffmpeg_dem_WTV_fuzzer-6286909377150976
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 >
(cherry picked from commit c390234da2 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:52:57 +01:00
Michael Niedermayer
3d9afae908
avformat/wtvdec: clear sectors
...
The code can leave uninitialized holes in the array.
Fixes: use of uninitialized values
Fixes: 70883/clusterfuzz-testcase-minimized-ffmpeg_dem_WTV_fuzzer-6698694567591936
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 >
(cherry picked from commit c95ea03104 )
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2025-02-27 17:52:52 +01:00
Janne Grunau
6cd0bdf3b0
vp9: recon: Use emulated edge to prevent buffer overflows
...
The arm/aarch64 horizontal filter reads one additional pixel beyond what
the filter uses. This can become an issue if the application does not
allocate larger buffers than what's required for the pixel data. If the
motion vector points to the bottom right edge of the picture this
becomes a read buffer overflow. This triggers segfaults in Firefox for
video resolutions which result in a page aligned picture size like
1280x640.
Prevent this by using emulated edge in this case.
Fixes: https://bugzilla.mozilla.org/show_bug.cgi?id=1881185
Signed-off-by: Janne Grunau <janne-ffmpeg@jannau.net >
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com >
(cherry picked from commit 060464105b )
2025-01-04 07:31:08 -05:00
Janne Grunau
131bd9436c
arm: vp9mc: Load only 12 pixels in the 4 pixel wide horizontal filter
...
This reduces the amount the horizontal filters read beyond the filter
width to a consistent 1 pixel. The data is not used so this is usually
not noticeable. It becomes a problem when the application allocates
frame buffers only for the aligned picture size and the end of it is at
a page boundary. This happens for picture sizes which are a multiple of
the page size like 1280x640. The frame buffer allocation is based on
its most likely done via mmap + MAP_ANONYMOUS so start and end of the
buffer are page aligned and the previous and next page are not
necessarily mapped.
This mirrors the aarch64 change.
Signed-off-by: Janne Grunau <janne-ffmpeg@jannau.net >
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com >
(cherry picked from commit f366256215 )
2025-01-04 07:31:08 -05:00
Janne Grunau
69107495c5
aarch64: vp9mc: Load only 12 pixels in the 4 pixel wide horizontal filter
...
This reduces the amount the horizontal filters read beyond the filter
width to a consistent 1 pixel. The data is not used so this is usually
not noticeable. It becomes a problem when the application allocates
frame buffers only for the aligned picture size and the end of it is at
a page boundary. This happens for picture sizes which are a multiple of
the page size like 1280x640. The frame buffer allocation is based on
its most likely done via mmap + MAP_ANONYMOUS so start and end of the
buffer are page aligned and the previous and next page are not
necessarily mapped.
Under these conditions like seen by Firefox a read beyond the end of the
buffer results in a segfault.
After the over-read is reduced to a single pixel it's reasonable to use
VP9's emulated edge motion compensation for this.
Fixes: https://bugzilla.mozilla.org/show_bug.cgi?id=1881185
Signed-off-by: Janne Grunau <janne-ffmpeg@jannau.net >
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com >
(cherry picked from commit 430c38f698 )
2025-01-04 07:31:08 -05:00
Marton Balint
c5a083a50b
avformat/libzmq: fix check for zmq protocol prefix
...
Fixes ticket #11134 .
Signed-off-by: Marton Balint <cus@passwd.hu >
(cherry picked from commit a87a96105e )
2024-09-02 23:32:05 +02:00
Ramiro Polla
4af46cabf6
configure: improve check for POSIX ioctl
...
Instead of relying on system #ifdefs which may or may not be correct,
detect the POSIX ioctl signature at configure time.
(cherry picked from commit 00b64fca55 )
Signed-off-by: Brad Smith <brad@comstyle.com >
2024-09-01 21:16:49 -04:00
Ramiro Polla
d67155005d
configure: restore autodetection of v4l2 and fbdev
...
The detection logic for v4l2 and fbdev was accidentally modified to
depend on v4l2-m2m in 43b3412 .
(cherry picked from commit 7405f1ad53 )
Signed-off-by: Brad Smith <brad@comstyle.com >
2024-09-01 21:16:23 -04:00