From patchwork Thu Nov 13 12:06:08 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gyorgy Sarvari X-Patchwork-Id: 74397 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id B8A3BCD5BDE for ; Thu, 13 Nov 2025 12:06:17 +0000 (UTC) Received: from mail-wr1-f54.google.com (mail-wr1-f54.google.com [209.85.221.54]) by mx.groups.io with SMTP id smtpd.msgproc01-g2.22279.1763035574912667059 for ; Thu, 13 Nov 2025 04:06:15 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=SHfXYyhX; spf=pass (domain: gmail.com, ip: 209.85.221.54, mailfrom: skandigraun@gmail.com) Received: by mail-wr1-f54.google.com with SMTP id ffacd0b85a97d-42b3377aaf2so444401f8f.2 for ; Thu, 13 Nov 2025 04:06:14 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1763035573; x=1763640373; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:message-id:date:subject:to :from:from:to:cc:subject:date:message-id:reply-to; bh=4EsJqjXdMuu8W6PDoffbyPWJXeqckiJq1VsIqEt1AEc=; b=SHfXYyhX/dhOFaFgQ3jGUUTx5xG7xyeuhkHAe0XhTFNKH4tFURrcn9LMv+DBAYRHkZ Uakn7wDukNCyRTEULfsLzx7EGW3wToFY9dVe/g3vLoIbXAL5AH/fRyeYVVVqeCP5Gl4H pe5sHvJQw4UjlAB2xOI01vID6tnqoxbWlVmTVx5qzUgVjIVYIQuyp64VwdJg+R7IOI+q LqB1TUtBHD7rdhGBTjEHnvWXmdpA/xFoq4AwV6ZqYQEvqwBnRNgl8tXjeuccab3+yvn/ eG9+1fPjsb4+cnNV7q+MTNztke/9lKRst4jxH1nY93umc9DG4w08kmmjROI4YzmMtI+g DZ1Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763035573; x=1763640373; h=content-transfer-encoding:mime-version:message-id:date:subject:to :from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=4EsJqjXdMuu8W6PDoffbyPWJXeqckiJq1VsIqEt1AEc=; b=BcYv2OU/3jdvw8xtiHyvmERK7BBr2Zvlch5QUNnap/5EQEqydXEaO4pDWrdhoKoDFq vY7sNcGyBYZVN4JhICd6TxF4IbcOJ1dsuq+G6IAj1XWIEduitYciBLM8CSpqwKK+/ZSw vkQ4bUTcZx4LwAC4dOnIev8R6Wtiqayk0viYuRCZr15NktxQXQKvYPQzxbpfWo3jCRNa pzF+YiHQJvjpxzgSfWaqG7hqsWi8JE2qp9LRhVWSsqXFqgKiZavBfMA2RulGShCK8aKp svjYg4lboUiQ+1bbC1uF9dMC81T5rfbtWldftDrGNKsy5Dwld6Mw7iMw/FlomDKDpiZD D9Wg== X-Gm-Message-State: AOJu0YxuQvc8tK0lFMxnxyMuYGHm3EmXizOU3W1pAgQKe2rU/NEZbBYl SqrTEcLCrhv1ethsAo8jFH4Gjfu8VR+BtZpRYuVNTukgxow8O3xbX8smF8ci9gRG X-Gm-Gg: ASbGncsnkREnA0PsNCjfHlCgq20U+U8vLMFm05SZGcLW+vKYptka+HXwVQL77L8jCNY FXandFYxgnHdW1DjqYD8xCk+DEOpKDjzQxkLllLkRJMJju8LJOnxGN+cSSNkxUTlCyOW5sP1S1e HKlDLjhm7ZdsnpzIk1MzxQdjFhUuqmf+UfIDYHdUCvu3Z91S5Rtzzg84bCr1+v6OKigRK1wzq9o +Yv6GsiD46fhW7542htuNMxuf+ITMAjWNTrTLTU3ljD3waugppUIrY6Fpdgkl+G3B83ngbyUWEp 8a3WXrgDakG2bFsiKQJAMTUeqHULM2t9XQT7rLoEvbWTV1ciFAJKHSYAYd6DLmaWICayeauU0IS VWSQxyM59Ck9aDx+BkRbLZn6GB6s46ggow1IT0881XqJxZkqwjrpxIp04UUSY8FMSuWMeWtXOXg == X-Google-Smtp-Source: AGHT+IFYBm9OS1mP6hlHmz4/lzVku7kaujT+HTvQmkLxgyVLRPOc27LxPn2IBhmZ6gcWv5imRb1Rqw== X-Received: by 2002:a5d:5d0a:0:b0:429:d3c9:b889 with SMTP id ffacd0b85a97d-42b4bb8f18dmr5764570f8f.1.1763035572885; Thu, 13 Nov 2025 04:06:12 -0800 (PST) Received: from desktop ([51.154.145.205]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-42b53e85627sm3974561f8f.16.2025.11.13.04.06.12 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 13 Nov 2025 04:06:12 -0800 (PST) From: Gyorgy Sarvari To: openembedded-devel@lists.openembedded.org Subject: [meta-oe][PATCH 1/4] audiofile: patch CVE-2019-13147 and CVE-2022-24599 Date: Thu, 13 Nov 2025 13:06:08 +0100 Message-ID: <20251113120611.2590707-1-skandigraun@gmail.com> X-Mailer: git-send-email 2.51.2 MIME-Version: 1.0 List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 13 Nov 2025 12:06:17 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-devel/message/121645 Details: https://nvd.nist.gov/vuln/detail/CVE-2019-13147 https://nvd.nist.gov/vuln/detail/CVE-2022-24599 These patches are used by opensuse to mitigate the corresponding vulnerabulities. Signed-off-by: Gyorgy Sarvari --- .../audiofile/audiofile_0.3.6.bb | 2 + .../audiofile/files/CVE-2019-13147.patch | 31 ++++++++++++ .../audiofile/files/CVE-2022-24599.patch | 50 +++++++++++++++++++ 3 files changed, 83 insertions(+) create mode 100644 meta-oe/recipes-multimedia/audiofile/files/CVE-2019-13147.patch create mode 100644 meta-oe/recipes-multimedia/audiofile/files/CVE-2022-24599.patch diff --git a/meta-oe/recipes-multimedia/audiofile/audiofile_0.3.6.bb b/meta-oe/recipes-multimedia/audiofile/audiofile_0.3.6.bb index 50df31c7b9..fd80729bd2 100644 --- a/meta-oe/recipes-multimedia/audiofile/audiofile_0.3.6.bb +++ b/meta-oe/recipes-multimedia/audiofile/audiofile_0.3.6.bb @@ -18,6 +18,8 @@ SRC_URI = " \ file://0006-Check-for-multiplication-overflow-in-sfconvert.patch \ file://0007-Actually-fail-when-error-occurs-in-parseFormat.patch \ file://0008-Check-for-multiplication-overflow-in-MSADPCM-decodeS.patch \ + file://CVE-2019-13147.patch \ + file://CVE-2022-24599.patch \ " SRC_URI[sha256sum] = "ea2449ad3f201ec590d811db9da6d02ffc5e87a677d06b92ab15363d8cb59782" diff --git a/meta-oe/recipes-multimedia/audiofile/files/CVE-2019-13147.patch b/meta-oe/recipes-multimedia/audiofile/files/CVE-2019-13147.patch new file mode 100644 index 0000000000..19f6892f69 --- /dev/null +++ b/meta-oe/recipes-multimedia/audiofile/files/CVE-2019-13147.patch @@ -0,0 +1,31 @@ +This patch is taken from opensuse: +https://build.opensuse.org/package/show/multimedia:libs/audiofile + +CVE: CVE-2019-13147 +Upstream-Status: Inactive-Upstream [lastcommit: 2016-Aug-30] +Signed-off-by: Gyorgy Sarvari + +diff --unified --recursive --text --new-file --color audiofile-0.3.6/libaudiofile/NeXT.cpp audiofile-0.3.6.new/libaudiofile/NeXT.cpp +--- audiofile-0.3.6/libaudiofile/NeXT.cpp 2013-03-06 13:30:03.000000000 +0800 ++++ audiofile-0.3.6.new/libaudiofile/NeXT.cpp 2025-05-14 10:45:11.685700984 +0800 +@@ -32,6 +32,7 @@ + #include + #include + #include ++#include + + #include "File.h" + #include "Setup.h" +@@ -122,6 +123,12 @@ + _af_error(AF_BAD_CHANNELS, "invalid file with 0 channels"); + return AF_FAIL; + } ++ /* avoid overflow of INT for double size rate */ ++ if (channelCount > (INT32_MAX / (sizeof(double)))) ++ { ++ _af_error(AF_BAD_CHANNELS, "invalid file with %i channels", channelCount); ++ return AF_FAIL; ++ } + + Track *track = allocateTrack(); + if (!track) diff --git a/meta-oe/recipes-multimedia/audiofile/files/CVE-2022-24599.patch b/meta-oe/recipes-multimedia/audiofile/files/CVE-2022-24599.patch new file mode 100644 index 0000000000..9214d80172 --- /dev/null +++ b/meta-oe/recipes-multimedia/audiofile/files/CVE-2022-24599.patch @@ -0,0 +1,50 @@ +This patch is taken from opensuse: +https://build.opensuse.org/package/show/multimedia:libs/audiofile + +CVE: CVE-2022-24599 +Upstream-Status: Inactive-Upstream [lastcommit: 2016-Aug-30] +Signed-off-by: Gyorgy Sarvari + +diff --unified --recursive --text --new-file --color audiofile-0.3.6.old/sfcommands/printinfo.c audiofile-0.3.6.new/sfcommands/printinfo.c +--- audiofile-0.3.6.old/sfcommands/printinfo.c 2013-03-06 13:30:03.000000000 +0800 ++++ audiofile-0.3.6.new/sfcommands/printinfo.c 2025-04-30 15:18:24.778177640 +0800 +@@ -37,6 +37,7 @@ + #include + #include + #include ++#include + + static char *copyrightstring (AFfilehandle file); + +@@ -147,7 +148,11 @@ + int i, misccount; + + misccount = afGetMiscIDs(file, NULL); +- miscids = (int *) malloc(sizeof (int) * misccount); ++ if (!misccount) ++ return NULL; ++ miscids = (int *)calloc(misccount, sizeof(int)); ++ if (!miscids) ++ return NULL; + afGetMiscIDs(file, miscids); + + for (i=0; i= INT_MAX - 1) ++ goto error; ++ char *data = (char *)calloc(datasize + 1, sizeof(char)); + afReadMisc(file, miscids[i], data, datasize); + copyright = data; + break; + } + ++error: + free(miscids); + + return copyright; From patchwork Thu Nov 13 12:06:09 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gyorgy Sarvari X-Patchwork-Id: 74395 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id BC64BCD5BD0 for ; Thu, 13 Nov 2025 12:06:17 +0000 (UTC) Received: from mail-wr1-f49.google.com (mail-wr1-f49.google.com [209.85.221.49]) by mx.groups.io with SMTP id smtpd.msgproc01-g2.22280.1763035575337238461 for ; Thu, 13 Nov 2025 04:06:15 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=gv3V9cp7; spf=pass (domain: gmail.com, ip: 209.85.221.49, mailfrom: skandigraun@gmail.com) Received: by mail-wr1-f49.google.com with SMTP id ffacd0b85a97d-42b312a086eso464372f8f.2 for ; Thu, 13 Nov 2025 04:06:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1763035574; x=1763640374; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=DcdEhpqtBjaPHneM0UqalSyeVPfZIhlC7Bue4mYh1F0=; b=gv3V9cp7sZgQT7nhAamq0ur4Gn2udlMOzz99Ztk9DF+myS1q6OInvPxQTJeIeXAWYy xJxR9Pzh6sn4Fotlve+O1KrphfwUUStdFA2FgP5Pl2Rk5Rxcxw1sivWTD0MY458Gy7J5 6Yam4nz6zzt5vI4YOBEDlASNEaLIhb4Gs//AnfNZweQqicRYm/V5VXAEhYn8XPJZ18CS /KHJQA31e1KsIxOrQ2L6zvX2ciJPmmuULeH9XaTUOLZLve75/WsRuVjkTgZrZjNfTN8q pMQW23Q0cbHtcZYuTHplqijQVv4MQhveHhjztKIzZE+L2J1viv99a1+BpQiF2qstCiE6 B18g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763035574; x=1763640374; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=DcdEhpqtBjaPHneM0UqalSyeVPfZIhlC7Bue4mYh1F0=; b=PKVJjZWtwy90KkF3Nw2C7bljpjC1kY5TWP0tf4eRicL0Oum4RlhAOFN8TJKZsTO6in W0v/sX+MqrwrfyMMWTejCoCxmnzYXklpMi6v6QMAMxzXdOYam5cj2YMG+U2eN14o5QbO Fw0/perAWi9W1BSTdglVwxagM9igRuAg2MD6yFvYUVwqhyelb4XM28sOGkTyYMJ+s8Bg AHmUKZeWZ20d7qFnh3XTSEIjXxMMMIsUpJvBq7Xh6+sfgKQQ3PmB59PBes+a6n2PV9G1 DExyobPtQqOptoc8mlYQSgLtKsDpbrikUdsDqqfAw8dPTJy/4t9sRNQtSQjtDWmZ2rgA NOyw== X-Gm-Message-State: AOJu0YyE95sXHRXqPw5PJUHsc4EFI0TMQNdbzgCqwEJjO5d6E5y0HlaX q56cLtNR9DHM2RV48Ol9/r32rMgNdoBAHK2IWDd1okGGpqtp2p70I+vsQefB81ih X-Gm-Gg: ASbGncsTWMSJ5AQ4ZYphlB2y1FLTcHu/MQ6aaY/gFJ71NOn3gQn0Qezaxnbj0IY3cXl /ONpXSHfdo0DCD4OTJkccJuyr7lW3T8IxkSj4OvRE6xUFZoOgt9fgXHUUcfrA0RjAvawecIZlWq WAdMvup+9TSPttirPj5My2L00oT6LiFsU1htBK+ULMKxKtzolLS6Zpf/OUMXW69aYBy+tA7xjb9 om9TA1d0xiumDyMXBG13FZZ6Yv5EPnBSGIyaGPh7OKCf/kLVWrIPHaNQPGmK0u0KstrRP4o6P/t Dan3AsA3zLsHGShDAHzrLjQTkErnPsxo3xww7JX8/YCNGxHewku70vUlnZ9WZaQjwtzUUhMDAQW Z5l0JNie02psjvx+ew5zsDgFNYZCAtd9ST9KMOsfBkLSBfhb+liGHAAuYmqZv9vrMf8+YlY1p1w == X-Google-Smtp-Source: AGHT+IGE6sziIUBwtw4v7LUanJqapt3tDHZ4tKJnK3VNn80Jnxf/mA8zygyUFw0AX2nGsRQwM8pWLg== X-Received: by 2002:a05:6000:2c0b:b0:429:b9bc:e826 with SMTP id ffacd0b85a97d-42b4bdd4273mr7090864f8f.53.1763035573584; Thu, 13 Nov 2025 04:06:13 -0800 (PST) Received: from desktop ([51.154.145.205]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-42b53e85627sm3974561f8f.16.2025.11.13.04.06.13 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 13 Nov 2025 04:06:13 -0800 (PST) From: Gyorgy Sarvari To: openembedded-devel@lists.openembedded.org Subject: [meta-oe][PATCH 2/4] audiofile: add ptest support Date: Thu, 13 Nov 2025 13:06:09 +0100 Message-ID: <20251113120611.2590707-2-skandigraun@gmail.com> X-Mailer: git-send-email 2.51.2 In-Reply-To: <20251113120611.2590707-1-skandigraun@gmail.com> References: <20251113120611.2590707-1-skandigraun@gmail.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 13 Nov 2025 12:06:17 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-devel/message/121646 It's under 15 seconds to execute it. Signed-off-by: Gyorgy Sarvari --- .../include/ptest-packagelists-meta-oe.inc | 1 + .../audiofile/audiofile_0.3.6.bb | 18 +++++++++++++++++- .../audiofile/files/run-ptest | 14 ++++++++++++++ 3 files changed, 32 insertions(+), 1 deletion(-) create mode 100644 meta-oe/recipes-multimedia/audiofile/files/run-ptest diff --git a/meta-oe/conf/include/ptest-packagelists-meta-oe.inc b/meta-oe/conf/include/ptest-packagelists-meta-oe.inc index 1d5932c315..96e0d87bd4 100644 --- a/meta-oe/conf/include/ptest-packagelists-meta-oe.inc +++ b/meta-oe/conf/include/ptest-packagelists-meta-oe.inc @@ -8,6 +8,7 @@ # ptests which take less than ~30s each PTESTS_FAST_META_OE = "\ asio \ + audiofile \ cli11 \ cmocka \ cunit \ diff --git a/meta-oe/recipes-multimedia/audiofile/audiofile_0.3.6.bb b/meta-oe/recipes-multimedia/audiofile/audiofile_0.3.6.bb index fd80729bd2..f734a41dfc 100644 --- a/meta-oe/recipes-multimedia/audiofile/audiofile_0.3.6.bb +++ b/meta-oe/recipes-multimedia/audiofile/audiofile_0.3.6.bb @@ -10,6 +10,7 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c \ SRC_URI = " \ ${GNOME_MIRROR}/audiofile/0.3/${BP}.tar.xz \ + file://run-ptest \ file://0001-fix-negative-shift-constants.patch \ file://0002-fix-build-on-gcc6.patch \ file://0003-fix-CVE-2015-7747.patch \ @@ -23,7 +24,7 @@ SRC_URI = " \ " SRC_URI[sha256sum] = "ea2449ad3f201ec590d811db9da6d02ffc5e87a677d06b92ab15363d8cb59782" -inherit autotools lib_package pkgconfig +inherit autotools lib_package pkgconfig ptest CXXFLAGS += "-std=c++14" @@ -33,3 +34,18 @@ DEPENDS = " \ libogg \ flac \ " + +do_compile_ptest(){ + oe_runmake -C gtest libgtest.la + cd test + # Query the TESTS variable value, remove the $(...) parts from it, + # compile as make target along with FLAC (which is an optional test) + oe_runmake `make -p | grep "^TESTS = " | sed 's/$([^)]*)//g' | cut -d= -f2` FLAC +} + +do_install_ptest(){ + install -d ${D}${PTEST_PATH}/test + for t in test/.libs/*; do + install $t ${D}${PTEST_PATH}/test/ + done +} diff --git a/meta-oe/recipes-multimedia/audiofile/files/run-ptest b/meta-oe/recipes-multimedia/audiofile/files/run-ptest new file mode 100644 index 0000000000..cdf1677bde --- /dev/null +++ b/meta-oe/recipes-multimedia/audiofile/files/run-ptest @@ -0,0 +1,14 @@ +#!/bin/sh + +RES=0 +cd test +for t in *; do + if ./$t; then + echo PASS: $t + else + echo FAIL: $t + RES=1 + fi +done + +exit $RES From patchwork Thu Nov 13 12:06:10 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gyorgy Sarvari X-Patchwork-Id: 74396 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id C6E42CD6E42 for ; Thu, 13 Nov 2025 12:06:17 +0000 (UTC) Received: from mail-wr1-f42.google.com (mail-wr1-f42.google.com [209.85.221.42]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.22296.1763035576124838815 for ; Thu, 13 Nov 2025 04:06:16 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=VK5LzT4o; spf=pass (domain: gmail.com, ip: 209.85.221.42, mailfrom: skandigraun@gmail.com) Received: by mail-wr1-f42.google.com with SMTP id ffacd0b85a97d-42b3ad51fecso620519f8f.1 for ; Thu, 13 Nov 2025 04:06:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1763035574; x=1763640374; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=CdCnUfcnIBjT1DMWrwIO177HmSI6tBUzbPjZ7oi+wn8=; b=VK5LzT4oUkUQZa7u2ZeV4u3iAm2E9MhfdmeqJdecWUUApixWkYTz+d+8flVkx4qgG5 eG16mcIsfZCMPw49D5YVMBfy6vUzJXejAPyFP9y+1XEFgcMhX9kROqjzWjQkisDm+5YM 64HlKE5OvrCMXqVRPpLp9mMLXOPwEjvAyIBZoStV6iLSoTtwaDMuD6VLuy2Vr6aJZftt euRzly+zO8xj9wFGaAKx8KsSxrolOmGFggJHMF1CL1pyhGCpod4JQo0YX+7jQqWLHwLD qD0S7gT/t0Jqn1VESqo6nHTiesk1KqyF64uxaq3sEX4PJ5SBQoNODO2e+2EHE7dMtLkZ P+Jw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763035574; x=1763640374; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=CdCnUfcnIBjT1DMWrwIO177HmSI6tBUzbPjZ7oi+wn8=; b=ehpWRr2aewD+B6Hg0I46i4ZmANLa/HHk6co8ftm3RgT6kMZc4YMNEOZFQTsIbKjm1F k3+j2jyMM5UOHnFyYEPlXN9L1OVZ394NagHOJFpwHN0OuLv5qPizz75V+jZhN7sTi9LJ kghjPnD4DUzfE6hPmFN10DcWm+3g53udpwW5a1iQze5IKfslUK4h8U/9P/ExhFkwyv7l uw90awIZErcsIFtcuGxcczCsC4cgxlgVFTW7uw8yn6Jb6KSfCrwWtK0JwPgGijg3m0NQ 8dQ6JGVyZtF0eqKCileBTrJnDX2snDS+ZojhAHB4vCyrEA37T1dU6rZeL2r7bJxJ8Cal rdqw== X-Gm-Message-State: AOJu0YzopUbrlCYajFSh0EG11et8gcrrPspFmqIfvZ/yTHqlo5Wb75K0 j/f6bxPo7Gd8bsSygK0bpWL211xvQkN7/o+9OqsdJu+nhoAkNYztTCwjicDlTa3x X-Gm-Gg: ASbGncvJdQUYlDVFXshCdXT7tsOJR/H7srUg0Uxp2xLjsQqcqG5rj+esKu/FBvgbut3 vIA0FhoU43ZW/Wj6q0QRzTSWUdf3sKg9bZppyj1Un4HYZtlxlkCL7zbzOsbaJdf+xykxYXDi+ya l4FCmtOy0iHb/8z2S97yHH9e3Ch3YNw/vRdKZhXmq1UojD0wxBdZVsf7leSmrvPB85FM/dLhNWS 2GYOfQI3CNrW9QC0yQbI2Vprt3k8+fDbZf2meOg6+nE8dk356vMVTQ3/p8E+DqQlcMQuEfujSJx 1Kn8GrPntqjTsrkhlH+BHupj3kFEDpXygPH5CIUjr7WaN/atkoXRuZvCw2Wi4DsZJo3sZQMvEn7 80YhzToFk2ziQO+mO5QBnWp0ECYYQKatPbLrN6ZTBtuTZlwRSRDTFFqRojVW/WrZIjINdwr0KRH nUXGpU18FT X-Google-Smtp-Source: AGHT+IHJg3/zKCycYMovY2YbI0WWJ7jJ14llZWjJRXuFb1AfjbNIDEmKdGoUuZV3HIknMwngNo3e3A== X-Received: by 2002:a05:6000:651:b0:42b:41d3:daf9 with SMTP id ffacd0b85a97d-42b4bb91210mr4691928f8f.2.1763035574292; Thu, 13 Nov 2025 04:06:14 -0800 (PST) Received: from desktop ([51.154.145.205]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-42b53e85627sm3974561f8f.16.2025.11.13.04.06.13 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 13 Nov 2025 04:06:13 -0800 (PST) From: Gyorgy Sarvari To: openembedded-devel@lists.openembedded.org Subject: [meta-oe][PATCH 3/4] audiofile: backport test for CVE-2015-7747 Date: Thu, 13 Nov 2025 13:06:10 +0100 Message-ID: <20251113120611.2590707-3-skandigraun@gmail.com> X-Mailer: git-send-email 2.51.2 In-Reply-To: <20251113120611.2590707-1-skandigraun@gmail.com> References: <20251113120611.2590707-1-skandigraun@gmail.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 13 Nov 2025 12:06:17 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-devel/message/121647 This is a backported patch from opensuse, which contains a testcase for CVE-2015-7747 (which is already patched in ths recipe, but not tested explicitly). Signed-off-by: Gyorgy Sarvari --- .../audiofile/audiofile_0.3.6.bb | 1 + .../files/test-for-CVE-2015-7747.patch | 166 ++++++++++++++++++ 2 files changed, 167 insertions(+) create mode 100644 meta-oe/recipes-multimedia/audiofile/files/test-for-CVE-2015-7747.patch diff --git a/meta-oe/recipes-multimedia/audiofile/audiofile_0.3.6.bb b/meta-oe/recipes-multimedia/audiofile/audiofile_0.3.6.bb index f734a41dfc..b14b4792b3 100644 --- a/meta-oe/recipes-multimedia/audiofile/audiofile_0.3.6.bb +++ b/meta-oe/recipes-multimedia/audiofile/audiofile_0.3.6.bb @@ -19,6 +19,7 @@ SRC_URI = " \ file://0006-Check-for-multiplication-overflow-in-sfconvert.patch \ file://0007-Actually-fail-when-error-occurs-in-parseFormat.patch \ file://0008-Check-for-multiplication-overflow-in-MSADPCM-decodeS.patch \ + file://test-for-CVE-2015-7747.patch \ file://CVE-2019-13147.patch \ file://CVE-2022-24599.patch \ " diff --git a/meta-oe/recipes-multimedia/audiofile/files/test-for-CVE-2015-7747.patch b/meta-oe/recipes-multimedia/audiofile/files/test-for-CVE-2015-7747.patch new file mode 100644 index 0000000000..a62cc7589b --- /dev/null +++ b/meta-oe/recipes-multimedia/audiofile/files/test-for-CVE-2015-7747.patch @@ -0,0 +1,166 @@ +From 1debf51f3a89d44c0bd46e7bc45c07342087dd7c Mon Sep 17 00:00:00 2001 +From: Fabrizio Gennari +Date: Sun, 4 Oct 2015 01:14:00 +0200 +Subject: [PATCH 2/2] Add a test case for conversion of both sample format and + number of channels + +This patch contains the testcase backport to version 0.3.6. +Author: Stanislav Brabec + +https://bugzilla.novell.com/show_bug.cgi?id=949399#c7 + + +This patch is from opensuse, to verify a CVE fix: +https://build.opensuse.org/projects/multimedia:libs/packages/audiofile/files/audiofile-CVE-2015-7747.patch: + +Upstream-Status: Inactive-Upstream [lastcommit: 2016-Aug-30] +Signed-off-by: Gyorgy Sarvari +--- + test/Makefile.am | 2 + + test/sixteen-stereo-to-eight-mono.c | 118 ++++++++++++++++++++++++++++++++++++ + 2 files changed, 120 insertions(+) + create mode 100644 test/sixteen-stereo-to-eight-mono.c + +diff --git a/test/Makefile.am b/test/Makefile.am +index 7bbf8e4..d311719 100644 +--- a/test/Makefile.am ++++ b/test/Makefile.am +@@ -27,6 +27,7 @@ TESTS = \ + VirtualFile \ + floatto24 \ + query2 \ ++ sixteen-stereo-to-eight-mono \ + sixteen-to-eight \ + testchannelmatrix \ + testdouble \ +@@ -143,6 +144,7 @@ printmarkers_SOURCES = printmarkers.c + printmarkers_LDADD = $(LIBAUDIOFILE) -lm + + sixteen_to_eight_SOURCES = sixteen-to-eight.c TestUtilities.cpp TestUtilities.h ++sixteen_stereo_to_eight_mono_SOURCES = sixteen-stereo-to-eight-mono.c TestUtilities.cpp TestUtilities.h + + testchannelmatrix_SOURCES = testchannelmatrix.c TestUtilities.cpp TestUtilities.h + +diff --git a/test/sixteen-stereo-to-eight-mono.c b/test/sixteen-stereo-to-eight-mono.c +new file mode 100644 +index 0000000..0f14636 +--- /dev/null ++++ b/test/sixteen-stereo-to-eight-mono.c +@@ -0,0 +1,117 @@ ++/* ++ Audio File Library ++ ++ Copyright 2000, Silicon Graphics, Inc. ++ ++ This program is free software; you can redistribute it and/or modify ++ it under the terms of the GNU General Public License as published by ++ the Free Software Foundation; either version 2 of the License, or ++ (at your option) any later version. ++ ++ This program is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++ GNU General Public License for more details. ++ ++ You should have received a copy of the GNU General Public License along ++ with this program; if not, write to the Free Software Foundation, Inc., ++ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. ++*/ ++ ++/* ++ sixteen-stereo-to-eight-mono.c ++ ++ This program tests the conversion from 2-channel 16-bit integers to ++ 1-channel 8-bit integers. ++*/ ++ ++#ifdef HAVE_CONFIG_H ++#include ++#endif ++ ++#include ++#include ++#include ++#include ++#include ++#include ++ ++#include ++ ++#include "TestUtilities.h" ++ ++int main (int argc, char **argv) ++{ ++ AFfilehandle file; ++ AFfilesetup setup; ++ int16_t frames16[] = {14298, 392, 3923, -683, 958, -1921}; ++ int8_t frames8[] = {28, 6, -2}; ++ int i, frameCount = 3; ++ int8_t byte; ++ AFframecount result; ++ ++ setup = afNewFileSetup(); ++ ++ afInitFileFormat(setup, AF_FILE_WAVE); ++ ++ afInitSampleFormat(setup, AF_DEFAULT_TRACK, AF_SAMPFMT_TWOSCOMP, 16); ++ afInitChannels(setup, AF_DEFAULT_TRACK, 2); ++ ++ char testFileName[PATH_MAX]; ++ if (!createTemporaryFile("sixteen-to-eight", testFileName)) ++ { ++ fprintf(stderr, "Could not create temporary file.\n"); ++ exit(EXIT_FAILURE); ++ } ++ ++ file = afOpenFile(testFileName, "w", setup); ++ if (file == AF_NULL_FILEHANDLE) ++ { ++ fprintf(stderr, "could not open file for writing\n"); ++ exit(EXIT_FAILURE); ++ } ++ ++ afFreeFileSetup(setup); ++ ++ afWriteFrames(file, AF_DEFAULT_TRACK, frames16, frameCount); ++ ++ afCloseFile(file); ++ ++ file = afOpenFile(testFileName, "r", AF_NULL_FILESETUP); ++ if (file == AF_NULL_FILEHANDLE) ++ { ++ fprintf(stderr, "could not open file for reading\n"); ++ exit(EXIT_FAILURE); ++ } ++ ++ afSetVirtualSampleFormat(file, AF_DEFAULT_TRACK, AF_SAMPFMT_TWOSCOMP, 8); ++ afSetVirtualChannels(file, AF_DEFAULT_TRACK, 1); ++ ++ for (i=0; i X-Patchwork-Id: 74394 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id B99B2CD5BDF for ; Thu, 13 Nov 2025 12:06:17 +0000 (UTC) Received: from mail-wm1-f49.google.com (mail-wm1-f49.google.com [209.85.128.49]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.22297.1763035576739472992 for ; Thu, 13 Nov 2025 04:06:17 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=loa3DY6m; spf=pass (domain: gmail.com, ip: 209.85.128.49, mailfrom: skandigraun@gmail.com) Received: by mail-wm1-f49.google.com with SMTP id 5b1f17b1804b1-47721743fd0so4376655e9.2 for ; Thu, 13 Nov 2025 04:06:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1763035575; x=1763640375; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=zC4aoo/eyvJUjokazg/F69nU8S+RomJN2prhpse3kDg=; b=loa3DY6m0anidyJlg8tUQvef6Iax0E1rD20VTla+4M66YfrcWnis6vK87TEuUy+Fwk pHlSKRRx0KXq1oULaD8f7A2lBqbgfsWqG5lKGdppFBts7E9BDarcwYbFP3phfkrxFbc/ eSm3arYh8kSyjOD0hgJ9A1MkJ4Lg2BeXYvGNy6rgB+bfNEZBgwIq/6OtiaouE7876MQc kk/N2Yq5cJi42ebdxUHCEEjBzIRQDhm4jVri/tfqx65Ouh0Iumk8kxOyw1VKEBqfbUH2 a4qIL75jHFnDYmC2ZgrhebfuWqgWlpQQfC8XkKnLucZt2DcOn+Hat3wVaOS+nl931de3 l4iw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763035575; x=1763640375; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=zC4aoo/eyvJUjokazg/F69nU8S+RomJN2prhpse3kDg=; b=lBLiPlmvOJELOOzH9D3DIoyEjfpRi0fGsbw6DR8IdMhDI6tNMlMzysz53YzKCEjxvT 62BhnaEwFJPMTutZxzRX/OrvvjiqfWGiQCwQpg9WkfUlvbaJ0WCLbkQ81p+VJ3h7sq/+ rlNAX11XvLDLQTCi34T3TKdLmXi4gEXh24J9gOVuAZ58FwryyHpbFecb2xBbOrc4DGJU o0faRsh1dCQ39ItcwNH6Ky+NYjKpwVzhO1E0ArrLnuKgPj0cB1hsBXfupbhG0gWxwDVU 7OM0zpkNCUUjVySJMjj4UJSNWq6TpRiWktT3Ufaj9GksxDpZL9qLYqeVeZiOo0cI1UaH PlCA== X-Gm-Message-State: AOJu0Yx5Nd77Txk/kDhcf1EnUn7y4DJEzP0VSEE4EN584MC2ceQBLRYx eMJa4Ik/mnbW0pjkDWfZ+LnMAr73sVqGcpZ8j/eQun0SulsICCo6uY9Exnh/bQaW X-Gm-Gg: ASbGncsiJxKW+eQbQmSaS38nfEhSj/aqM41dTu1/hGULxz5rr/UVXn3bzZHH6JWrWpS A6AgvQ5DIFouYwrip8wDeVEkwwX7Rc0W3g6vLvKWCtDAWXj6nKoNxNBpIezWrdVdjL7Tobdyhf6 Jtd5kMhq2wIjOhLVibzUv8tBVGKWsRCJ2JnfqNmsm6YT/FRjIxd8TOVUt97wLxJQCaplddPAk0W SF/Iz44ARmFplEEstlIxnc2R62DrHgbyvtD9Eruymb+Bmb9jbmUp2odY1fq69obUU9E175fkGf4 9zDOJsNHPmRGI/3LNQRE2EEVy6pslOs3bqxyTVCZLEB7psuS611/u/ATsHuUnme97aVKDYQdGso vzC5ii4PE+PoinyD4wm0AG1LNZO9T3KjLt4Bh4V+bSZnzzRhzhIfPBa2T7DY9ikRx8TD7UvDpeI Bm6j7HTChu X-Google-Smtp-Source: AGHT+IEfcf54dFSbBP6/oIOcUI2v+zFEYrcrMtPUKFeHSU02f/NVqRZHojWqbFbDXIh1X5A4Evf6Qw== X-Received: by 2002:a05:600c:4f91:b0:477:54cd:202f with SMTP id 5b1f17b1804b1-4778707095emr66270885e9.3.1763035575010; Thu, 13 Nov 2025 04:06:15 -0800 (PST) Received: from desktop ([51.154.145.205]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-42b53e85627sm3974561f8f.16.2025.11.13.04.06.14 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 13 Nov 2025 04:06:14 -0800 (PST) From: Gyorgy Sarvari To: openembedded-devel@lists.openembedded.org Subject: [meta-oe][PATCH 4/4] audiofile: patch CVE-2018-13440 and CVE-2018-17059 Date: Thu, 13 Nov 2025 13:06:11 +0100 Message-ID: <20251113120611.2590707-4-skandigraun@gmail.com> X-Mailer: git-send-email 2.51.2 In-Reply-To: <20251113120611.2590707-1-skandigraun@gmail.com> References: <20251113120611.2590707-1-skandigraun@gmail.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 13 Nov 2025 12:06:17 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-devel/message/121648 Details: https://nvd.nist.gov/vuln/detail/CVE-2018-13440 https://nvd.nist.gov/vuln/detail/CVE-2018-17059 The patches have been backported from Debian - upstream has been inactive for almost a decade by now. Signed-off-by: Gyorgy Sarvari --- .../audiofile/audiofile_0.3.6.bb | 2 ++ .../audiofile/files/CVE-2018-13440.patch | 36 +++++++++++++++++++ .../audiofile/files/CVE-2018-17059.patch | 35 ++++++++++++++++++ 3 files changed, 73 insertions(+) create mode 100644 meta-oe/recipes-multimedia/audiofile/files/CVE-2018-13440.patch create mode 100644 meta-oe/recipes-multimedia/audiofile/files/CVE-2018-17059.patch diff --git a/meta-oe/recipes-multimedia/audiofile/audiofile_0.3.6.bb b/meta-oe/recipes-multimedia/audiofile/audiofile_0.3.6.bb index b14b4792b3..cc7fef2a26 100644 --- a/meta-oe/recipes-multimedia/audiofile/audiofile_0.3.6.bb +++ b/meta-oe/recipes-multimedia/audiofile/audiofile_0.3.6.bb @@ -22,6 +22,8 @@ SRC_URI = " \ file://test-for-CVE-2015-7747.patch \ file://CVE-2019-13147.patch \ file://CVE-2022-24599.patch \ + file://CVE-2018-13440.patch \ + file://CVE-2018-17059.patch \ " SRC_URI[sha256sum] = "ea2449ad3f201ec590d811db9da6d02ffc5e87a677d06b92ab15363d8cb59782" diff --git a/meta-oe/recipes-multimedia/audiofile/files/CVE-2018-13440.patch b/meta-oe/recipes-multimedia/audiofile/files/CVE-2018-13440.patch new file mode 100644 index 0000000000..f468696845 --- /dev/null +++ b/meta-oe/recipes-multimedia/audiofile/files/CVE-2018-13440.patch @@ -0,0 +1,36 @@ +From fde6d79fb8363c4a329a184ef0b107156602b225 Mon Sep 17 00:00:00 2001 +From: Wim Taymans +Date: Thu, 27 Sep 2018 10:48:45 +0200 +Subject: [PATCH] ModuleState: handle compress/decompress init failure + +When the unit initcompress or initdecompress function fails, +m_fileModule is NULL. Return AF_FAIL in that case instead of +causing NULL pointer dereferences later. + +Fixes #49 + +This patch has been backported from Debian: +https://sources.debian.org/src/audiofile/0.3.6-7/debian/patches/11_CVE-2018-13440.patch + +CVE: CVE-2018-13440 +Upstream-Status: Inactive-Upstream [lastcommit: 2016-Aug-30] +Signed-off-by: Gyorgy Sarvari + +--- + libaudiofile/modules/ModuleState.cpp | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/libaudiofile/modules/ModuleState.cpp b/libaudiofile/modules/ModuleState.cpp +index 0c29d7a..070fd9b 100644 +--- a/libaudiofile/modules/ModuleState.cpp ++++ b/libaudiofile/modules/ModuleState.cpp +@@ -75,6 +75,9 @@ status ModuleState::initFileModule(AFfilehandle file, Track *track) + m_fileModule = unit->initcompress(track, file->m_fh, file->m_seekok, + file->m_fileFormat == AF_FILE_RAWDATA, &chunkFrames); + ++ if (!m_fileModule) ++ return AF_FAIL; ++ + if (unit->needsRebuffer) + { + assert(unit->nativeSampleFormat == AF_SAMPFMT_TWOSCOMP); diff --git a/meta-oe/recipes-multimedia/audiofile/files/CVE-2018-17059.patch b/meta-oe/recipes-multimedia/audiofile/files/CVE-2018-17059.patch new file mode 100644 index 0000000000..e9b560102a --- /dev/null +++ b/meta-oe/recipes-multimedia/audiofile/files/CVE-2018-17059.patch @@ -0,0 +1,35 @@ +From 822b732fd31ffcb78f6920001e9b1fbd815fa712 Mon Sep 17 00:00:00 2001 +From: Wim Taymans +Date: Thu, 27 Sep 2018 12:11:12 +0200 +Subject: [PATCH] SimpleModule: set output chunk framecount after pull + +After pulling the data, set the output chunk to the amount of +frames we pulled so that the next module in the chain has the correct +frame count. + +Fixes #50 and #51 + +This patch has been backported from Debian: +https://sources.debian.org/src/audiofile/0.3.6-7/debian/patches/12_CVE-2018-17095.patch + +CVE: CVE-2018-17095 + +Upstream-Status: Inactive-Upstream [lastcommit: 2016-Aug-30] +Signed-off-by: Gyorgy Sarvari + +--- + libaudiofile/modules/SimpleModule.cpp | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/libaudiofile/modules/SimpleModule.cpp b/libaudiofile/modules/SimpleModule.cpp +index 2bae1eb..e87932c 100644 +--- a/libaudiofile/modules/SimpleModule.cpp ++++ b/libaudiofile/modules/SimpleModule.cpp +@@ -26,6 +26,7 @@ + void SimpleModule::runPull() + { + pull(m_outChunk->frameCount); ++ m_outChunk->frameCount = m_inChunk->frameCount; + run(*m_inChunk, *m_outChunk); + } +