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 76B1742FDF for ; Fri, 13 Jan 2023 10:15:27 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 0A60168B6B1; Fri, 13 Jan 2023 12:15:24 +0200 (EET) Received: from mail-ua1-f45.google.com (mail-ua1-f45.google.com [209.85.222.45]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 6B106680677 for ; Fri, 13 Jan 2023 12:15:17 +0200 (EET) Received: by mail-ua1-f45.google.com with SMTP id z23so5193329uae.7 for ; Fri, 13 Jan 2023 02:15:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=to:subject:message-id:date:from:references:in-reply-to:mime-version :from:to:cc:subject:date:message-id:reply-to; bh=WbCSrueqq+goKPb3e0mkRdB814PMxoyy4kTnFjSKC+o=; b=IwISAY09d1v8IUocmhYmTLrQ8Z4BS1oar/TldYrX269W6YcwaEfaedCYyDsIKg9leg 1WvFYDsf95JlYwO6Zsaa6Mocx5ZU1HDx+9Q5Hj1LVo0SCg3zqxxnESg1856aMp1BUder OzXlTtQtBgSPH5AJlhjaLlwO3TN1T0orsY3PlW4SlZ2irNzlp4eMS+5Qs9kX4ZOYavv6 /Y7nuBm6Id3sB/s2HsEnJzU9C6qvEL87KWFgk5Iyk76uLiI5KHv7Vis6pQbZIA4WWCeQ AlqTSxY6K3GellWSjni4JPw+4F6KJKSFQvuWfdk5cbJr5fxt/S1ESG0YSIYy4uUrZkJZ Tabg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=to:subject:message-id:date:from:references:in-reply-to:mime-version :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=WbCSrueqq+goKPb3e0mkRdB814PMxoyy4kTnFjSKC+o=; b=ytHNaiwZ8D6njFzNeyfAxIA6+0c/fRzagWpBJKoZ+9JrVlWy1o9FatDivJvlH5K6Z6 7QZFvaZOCJfUCtOV0fQfh+wOdM67x/bMMV7olZRa44c7v0LdpBvFkYdX+oFp8s4TaefJ FcDqxp8xnJoZkgYR/pqZfJ7cfIwaEYeliJ8za3KDdoskr5IFf2JBp3Lt44WFQW+txu4S 5z6F9nNepNUfYYZXoLpRAIaZ/ygTJRyVkOqodSOqdXobU01WDmc6FEOhjrnc8IkH5hQD srw3WstHqxv2fLuM40XJx8/G3AgJChZtGdSjDIwwW6jnfa2yqUuTC8bPHDh0i+RIoDik EVLA== X-Gm-Message-State: AFqh2kqvDIEc5BtfHrUQ8JA7VCA45XttcQoz6aEwzzQZ3aZYDYIKBa9F 0GFnqnw/r3jV4AT/CRh5WiphfTKGg1x9pjh9EZQ2rwZ6 X-Google-Smtp-Source: AMrXdXs8JLnTKvAOo/H29NYM/wRgntmuqboU2J0yLLg9jz+MQmJJ41ImmUJOsEllHIkGTP6WCqMOEiwu1lBj/rl5pnk= X-Received: by 2002:ab0:1547:0:b0:418:f948:259f with SMTP id p7-20020ab01547000000b00418f948259fmr8544122uae.38.1673604915628; Fri, 13 Jan 2023 02:15:15 -0800 (PST) MIME-Version: 1.0 Received: by 2002:a05:612c:2428:b0:32a:5eaa:92e4 with HTTP; Fri, 13 Jan 2023 02:15:14 -0800 (PST) In-Reply-To: <20230113000138.9994-5-michael@niedermayer.cc> References: <20230113000138.9994-1-michael@niedermayer.cc> <20230113000138.9994-5-michael@niedermayer.cc> From: Paul B Mahol Date: Fri, 13 Jan 2023 11:15:14 +0100 Message-ID: To: FFmpeg development discussions and patches Subject: Re: [FFmpeg-devel] [PATCH 5/5] avcodec/sonic: avoid integer overflow on quantization parameter 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: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: On 1/13/23, Michael Niedermayer wrote: > Fixes: signed integer overflow: -1094995529 * 16 cannot be represented in > type 'int' > Fixes: > 48567/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_SONIC_fuzzer-6681622236233728 > > Found-by: continuous fuzzing process > https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg > Signed-off-by: Michael Niedermayer > --- > libavcodec/sonic.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/libavcodec/sonic.c b/libavcodec/sonic.c > index 77bdb418a7..95ac2b1a96 100644 > --- a/libavcodec/sonic.c > +++ b/libavcodec/sonic.c > @@ -1013,7 +1013,7 @@ static int sonic_decode_frame(AVCodecContext *avctx, > AVFrame *frame, > if (s->lossless) > quant = 1; > else > - quant = get_symbol(&c, state, 0) * SAMPLE_FACTOR; > + quant = get_symbol(&c, state, 0) * (unsigned)SAMPLE_FACTOR; > > // av_log(NULL, AV_LOG_INFO, "quant: %d\n", quant); > > -- > 2.17.1 > You are pointlessly wasting resources on broken bonk clone. > _______________________________________________ > 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". > _______________________________________________ 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".