From 3800c77496fc5cb4f6de6a09a6edd3bf94da3d46 Mon Sep 17 00:00:00 2001 From: lvfei Date: Thu, 8 Aug 2024 10:57:33 +0800 Subject: [PATCH] Fix CVE-2024-0745 --- CVE-2024-0745.patch | 34 ++++++++++++++++++++++++++++++++++ thunderbird.spec | 7 ++++++- 2 files changed, 40 insertions(+), 1 deletion(-) create mode 100644 CVE-2024-0745.patch diff --git a/CVE-2024-0745.patch b/CVE-2024-0745.patch new file mode 100644 index 0000000..600210c --- /dev/null +++ b/CVE-2024-0745.patch @@ -0,0 +1,34 @@ +From ddeaf6842f41547f917513095ed0c01cc5836370 Mon Sep 17 00:00:00 2001 +From: Karl Tomlinson +Date: Sun, 07 Jan 2024 23:24:05 +0000 (7 months ago) +Subject: [PATCH] CVE-2024-0745 + +--- + dom/media/webaudio/OscillatorNode.cpp | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git a/dom/media/webaudio/OscillatorNode.cpp b/dom/media/webaudio/OscillatorNode.cpp +index b18b0a0fe1..02ef34cebc 100644 +--- a/dom/media/webaudio/OscillatorNode.cpp ++++ b/dom/media/webaudio/OscillatorNode.cpp +@@ -294,7 +294,8 @@ class OscillatorNodeEngine final : public AudioNodeEngine { + return; + } + +- if (ticks + WEBAUDIO_BLOCK_SIZE <= mStart || ticks >= mStop) { ++ if (ticks + WEBAUDIO_BLOCK_SIZE <= mStart || ticks >= mStop || ++ mStop <= mStart) { + ComputeSilence(aOutput); + + } else { +@@ -303,6 +304,7 @@ class OscillatorNodeEngine final : public AudioNodeEngine { + + uint32_t start, end; + FillBounds(output, ticks, start, end); ++ MOZ_ASSERT(start < end); + + // Synthesize the correct waveform. + switch (mType) { +-- +2.33.0 + diff --git a/thunderbird.spec b/thunderbird.spec index 90149e2..c5858f1 100644 --- a/thunderbird.spec +++ b/thunderbird.spec @@ -59,7 +59,7 @@ Summary: Mozilla Thunderbird mail/newsgroup client Name: thunderbird Version: 115.5.0 -Release: 1 +Release: 2 URL: http://www.mozilla.org/projects/thunderbird/ License: MPLv1.1 or GPLv2+ or LGPLv2+ Source0: thunderbird-115.5.0.source.tar.xz.aa @@ -101,6 +101,7 @@ Patch503: expat-CVE-2022-25315.patch #openEuler specific Patch601: 0001-Fix-build-error-if-arc4random_buf-is-supported.patch +Patch602: CVE-2024-0745.patch BuildRequires: make BuildRequires: gcc-c++ @@ -236,6 +237,7 @@ mv -f %{_sourcedir}/tmp_source %{SOURCE0} %patch -P 503 -p1 -b .expat-CVE-2022-25315 %patch -P 601 -p1 -b .fix-build-error +%patch -P 602 -p1 %{__rm} -f .mozconfig %{__cp} %{SOURCE10} .mozconfig @@ -583,6 +585,9 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : #=============================================================================== %changelog +* Mon Aug 05 2024 lvfei - 115.5.0-2 +- Fix CVE-2024-0745 + * Tue Feb 27 2024 misaka00251 - 115.5.0-1 - Upgrade to 115.5.0 -- Gitee