Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ State on 2026-11-10. **None of these is in the Debian archive yet.**
| `gdcm` | trixie (13) | CVE-2025-11266, CVE-2025-48429, CVE-2025-52582, CVE-2025-53618, CVE-2025-53619, CVE-2026-3650 | [#1153126](https://bugs.debian.org/1153126) | `trixie-pu` request filed with the [debdiff](gdcm/debian/gdcm_3.0.24-5+deb13u1_trixie.debdiff); agreed with the team, waiting for the release team |
| `gdcm` | bookworm (12, LTS) | The same six CVEs | debian-med list | [Debdiff](gdcm/debian/gdcm_3.0.21-1+deb12u1_bookworm.debdiff) sent on 2026-11-05; a Debian developer is reviewing it |
| `invesalius` | unstable, then trixie (13) | CVE-2024-44825, plus CVE-2024-42845 in trixie | [#1136204](https://bugs.debian.org/1136204) | [Patch](invesalius/CVE-2024-44825.patch) sent to the bug on 2026-11-10, with test results for it and for the patch already proposed there; open. The [trixie debdiff](invesalius/debian/invesalius_3.1.99998-7+deb13u1_trixie.debdiff) waits for the fix in unstable |
| `pydicom` | trixie (13) | CVE-2026-32711 | [#1131492](https://bugs.debian.org/1131492) | [Debdiff](pydicom/debian/pydicom_2.4.3-2+deb13u1_trixie.debdiff) with the upstream [patch](pydicom/CVE-2026-32711.patch) sent to the debian-med list on 2026-11-10; the `trixie-pu` request waits for the team's reply |
| `pydicom` | trixie (13) | CVE-2026-32711 | [#1131492](https://bugs.debian.org/1131492) | [Debdiff](pydicom/debian/pydicom_2.4.3-2+deb13u1_trixie.debdiff) from the merged [Debian Med trixie branch](https://salsa.debian.org/med-team/pydicom/-/merge_requests/1); Karsten confirmed on 2026-11-16 that his existing [`trixie-pu` request #1148120](https://bugs.debian.org/1148120) awaits release-team approval. The [local filing draft](pydicom/debian/trixie-pu-request.md) is superseded; do not open a duplicate |

Each of these package folders has a `debian/` subfolder with the debdiff and the text of
what was sent or is going to be sent: the mail to the team, the bug report or reply, and
Expand Down
134 changes: 79 additions & 55 deletions pydicom/debian/pydicom_2.4.3-2+deb13u1_trixie.debdiff
Original file line number Diff line number Diff line change
@@ -1,24 +1,27 @@
diff -Nru pydicom-2.4.3/debian/changelog pydicom-2.4.3/debian/changelog
--- pydicom-2.4.3/debian/changelog 2025-04-14 21:30:28.000000000 +0000
+++ pydicom-2.4.3/debian/changelog 2026-11-10 14:47:48.000000000 +0000
@@ -1,3 +1,14 @@
+++ pydicom-2.4.3/debian/changelog 2026-11-15 13:13:57.000000000 +0000
@@ -1,3 +1,17 @@
+pydicom (2.4.3-2+deb13u1) trixie; urgency=medium
+
+ * Team upload.
+ * CVE-2026-32711.patch: reject Referenced File IDs in a DICOMDIR that
+ point outside of the File-set root. Upstream's fix for the 2.4 series,
+ released as 2.4.5 (CVE-2026-32711, Closes: #1131492).
+ * d/control: build-depend on python3-pyfakefs, which the tests added by
+ that patch need.
+
+ -- Valentín Torassa <valentintorassacolombero@gmail.com> Tue, 10 Nov 2026 11:50:00 -0300
+ [ Karsten Schöke ]
+ * Fix CVE-2026-32711 vulnerable to Path Traversal (Closes: #1131492)
+
+ [ Valentín Torassa ]
+ * d/control: python3-pyfakefs is only needed by the tests (<!nocheck>).
+ * d/patches: DEP-3 fields for the CVE-2026-32711 patch.
+ * d/gbp.conf: build from the debian/trixie branch.
+
+ -- Valentín Torassa <valentintorassacolombero@gmail.com> Sun, 15 Nov 2026 10:13:57 -0300
+
pydicom (2.4.3-2) unstable; urgency=medium

* Team upload.
diff -Nru pydicom-2.4.3/debian/control pydicom-2.4.3/debian/control
--- pydicom-2.4.3/debian/control 2025-04-14 21:30:28.000000000 +0000
+++ pydicom-2.4.3/debian/control 2026-11-10 14:36:37.000000000 +0000
+++ pydicom-2.4.3/debian/control 2026-11-15 13:13:57.000000000 +0000
@@ -9,6 +9,7 @@
dh-python,
python3-all,
Expand All @@ -27,32 +30,53 @@ diff -Nru pydicom-2.4.3/debian/control pydicom-2.4.3/debian/control
python3-setuptools,
python3-setuptools-scm,
python3-numpy,
diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian/patches/CVE-2026-32711.patch
--- pydicom-2.4.3/debian/patches/CVE-2026-32711.patch 1970-01-01 00:00:00.000000000 +0000
+++ pydicom-2.4.3/debian/patches/CVE-2026-32711.patch 2026-11-10 14:33:25.000000000 +0000
@@ -0,0 +1,560 @@
+Description: Reject Referenced File IDs that point outside of the File-set root
+ A crafted DICOMDIR could set ReferencedFileID to a path outside of the
+ File-set root. pydicom only checked that the path existed and then used it
+ in FileSet.copy(), FileSet.write() and when reading the instances, so files
+ outside of the File-set could be read, copied and, in some flows, moved or
+ deleted (CVE-2026-32711).
+ .
+ This is the fix that upstream cherry-picked to the 2.4 series for 2.4.5:
+ the changes to pydicom/fileset.py and their tests. The rest of that commit
+ (version number, CI configuration, typos in other files) is not included.
+Author: Darcy Mason <darcymason@gmail.com>
diff -Nru pydicom-2.4.3/debian/gbp.conf pydicom-2.4.3/debian/gbp.conf
--- pydicom-2.4.3/debian/gbp.conf 1970-01-01 00:00:00.000000000 +0000
+++ pydicom-2.4.3/debian/gbp.conf 2026-11-15 13:13:57.000000000 +0000
@@ -0,0 +1,3 @@
+[DEFAULT]
+debian-branch = debian/trixie
+pristine-tar = True
diff -Nru pydicom-2.4.3/debian/patches/0006-Insert-CVE-2026-32711-patch.patch pydicom-2.4.3/debian/patches/0006-Insert-CVE-2026-32711-patch.patch
--- pydicom-2.4.3/debian/patches/0006-Insert-CVE-2026-32711-patch.patch 1970-01-01 00:00:00.000000000 +0000
+++ pydicom-2.4.3/debian/patches/0006-Insert-CVE-2026-32711-patch.patch 2026-11-15 13:13:57.000000000 +0000
@@ -0,0 +1,574 @@
+From: =?utf-8?q?Karsten_Sch=C3=B6ke?= <karsten.schoeke@geobasis-bb.de>
+Date: Wed, 16 Sep 2026 18:51:48 +0200
+Subject: Insert CVE-2026-32711 patch.
+
+Reject Referenced File IDs in a DICOMDIR that point outside of the
+File-set root. This is the fix that upstream cherry-picked to the 2.4
+series for 2.4.5, without its version and CI changes.
+
+Origin: upstream, https://github.com/pydicom/pydicom/commit/ed4ddeac21de09101ee0732a0a2168dd73491370
+Bug: https://github.com/pydicom/pydicom/security/advisories/GHSA-v856-2rf8-9f28
+Bug-Debian: https://bugs.debian.org/1131492
+Last-Update: 2026-11-10
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+ pydicom/cli/codify.py | 2 +-
+ pydicom/fileset.py | 152 ++++++++++++++++++++++++++++++------------
+ pydicom/tests/conftest.py | 8 +++
+ pydicom/tests/test_fileset.py | 126 +++++++++++++++++++++++++++++++---
+ 4 files changed, 233 insertions(+), 55 deletions(-)
+
+diff --git a/pydicom/cli/codify.py b/pydicom/cli/codify.py
+index 15115c4..2239507 100644
+--- a/pydicom/cli/codify.py
++++ b/pydicom/cli/codify.py
+@@ -24,7 +24,7 @@ def add_subparser(subparsers: argparse._SubParsersAction) -> None:
+ ),
+ )
+
+- # Codify existed before as a stand-alone before, re-use it here
++ # Codify existed before as a stand-alone before, reuse it here
+ pydicom.util.codify.set_parser_arguments(
+ codify_parser, default_exclude_size
+ )
+diff --git a/pydicom/fileset.py b/pydicom/fileset.py
+index 5549d6dd86..f4412a4dcf 100644
+index 5549d6d..f4412a4 100644
+--- a/pydicom/fileset.py
++++ b/pydicom/fileset.py
+@@ -344,24 +344,47 @@ def _encode_record(self, force_implicit: bool = False) -> int:
+@@ -344,24 +344,47 @@ class RecordNode(Iterable["RecordNode"]):
+
+ return len(fp.getvalue())
+
Expand Down Expand Up @@ -107,7 +131,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+
+ raise AttributeError("No 'Referenced File ID' in the directory record")
+
+@@ -371,7 +394,7 @@ def file_set(self) -> "FileSet":
+@@ -371,7 +394,7 @@ class RecordNode(Iterable["RecordNode"]):
+ return self.root.file_set
+
+ def __getitem__(self, key: Union[str, "RecordNode"]) -> "RecordNode":
Expand All @@ -116,7 +140,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ :attr:`~pydicom.fileset.RecordNode.key`
+ """
+ if isinstance(key, RecordNode):
+@@ -524,8 +547,8 @@ def leaf_summary(node: "RecordNode", indent_char: str) -> List[str]:
+@@ -524,8 +547,8 @@ class RecordNode(Iterable["RecordNode"]):
+ for node in self:
+ indent = indent_char * node.depth
+ if node.children:
Expand All @@ -127,7 +151,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ for child in node.children:
+ if child.has_instance:
+ s.extend(leaf_summary(child, indent_char))
+@@ -931,9 +954,8 @@ def path(self) -> str:
+@@ -931,9 +954,8 @@ class FileInstance:
+ return os.fspath(cast(Path, self._stage_path))
+
+ # If not staged for addition then File Set must exist on file system
Expand All @@ -139,7 +163,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+
+ @property
+ def SOPClassUID(self) -> UID:
+@@ -966,7 +988,7 @@ def __init__(self, ds: Optional[DSPathType] = None) -> None:
+@@ -966,7 +988,7 @@ class FileSet:
+ to the DICOMDIR file.
+ """
+ # The nominal path to the root of the File-set
Expand All @@ -148,7 +172,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ # The root node of the record tree used to fill out the DICOMDIR's
+ # *Directory Record Sequence*.
+ # The tree for instances currently in the File-set
+@@ -1212,7 +1234,7 @@ def clear(self) -> None:
+@@ -1212,7 +1234,7 @@ class FileSet:
+ """Clear the File-set."""
+ self._tree.children = []
+ self._instances = []
Expand All @@ -157,7 +181,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ self._ds = Dataset()
+ self._id = None
+ self._uid = generate_uid()
+@@ -1661,7 +1683,7 @@ def load(
+@@ -1661,7 +1683,7 @@ class FileSet:
+ )
+
+ try:
Expand All @@ -166,7 +190,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ except FileNotFoundError:
+ raise FileNotFoundError(
+ "Unable to load the File-set as the 'filename' attribute "
+@@ -1692,7 +1714,7 @@ def load(
+@@ -1692,7 +1714,7 @@ class FileSet:
+ Optional[str],
+ ds.get("SpecificCharacterSetOfFileSetDescriptorFile", None)
+ )
Expand All @@ -175,7 +199,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ self._ds = ds
+
+ # Create the record tree
+@@ -1701,20 +1723,17 @@ def load(
+@@ -1701,20 +1723,17 @@ class FileSet:
+ bad_instances = []
+ for instance in self:
+ # Check that the referenced file exists
Expand All @@ -200,7 +224,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ )
+ continue
+
+@@ -1726,6 +1745,31 @@ def load(
+@@ -1726,6 +1745,31 @@ class FileSet:
+ for instance in bad_instances:
+ self._instances.remove(instance)
+
Expand Down Expand Up @@ -232,7 +256,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ def _parse_records(
+ self,
+ ds: Dataset,
+@@ -1782,7 +1826,10 @@ def recurse_node(node: RecordNode) -> None:
+@@ -1782,7 +1826,10 @@ class FileSet:
+ del node.parent[node]
+
+ # The leaf node references the FileInstance
Expand All @@ -244,7 +268,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ node.instance = FileInstance(node)
+ self._instances.append(node.instance)
+
+@@ -1817,12 +1864,11 @@ def recurse_node(node: RecordNode) -> None:
+@@ -1817,12 +1864,11 @@ class FileSet:
+ for node in missing:
+ # Get the path to the orphaned instance
+ original_value = node._record.ReferencedFileID
Expand All @@ -259,7 +283,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ if node.record_type == "PRIVATE":
+ instance = self.add_custom(path, node)
+ else:
+@@ -1832,14 +1878,29 @@ def recurse_node(node: RecordNode) -> None:
+@@ -1832,14 +1878,29 @@ class FileSet:
+ instance.node._record.ReferencedFileID = original_value
+
+ @property
Expand Down Expand Up @@ -293,7 +317,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+
+ def _recordify(self, ds: Dataset) -> Iterator[Dataset]:
+ """Yield directory records for a SOP Instance.
+@@ -2105,16 +2166,17 @@ def write(
+@@ -2105,16 +2166,17 @@ class FileSet:
+ )
+
+ if path:
Expand All @@ -314,7 +338,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ # are required and `use_existing` is True
+ major_change = bool(self._stage['+'])
+ if use_existing and major_change:
+@@ -2159,26 +2221,30 @@ def write(
+@@ -2159,26 +2221,30 @@ class FileSet:
+ # and copy any to the stage
+ fout = {Path(ii.FileID) for ii in self}
+ fin = {
Expand Down Expand Up @@ -354,7 +378,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+
+ fn(os.fspath(src), os.fspath(dst))
+diff --git a/pydicom/tests/conftest.py b/pydicom/tests/conftest.py
+index 10d1dc3950..301fd009dc 100644
+index 10d1dc3..301fd00 100644
+--- a/pydicom/tests/conftest.py
++++ b/pydicom/tests/conftest.py
+@@ -22,6 +22,14 @@ def allow_reading_invalid_values():
Expand All @@ -373,7 +397,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ def enforce_writing_invalid_values():
+ value = config.settings.writing_validation_mode
+diff --git a/pydicom/tests/test_fileset.py b/pydicom/tests/test_fileset.py
+index 40bd9d833c..8ded8862da 100644
+index cff26da..bdb7cee 100644
+--- a/pydicom/tests/test_fileset.py
++++ b/pydicom/tests/test_fileset.py
+@@ -1,5 +1,6 @@
Expand All @@ -383,7 +407,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ import sys
+ from pathlib import Path
+ import shutil
+@@ -10,7 +11,7 @@
+@@ -10,7 +11,7 @@ import pytest
+ from pydicom import config, dcmread
+ from pydicom.data import get_testdata_file
+ from pydicom.dataset import Dataset, FileMetaDataset
Expand Down Expand Up @@ -458,7 +482,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ """Return a DICOMDIR dataset with PRIVATE records."""
+ def write_record(ds):
+ """Return `ds` as explicit little encoded bytes."""
+@@ -143,9 +194,17 @@ def private_record():
+@@ -143,9 +194,17 @@ def private(dicomdir):
+ middle = private_record()
+ bottom = private_record()
+ bottom.ReferencedSOPClassUIDInFile = "1.2.3.4"
Expand All @@ -479,7 +503,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ bottom.ReferencedSOPInstanceUIDInFile = (
+ "1.2.276.0.7230010.3.1.4.0.31906.1359940846.78187"
+ )
+@@ -647,6 +706,15 @@ def test_key_raises(self, dummy):
+@@ -647,6 +706,15 @@ class TestRecordNode:
+ with pytest.raises(AttributeError, match=msg):
+ instance.node.key
+
Expand All @@ -495,7 +519,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ def test_bad_record(self, private):
+ """Test a bad directory record raises an exception when loading."""
+ del private.DirectoryRecordSequence[0].PatientID
+@@ -709,7 +777,33 @@ def test_file_id_singleton(self, ct, tdir):
+@@ -709,7 +777,33 @@ class TestRecordNode:
+ item.ReferencedFileID = "01"
+ ds.save_as(p / "DICOMDIR")
+ fs = FileSet(ds)
Expand Down Expand Up @@ -530,7 +554,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+
+ def test_file_id_missing(self, ct):
+ """Test RecordNode._file_id if no Referenced File ID."""
+@@ -718,7 +812,7 @@ def test_file_id_missing(self, ct):
+@@ -718,7 +812,7 @@ class TestRecordNode:
+ del instance.node._record.ReferencedFileID
+ msg = r"No 'Referenced File ID' in the directory record"
+ with pytest.raises(AttributeError, match=msg):
Expand All @@ -539,7 +563,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+
+
+ @pytest.mark.filterwarnings("ignore:The 'DicomDir'")
+@@ -1651,7 +1745,7 @@ def test_clear(self, dicomdir, tdir):
+@@ -1651,7 +1745,7 @@ class TestFileSet:
+ assert "ISO 1" == fs.descriptor_character_set
+ assert [] != fs._instances
+ assert fs._id is not None
Expand All @@ -548,7 +572,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ uid = fs._uid
+ assert fs._uid is not None
+ assert fs._ds is not None
+@@ -1662,7 +1756,7 @@ def test_clear(self, dicomdir, tdir):
+@@ -1662,7 +1756,7 @@ class TestFileSet:
+ fs.clear()
+ assert [] == fs._instances
+ assert fs._id is None
Expand All @@ -557,7 +581,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ assert uid != fs._uid
+ assert fs._uid.is_valid
+ assert fs._ds == Dataset()
+@@ -2321,14 +2415,14 @@ def test_write_use_existing(self, dicomdir_copy):
+@@ -2323,14 +2417,14 @@ class TestFileSet_Modify:
+ tdir, ds = dicomdir_copy
+ assert 52 == len(ds.DirectoryRecordSequence)
+ fs = FileSet(ds)
Expand All @@ -574,7 +598,7 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ assert orig_file_ids == [ii.ReferencedFileID for ii in fs]
+ assert Path(instance.path) not in paths
+ assert sorted(orig_paths)[1:] == sorted(paths)
+@@ -2478,6 +2572,16 @@ def setup_method(self):
+@@ -2480,6 +2574,16 @@ class TestFileSet_Copy:
+ def teardown_method(self):
+ FileSet.__len__ = self.orig
+
Expand All @@ -593,9 +617,9 @@ diff -Nru pydicom-2.4.3/debian/patches/CVE-2026-32711.patch pydicom-2.4.3/debian
+ orig_root = Path(dicomdir.filename).parent
diff -Nru pydicom-2.4.3/debian/patches/series pydicom-2.4.3/debian/patches/series
--- pydicom-2.4.3/debian/patches/series 2025-04-14 21:30:28.000000000 +0000
+++ pydicom-2.4.3/debian/patches/series 2026-11-10 14:33:25.000000000 +0000
+++ pydicom-2.4.3/debian/patches/series 2026-11-15 13:13:57.000000000 +0000
@@ -3,3 +3,4 @@
ignore_tests_with_wrong_gdcm_usage.patch
sphinx_no_git.patch
skip-i386-incapable-tests.patch
+CVE-2026-32711.patch
+0006-Insert-CVE-2026-32711-patch.patch
Loading