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 9744E40FB2 for ; Mon, 14 Mar 2022 14:04:52 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id BFB7868A800; Mon, 14 Mar 2022 16:04:49 +0200 (EET) Received: from relay11.mail.gandi.net (relay11.mail.gandi.net [217.70.178.231]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id A61F86802C3 for ; Mon, 14 Mar 2022 16:04:42 +0200 (EET) Received: from localhost (213-47-68-29.cable.dynamic.surfer.at [213.47.68.29]) (Authenticated sender: michael@niedermayer.cc) by mail.gandi.net (Postfix) with ESMTPSA id 0910510000D for ; Mon, 14 Mar 2022 14:04:41 +0000 (UTC) Date: Mon, 14 Mar 2022 15:04:41 +0100 From: Michael Niedermayer To: FFmpeg development discussions and patches Message-ID: <20220314140441.GY2829255@pb2> References: <20220312235227.19626-1-michael@niedermayer.cc> MIME-Version: 1.0 In-Reply-To: Subject: Re: [FFmpeg-devel] [PATCH 1/4] avcodec/vp9_superframe_split_bsf: Check in size 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="===============3568804900229597476==" Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: --===============3568804900229597476== Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="X51Q9b2QBq9OhetX" Content-Disposition: inline --X51Q9b2QBq9OhetX Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Mar 13, 2022 at 04:03:42PM -0300, James Almer wrote: >=20 >=20 > On 3/12/2022 8:52 PM, Michael Niedermayer wrote: > > Fixes: Out of array read > > Fixes: 45137/clusterfuzz-testcase-minimized-ffmpeg_BSF_VP9_SUPERFRAME_S= PLIT_fuzzer-4984270639202304 > >=20 > > Found-by: continuous fuzzing process https://github.com/google/oss-fuzz= /tree/master/projects/ffmpeg > > Signed-off-by: Michael Niedermayer > > --- > > libavcodec/vp9_superframe_split_bsf.c | 5 +++++ > > 1 file changed, 5 insertions(+) > >=20 > > diff --git a/libavcodec/vp9_superframe_split_bsf.c b/libavcodec/vp9_sup= erframe_split_bsf.c > > index ed0444561a..6af555c078 100644 > > --- a/libavcodec/vp9_superframe_split_bsf.c > > +++ b/libavcodec/vp9_superframe_split_bsf.c > > @@ -51,6 +51,11 @@ static int vp9_superframe_split_filter(AVBSFContext = *ctx, AVPacket *out) > > return ret; > > in =3D s->buffer_pkt; > > + if (in->size =3D=3D 0) { >=20 > !in->size I favor checking "=3D=3D 0" when its about the value 0 and !X when its about something being not set / not allocated. but i can change it if you prefer thx [...] --=20 Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB The smallest minority on earth is the individual. Those who deny=20 individual rights cannot claim to be defenders of minorities. - Ayn Rand --X51Q9b2QBq9OhetX Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iF0EABEIAB0WIQSf8hKLFH72cwut8TNhHseHBAsPqwUCYi9LeAAKCRBhHseHBAsP q12hAJ99tWticAYL/GYQwGKHAAeKvgQL4gCePxIGb+ZptlwhddGl57nlIt8PYsc= =mzN1 -----END PGP SIGNATURE----- --X51Q9b2QBq9OhetX-- --===============3568804900229597476== 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". --===============3568804900229597476==--