From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTP id E64EC4C838 for ; Wed, 7 Aug 2024 00:02:29 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 25CAB68DAC2; Wed, 7 Aug 2024 03:02:28 +0300 (EEST) Received: from mx.sdf.org (mx.sdf.org [205.166.94.24]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 5A7AA68DA25 for ; Wed, 7 Aug 2024 03:02:21 +0300 (EEST) Received: from 7ba90722f570c2b0104f5b8afe4fa274 ([1.152.186.235]) (authenticated (0 bits)) by mx.sdf.org (8.18.1/8.14.3) with ESMTPSA id 47702F89027403 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits) verified NO) for ; Wed, 7 Aug 2024 00:02:19 GMT Date: Wed, 7 Aug 2024 10:02:09 +1000 From: Peter Ross To: FFmpeg development discussions and patches Message-ID: Mail-Followup-To: FFmpeg development discussions and patches References: <20240806221853.959177-1-michael@niedermayer.cc> <20240806221853.959177-6-michael@niedermayer.cc> MIME-Version: 1.0 In-Reply-To: <20240806221853.959177-6-michael@niedermayer.cc> Subject: Re: [FFmpeg-devel] [PATCH 6/6] avformat/wtvdec: Check length of read mpeg2_descriptor X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Content-Type: multipart/mixed; boundary="===============6778973520600027018==" Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: --===============6778973520600027018== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="aDyLL1XSHURzTV4o" Content-Disposition: inline --aDyLL1XSHURzTV4o Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Aug 07, 2024 at 12:18:53AM +0200, Michael Niedermayer wrote: > Fixes: Use of uninitialized value > Fixes: 70900/clusterfuzz-testcase-minimized-ffmpeg_dem_WTV_fuzzer-6286909= 377150976 >=20 > Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/t= ree/master/projects/ffmpeg > Signed-off-by: Michael Niedermayer > --- > libavformat/wtvdec.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) >=20 > diff --git a/libavformat/wtvdec.c b/libavformat/wtvdec.c > index 1a6c4c33481..730c7fca783 100644 > --- a/libavformat/wtvdec.c > +++ b/libavformat/wtvdec.c > @@ -846,7 +846,8 @@ static int parse_chunks(AVFormatContext *s, int mode,= int64_t seekts, int *len_p > } > =20 > buf_size =3D FFMIN(len - consumed, sizeof(buf)); > - avio_read(pb, buf, buf_size); > + if (avio_read(pb, buf, buf_size) !=3D buf_size) > + return AVERROR_INVALIDDATA; > consumed +=3D buf_size; > ff_parse_mpeg2_descriptor(s, st, 0, &pbuf, buf + buf_siz= e, NULL, 0, 0, NULL); > } please apply -- Peter (A907 E02F A6E5 0CD2 34CD 20D2 6760 79C5 AC40 DD6B) --aDyLL1XSHURzTV4o Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iF0EABECAB0WIQSpB+AvpuUM0jTNINJnYHnFrEDdawUCZrK5gQAKCRBnYHnFrEDd a2KXAJ9JQchfTSxc5hFf4dCjxcCibKAmawCfcsGcKUdLcHsNO3N86k8l0bfUr4c= =rZgV -----END PGP SIGNATURE----- --aDyLL1XSHURzTV4o-- --===============6778973520600027018== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe". --===============6778973520600027018==--