public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Germano Massullo (Thetra) <germano.massullo@thetra.eu>
To: git-commits@fedoraproject.org
Subject: [rpms/darktable] f44: Add cve-2026-5318.patch
Date: Tue, 01 Sep 2026 08:49:56 GMT [thread overview]
Message-ID: <178825259690.1.5852213911365654616.rpms-darktable-3d2fe6b7f0aa@fedoraproject.org> (raw)
A new commit has been pushed.
Repo : rpms/darktable
Branch : f44
Commit : 3d2fe6b7f0aafb8e4a3e4306b999f77d4322fbe2
Author : Germano Massullo (Thetra) <germano.massullo@thetra.eu>
Date : 2026-04-03T01:08:29+02:00
Stats : +29/-0 in 2 file(s)
URL : https://src.fedoraproject.org/rpms/darktable/c/3d2fe6b7f0aafb8e4a3e4306b999f77d4322fbe2?branch=f44
Log:
Add cve-2026-5318.patch
---
diff --git a/cve-2026-5318.patch b/cve-2026-5318.patch
new file mode 100644
index 0000000..0be8543
--- /dev/null
+++ b/cve-2026-5318.patch
@@ -0,0 +1,27 @@
+diff -urNr darktable-5.4.1-orig/src/external/LibRaw/src/decompressors/losslessjpeg.cpp darktable-5.4.1/src/external/LibRaw/src/decompressors/losslessjpeg.cpp
+--- darktable-5.4.1-orig/src/external/LibRaw/src/decompressors/losslessjpeg.cpp 2026-01-09 10:59:59.000000000 +0100
++++ darktable-5.4.1/src/external/LibRaw/src/decompressors/losslessjpeg.cpp 2026-04-02 23:23:27.630825281 +0200
+@@ -361,6 +361,7 @@
+ nbits--;
+ }
+ hufftable.resize( size_t(1ULL << nbits));
++ uint32_t tsize = 1 << nbits;
+ for (unsigned i = 0; i < hufftable.size(); i++) hufftable[i] = 0;
+
+ int h = 0;
+@@ -371,10 +372,14 @@
+ {
+ for (int j = 0; j < (1 << (nbits - len - 1)); j++)
+ {
+- hufftable[h] = ((len+1) << 16) | (uint8_t(huffval[pos] & 0xff) << 8) | uint8_t(shiftval[pos] & 0xff);
++ if (h >= tsize)
++ throw LIBRAW_EXCEPTION_IO_CORRUPT;
++ hufftable[h] = ((len + 1) << 16) | (uint8_t(huffval[pos] & 0xff) << 8) | uint8_t(shiftval[pos] & 0xff);
+ h++;
+ }
+ pos++;
++ if(pos >= 256)
++ throw LIBRAW_EXCEPTION_IO_CORRUPT;
+ }
+ }
+ if (!disable_cache)
diff --git a/darktable.spec b/darktable.spec
index 40a4db0..8d9d024 100644
--- a/darktable.spec
+++ b/darktable.spec
@@ -21,6 +21,8 @@ Source0: https://github.com/darktable-org/darktable/releases/download/release-%{
Patch0: 0001-Add-5.4.1-in-appdata.patch
Patch1: darktable-5.4.1-lua-5.5.patch
+# https://bugzilla.redhat.com/show_bug.cgi?id=2454222
+Patch2: cve-2026-5318.patch
BuildRequires: cairo-devel
# clang is optional (OpenCL kernel build test)
reply other threads:[~2026-09-01 8:49 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=178825259690.1.5852213911365654616.rpms-darktable-3d2fe6b7f0aa@fedoraproject.org \
--to=germano.massullo@thetra.eu \
--cc=git-commits@fedoraproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox