Skip to content

Commit

Permalink
Roll FFmpeg and update FFmpegDemuxer for security fixes.
Browse files Browse the repository at this point in the history
https://chromium.googlesource.com/chromium/third_party/ffmpeg.git/+log/9cb03e5705c1..18c815f81428

$ git log 9cb03e570..18c815f81 --date=short --no-merges --format='%ad %ae %s'
2017-11-28 dalecurtis Update chromium patches README with new patches.
2017-11-28 dalecurtis Free opus extradata before reallocating.
2017-11-28 dalecurtis Don't manipulate duration when it's AV_NOPTS_VALUE.
2017-11-28 dalecurtis Respect AVERROR codes returned by ogg parsers.
2017-11-25 michael avformat/aacdec: Fix leak in adts_aac_read_packet()

Inspection of code reveals that we don't properly ignore invalid codec
parameters when setting up the ffmpeg demuxer, so we will now explicitly
discard streams which don't have a codec detected.

Created with:
  roll-dep src/third_party/ffmpeg

BUG=788550,787803,773637,787351
TEST=ubsan/asan no longer fail.

Cq-Include-Trybots: master.tryserver.chromium.android:android_optional_gpu_tests_rel;master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel
Change-Id: I87b0482499e41b2c0190ef3852ed81c3e91c4236
Reviewed-on: https://chromium-review.googlesource.com/794844
Commit-Queue: Dale Curtis <dalecurtis@chromium.org>
Reviewed-by: Thomas Guilbert <tguilbert@chromium.org>
Cr-Commit-Position: refs/heads/master@{#519941}
  • Loading branch information
dalecurtis authored and Commit Bot committed Nov 29, 2017
1 parent ae26e11 commit 415212d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion DEPS
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,7 @@ deps = {
},

'src/third_party/ffmpeg':
Var('chromium_git') + '/chromium/third_party/ffmpeg.git' + '@' + '9cb03e5705c1bcff7cdaace0e8f55d79374e24b6',
Var('chromium_git') + '/chromium/third_party/ffmpeg.git' + '@' + '18c815f81428e3b41e6f4efc6cb0cbe5b846d1c2',

'src/third_party/findbugs': {
'url': Var('chromium_git') + '/chromium/deps/findbugs.git' + '@' + '4275d9ac8610db6b1bc9a5e887f97e41b33fac67',
Expand Down
5 changes: 5 additions & 0 deletions media/filters/ffmpeg_demuxer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1283,6 +1283,11 @@ void FFmpegDemuxer::OnFindStreamInfoDone(const PipelineStatusCB& status_cb,
const AVCodecParameters* codec_parameters = stream->codecpar;
const AVMediaType codec_type = codec_parameters->codec_type;
const AVCodecID codec_id = codec_parameters->codec_id;
// Skip streams which are not properly detected.
if (codec_id == AV_CODEC_ID_NONE) {
stream->discard = AVDISCARD_ALL;
continue;
}

if (codec_type == AVMEDIA_TYPE_AUDIO) {
// Log the codec detected, whether it is supported or not, and whether or
Expand Down

0 comments on commit 415212d

Please sign in to comment.