[FFmpeg-cvslog] avformat/oggparseogm: Check lb against psize
ffmpeg | branch: release/2.8 | Michael Niedermayer | Fri Mar 9 01:05:20 2018 +0100| [6b51dc9223460b40b14c2c61187b135fb690ebb7] | committer: Michael Niedermayer avformat/oggparseogm: Check lb against psize No testcase, this was found during code review Found-by: Matt Wolenetz Reviewed-by: Matt Wolenetz Signed-off-by: Michael Niedermayer (cherry picked from commit 3e7c847aaf5a298b62afae12b4ecfb8e12385998) Signed-off-by: Michael Niedermayer > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=6b51dc9223460b40b14c2c61187b135fb690ebb7 --- libavformat/oggparseogm.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/libavformat/oggparseogm.c b/libavformat/oggparseogm.c index f03dedaf2c..573fb99dd0 100644 --- a/libavformat/oggparseogm.c +++ b/libavformat/oggparseogm.c @@ -170,6 +170,9 @@ ogm_packet(AVFormatContext *s, int idx) os->pflags |= AV_PKT_FLAG_KEY; lb = ((*p & 2) << 1) | ((*p >> 6) & 3); +if (os->psize < lb + 1) +return AVERROR_INVALIDDATA; + os->pstart += lb + 1; os->psize -= lb + 1; ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avformat/oggparseogm: Check lb against psize
ffmpeg | branch: release/3.3 | Michael Niedermayer| Fri Mar 9 01:05:20 2018 +0100| [e61cdbe27167434b87ff814769b54178c5a3d2a6] | committer: Michael Niedermayer avformat/oggparseogm: Check lb against psize No testcase, this was found during code review Found-by: Matt Wolenetz Reviewed-by: Matt Wolenetz Signed-off-by: Michael Niedermayer (cherry picked from commit 3e7c847aaf5a298b62afae12b4ecfb8e12385998) Signed-off-by: Michael Niedermayer > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=e61cdbe27167434b87ff814769b54178c5a3d2a6 --- libavformat/oggparseogm.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/libavformat/oggparseogm.c b/libavformat/oggparseogm.c index 4d09d174b8..03499486f7 100644 --- a/libavformat/oggparseogm.c +++ b/libavformat/oggparseogm.c @@ -177,6 +177,9 @@ ogm_packet(AVFormatContext *s, int idx) os->pflags |= AV_PKT_FLAG_KEY; lb = ((*p & 2) << 1) | ((*p >> 6) & 3); +if (os->psize < lb + 1) +return AVERROR_INVALIDDATA; + os->pstart += lb + 1; os->psize -= lb + 1; ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avformat/oggparseogm: Check lb against psize
ffmpeg | branch: master | Michael Niedermayer| Fri Mar 9 01:05:20 2018 +0100| [3e7c847aaf5a298b62afae12b4ecfb8e12385998] | committer: Michael Niedermayer avformat/oggparseogm: Check lb against psize No testcase, this was found during code review Found-by: Matt Wolenetz Reviewed-by: Matt Wolenetz Signed-off-by: Michael Niedermayer > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=3e7c847aaf5a298b62afae12b4ecfb8e12385998 --- libavformat/oggparseogm.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/libavformat/oggparseogm.c b/libavformat/oggparseogm.c index 4b4edf26ca..a07453760b 100644 --- a/libavformat/oggparseogm.c +++ b/libavformat/oggparseogm.c @@ -176,6 +176,9 @@ ogm_packet(AVFormatContext *s, int idx) os->pflags |= AV_PKT_FLAG_KEY; lb = ((*p & 2) << 1) | ((*p >> 6) & 3); +if (os->psize < lb + 1) +return AVERROR_INVALIDDATA; + os->pstart += lb + 1; os->psize -= lb + 1; ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog