commit | b66884f4aa6701a842bb83b407d546cdb76320d9 | [log] [tgz] |
---|---|---|
author | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | Wed May 27 19:09:14 2020 +0200 |
committer | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | Fri Jul 03 00:04:06 2020 +0200 |
tree | ca56b6b071886c839e362cb07e3e0946295e9a68 | |
parent | a3a2e782c2ab5ccfcd864f476e6c3b7aa03c8dcf [diff] |
avcodec/hevc_mp4toannexb_bsf: Check NAL size against available input The hevc_mp4toannexb bsf does not explicitly check whether a NAL unit is so big that it extends beyond the end of the input packet; it does so only implicitly by using the checked version of the bytestream2 API. But this has downsides compared to real checks: It can lead to huge allocations (up to 2GiB) even when the input packet is just a few bytes. And furthermore it leads to uninitialized data being output. So add a check to error out early if it happens. Also check directly whether there is enough data for the length field. Reviewed-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com> (cherry picked from commit ea1b71e82f5a1752d59d3bfb9704092a79eba6b5) Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
FFmpeg is a collection of libraries and tools to process multimedia content such as audio, video, subtitles and related metadata.
libavcodec
provides implementation of a wider range of codecs.libavformat
implements streaming protocols, container formats and basic I/O access.libavutil
includes hashers, decompressors and miscellaneous utility functions.libavfilter
provides a mean to alter decoded Audio and Video through chain of filters.libavdevice
provides an abstraction to access capture and playback devices.libswresample
implements audio mixing and resampling routines.libswscale
implements color conversion and scaling routines.aviocat
, ismindex
and qt-faststart
.The offline documentation is available in the doc/ directory.
The online documentation is available in the main website and in the wiki.
Coding examples are available in the doc/examples directory.
FFmpeg codebase is mainly LGPL-licensed with optional components licensed under GPL. Please refer to the LICENSE file for detailed information.
Patches should be submitted to the ffmpeg-devel mailing list using git format-patch
or git send-email
. Github pull requests should be avoided because they are not part of our review process and will be ignored.