From 84854961811d6cf14c0c22035b510c430647f04b Mon Sep 17 00:00:00 2001 From: Tomas Bzatek Date: Wed, 2 Oct 2024 13:59:11 +0200 Subject: [PATCH 01/14] * Wed Oct 02 2024 Tomas Bzatek - 2.10.90-1 - Version 2.10.90 --- .gitignore | 1 + sources | 2 +- udisks-2.11.0-BLKRRPART_harder.patch | 55 --------- ...-targetcli_config.json_netif_timeout.patch | 38 ------ ...iskslinuxblock_survive_missing_fstab.patch | 32 ----- ....0-udiskslinuxmanager_use_after_free.patch | 112 ------------------ udisks2.spec | 25 ++-- 7 files changed, 15 insertions(+), 250 deletions(-) delete mode 100644 udisks-2.11.0-BLKRRPART_harder.patch delete mode 100644 udisks-2.11.0-targetcli_config.json_netif_timeout.patch delete mode 100644 udisks-2.11.0-udiskslinuxblock_survive_missing_fstab.patch delete mode 100644 udisks-2.11.0-udiskslinuxmanager_use_after_free.patch diff --git a/.gitignore b/.gitignore index 148ecf9..5efa339 100644 --- a/.gitignore +++ b/.gitignore @@ -19,3 +19,4 @@ /udisks-2.9.4.tar.bz2 /udisks-2.10.0.tar.bz2 /udisks-2.10.1.tar.bz2 +/udisks-2.10.90.tar.bz2 diff --git a/sources b/sources index 3712713..55741ad 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (udisks-2.10.1.tar.bz2) = 9cdaeca4306a970c85f88d406dbe5d2dad23d72f47d9ab1c021b8c2888d4c790f680eb94388d86f9255024283b4a36e98b8aee4408d193a7d4aad1e74463356a +SHA512 (udisks-2.10.90.tar.bz2) = 7e2507ee9b235925af6d367a0d55608f7a2780a07efba9db3c4bc06a3d42728ce74fc9edc42255fc9259aa3426c83eb164e1e99740a2d2c1b80ec2265b51df90 diff --git a/udisks-2.11.0-BLKRRPART_harder.patch b/udisks-2.11.0-BLKRRPART_harder.patch deleted file mode 100644 index 39af1e0..0000000 --- a/udisks-2.11.0-BLKRRPART_harder.patch +++ /dev/null @@ -1,55 +0,0 @@ -From eb1d4a2bcbb8744074d17553bd0d55ffbd76bdeb Mon Sep 17 00:00:00 2001 -From: Tomas Bzatek -Date: Tue, 14 Nov 2023 13:16:39 +0000 -Subject: [PATCH] udiskslinuxblockobject: Try issuing BLKRRPART ioctl harder - -For some reason even after acquiring a voluntary BSD lock on -the device the BLKRRPART ioctl still fails with EBUSY. Wait -a couple of msec and everything is fine. - -So try harder, several attempts, if busy. There might be number -of things going on in the system and it's out of our control -even when holding a lock. ---- - src/udiskslinuxblockobject.c | 14 +++++++++++--- - 1 file changed, 11 insertions(+), 3 deletions(-) - -diff --git a/src/udiskslinuxblockobject.c b/src/udiskslinuxblockobject.c -index d5da4bc4d9..33604df841 100644 ---- a/src/udiskslinuxblockobject.c -+++ b/src/udiskslinuxblockobject.c -@@ -1098,23 +1098,31 @@ udisks_linux_block_object_reread_partition_table (UDisksLinuxBlockObject *objec - } - else - { -- gint num_tries = 0; -+ gint num_tries; - - /* acquire an exclusive BSD lock to prevent udev probes. - * See also https://systemd.io/BLOCK_DEVICE_LOCKING - */ -+ num_tries = 10; - while (flock (fd, LOCK_EX | LOCK_NB) != 0) - { - g_usleep (100 * 1000); /* microseconds */ -- if (num_tries++ > 5) -+ if (num_tries-- < 0) - break; - } - -- if (ioctl (fd, BLKRRPART) != 0) -+ num_tries = 5; -+ while (ioctl (fd, BLKRRPART) != 0) - { -+ if (errno == EBUSY && num_tries-- >= 0) -+ { -+ g_usleep (200 * 1000); /* microseconds */ -+ continue; -+ } - g_set_error (error, G_IO_ERROR, g_io_error_from_errno (errno), - "Error re-reading partition table (BLKRRPART ioctl) on %s: %m", device_file); - ret = FALSE; -+ break; - } - close (fd); - } diff --git a/udisks-2.11.0-targetcli_config.json_netif_timeout.patch b/udisks-2.11.0-targetcli_config.json_netif_timeout.patch deleted file mode 100644 index e40f136..0000000 --- a/udisks-2.11.0-targetcli_config.json_netif_timeout.patch +++ /dev/null @@ -1,38 +0,0 @@ -From acae6bf4594f80da57855343ab325f87386178c4 Mon Sep 17 00:00:00 2001 -From: Tomas Bzatek -Date: Fri, 3 Nov 2023 16:40:54 +0100 -Subject: [PATCH] tests: Fix targetcli_config.json - -Not all attributes are available anymore in newer kernel versions. ---- - src/tests/dbus-tests/targetcli_config.json | 3 --- - 1 file changed, 3 deletions(-) - -diff --git a/src/tests/dbus-tests/targetcli_config.json b/src/tests/dbus-tests/targetcli_config.json -index 3be9eac2be..f50bf7d4d2 100644 ---- a/src/tests/dbus-tests/targetcli_config.json -+++ b/src/tests/dbus-tests/targetcli_config.json -@@ -331,7 +331,6 @@ - "demo_mode_write_protect": 0, - "generate_node_acls": 1, - "login_timeout": 15, -- "netif_timeout": 2, - "prod_mode_write_protect": 0, - "t10_pi": 0, - "tpg_enabled_sendtargets": 1 -@@ -393,7 +392,6 @@ - "demo_mode_write_protect": 1, - "generate_node_acls": 0, - "login_timeout": 15, -- "netif_timeout": 2, - "prod_mode_write_protect": 0, - "t10_pi": 0, - "tpg_enabled_sendtargets": 1 -@@ -479,7 +477,6 @@ - "demo_mode_write_protect": 1, - "generate_node_acls": 0, - "login_timeout": 15, -- "netif_timeout": 2, - "prod_mode_write_protect": 0, - "t10_pi": 0, - "tpg_enabled_sendtargets": 1 diff --git a/udisks-2.11.0-udiskslinuxblock_survive_missing_fstab.patch b/udisks-2.11.0-udiskslinuxblock_survive_missing_fstab.patch deleted file mode 100644 index 9acd8bd..0000000 --- a/udisks-2.11.0-udiskslinuxblock_survive_missing_fstab.patch +++ /dev/null @@ -1,32 +0,0 @@ -From 8f62f7c6888659f3b66d5861d46fb9b3a34ff169 Mon Sep 17 00:00:00 2001 -From: Marius Vollmer -Date: Thu, 22 Feb 2024 16:49:24 +0200 -Subject: [PATCH] udiskslinuxblock: Survive a missing /etc/fstab - -This is similar to b79f6840ca82551e672156153b7e13328f0ba19d, which -solved the same problem for /etc/crypttab. ---- - src/udiskslinuxblock.c | 10 +++++++++- - 1 file changed, 9 insertions(+), 1 deletion(-) - -diff --git a/src/udiskslinuxblock.c b/src/udiskslinuxblock.c -index 829dd5f78..a3fa183be 100644 ---- a/src/udiskslinuxblock.c -+++ b/src/udiskslinuxblock.c -@@ -1541,7 +1541,15 @@ add_remove_fstab_entry (UDisksBlock *block, - &contents, - NULL, - error)) -- goto out; -+ { -+ if (g_error_matches (*error, G_FILE_ERROR, G_FILE_ERROR_NOENT)) -+ { -+ contents = g_strdup (""); -+ g_clear_error (error); -+ } -+ else -+ goto out; -+ } - - lines = g_strsplit (contents, "\n", 0); - diff --git a/udisks-2.11.0-udiskslinuxmanager_use_after_free.patch b/udisks-2.11.0-udiskslinuxmanager_use_after_free.patch deleted file mode 100644 index 3157b10..0000000 --- a/udisks-2.11.0-udiskslinuxmanager_use_after_free.patch +++ /dev/null @@ -1,112 +0,0 @@ -From 3dc036fb5045fc068c6abfbe4e62d0871d7ca82a Mon Sep 17 00:00:00 2001 -From: xinpeng wang -Date: Thu, 21 Sep 2023 13:57:40 +0800 -Subject: [PATCH] udiskslinuxmanager:use dbus interface after free - -In handle_get_block_devices, call get_block_objects to obtain iface_block_device -of all current UDisksLinuxBlockObject, and then obtain the corresponding -UDisksLinuxBlockObject's object_path through iface_block_device.iface_block_device -is a GDBusInterfaceSkeleton, which saves the object through -g_dbus_interface_skeleton_set_object. g_object_add_weak_pointer is used here. This -function is not thread-safe.At this time, if other threads are releasing the object, -the program will crash. -This scene can be reproduced by quickly plugging and unplugging the USB disk. -The core is as follows (the redundant stack is omitted): -When accessing object in thread 1, the object is released by thread 2 -info threads - Id Target Id Frame -* 1 Thread 0x7f80979e70 (LWP 24559) 0x0000007f8a48dda0 in -g_dbus_object_get_object_path (object=0x0) at ../../../gio/gdbusobject.c:109 - 2 Thread 0x7f88a43010 (LWP 1159) 0x0000007f8a0a6ae8 in __GI___libc_free -(mem=0x556a919c80) at malloc.c:3093 - -thread 1 -(gdb) bt -0 0x0000007f8a48dda0 in g_dbus_object_get_object_path (object=0x0) at -../../../gio/gdbusobject.c:109 -1 0x000000556a56911c in handle_get_block_devices (object=0x7f7c007ed0, invocation= -0x7f74016f20 [GDBusMethodInvocation], arg_options=) - at udiskslinuxmanager.c:1063 - -(gdb) p ((GObject*)(blocks_p->data))->ref_count -$3 = 1 -(gdb) p *((GDBusInterfaceSkeleton*)(blocks_p->data)) -$6 = {parent_instance = {g_type_instance = {g_class = 0x556a64e740 -[g_type: UDisksLinuxBlock/UDisksBlockSkeleton/GDBusInterfaceSkeleton]}, ref_count = 1, -qdata = 0x0}, priv = 0x7f7c004ac0} -(gdb) p *((GDBusInterfaceSkeleton*)(blocks_p->data))->priv -$7 = {lock = {p = 0x0, i = {0, 0}}, object = 0x0, -flags = G_DBUS_INTERFACE_SKELETON_FLAGS_HANDLE_METHOD_INVOCATIONS_IN_THREAD, -connections = 0x0, object_path = 0x0, hooked_vtable = 0x556a62b9f0} - -thread 2 -(gdb) bt -0 0x0000007f8a0a6ae8 in __GI___libc_free (mem=0x556a919c80) at malloc.c:3093 -1 0x0000007f89ff1224 in () at /lib/aarch64-linux-gnu/libudev.so.1 -2 0x0000007f89ff1348 in () at /lib/aarch64-linux-gnu/libudev.so.1 -3 0x0000007f89ff5520 in () at /lib/aarch64-linux-gnu/libudev.so.1 -4 0x0000007f89fff878 in udev_device_unref () at /lib/aarch64-linux-gnu/libudev.so.1 -5 0x0000007f8a7aeb74 in () at /lib/aarch64-linux-gnu/libgudev-1.0.so.0 -6 0x0000007f8a3193f8 in g_object_unref (_object=) at -../../../gobject/gobject.c:3346 -7 0x0000007f8a3193f8 in g_object_unref (_object=0x7f680038a0) at -../../../gobject/gobject.c:3238 -8 0x000000556a57700c in udisks_linux_device_finalize (object=0x7f5c005730 -[UDisksLinuxDevice]) at udiskslinuxdevice.c:75 -9 0x0000007f8a3193f8 in g_object_unref (_object=) at -../../../gobject/gobject.c:3346 -10 0x0000007f8a3193f8 in g_object_unref (_object=0x7f5c005730) at -../../../gobject/gobject.c:3238 -11 0x000000556a55d0fc in udisks_linux_drive_object_uevent - (object=object@entry=0x556a5df370 [UDisksLinuxDriveObject], -action=action@entry=0x556a87b120 -"remove",device=device@entry=0x7f74007610 [UDisksLinuxDevice]) - at udiskslinuxdriveobject.c:715 -12 0x000000556a54840c in handle_block_uevent_for_drive - (provider=provider@entry=0x556a5c8200 [UDisksLinuxProvider], -action=action@entry=0x556a87b120 "remove",device=device@entry=0x7f74007610 -[UDisksLinuxDevice]) at udiskslinuxprovider.c:1035 -13 0x000000556a548ab8 in handle_block_uevent (device=0x7f74007610 [UDisksLinuxDevice], -action=0x556a87b120 "remove", provider=0x556a5c8200 [UDisksLinuxProvider]) at -udiskslinuxprovider.c:1349 -14 0x000000556a548ab8 in udisks_linux_provider_handle_uevent - (provider=0x556a5c8200 [UDisksLinuxProvider], action=0x556a87b120 "remove", -device=0x7f74007610 [UDisksLinuxDevice]) at udiskslinuxprovider.c:1399 -15 0x000000556a548cac in on_idle_with_probed_uevent (user_data=0x556a7e65a0) at -udiskslinuxprovider.c:230 ---- - src/udiskslinuxmanager.c | 13 +++++++++---- - 1 file changed, 9 insertions(+), 4 deletions(-) - -diff --git a/src/udiskslinuxmanager.c b/src/udiskslinuxmanager.c -index 5bfeec103..491edb92b 100644 ---- a/src/udiskslinuxmanager.c -+++ b/src/udiskslinuxmanager.c -@@ -1196,8 +1196,11 @@ handle_get_block_devices (UDisksManager *object, - blocks = get_block_objects (object, &num_blocks); - block_paths = g_new0 (const gchar *, num_blocks + 1); - -- for (i = 0,blocks_p = blocks; blocks_p != NULL; blocks_p = blocks_p->next, i++) -- block_paths[i] = g_dbus_object_get_object_path (g_dbus_interface_get_object (G_DBUS_INTERFACE (blocks_p->data))); -+ for (blocks_p = blocks; blocks_p != NULL; blocks_p = blocks_p->next) { -+ GDBusObject * block_object = g_dbus_interface_get_object (G_DBUS_INTERFACE (blocks_p->data)); -+ if (block_object) -+ block_paths[i++] = g_dbus_object_get_object_path (block_object); -+ } - - udisks_manager_complete_get_block_devices (object, - invocation, -@@ -1284,9 +1287,11 @@ handle_resolve_device (UDisksManager *object, - } - - ret_paths = g_new0 (const gchar *, num_found + 1); -- for (i = 0,ret_p = ret; ret_p != NULL; ret_p = ret_p->next, i++) -+ for (i = 0,ret_p = ret; ret_p != NULL; ret_p = ret_p->next) - { -- ret_paths[i] = g_dbus_object_get_object_path (g_dbus_interface_get_object (G_DBUS_INTERFACE (ret_p->data))); -+ GDBusObject *block_object = g_dbus_interface_get_object (G_DBUS_INTERFACE (ret_p->data)); -+ if (block_object) -+ ret_paths[i++] = g_dbus_object_get_object_path (block_object); - } - - udisks_manager_complete_resolve_device (object, diff --git a/udisks2.spec b/udisks2.spec index 0f0e534..b5f1a77 100644 --- a/udisks2.spec +++ b/udisks2.spec @@ -2,10 +2,9 @@ %global gobject_introspection_version 1.30.0 %global polkit_version 0.102 %global systemd_version 208 -%global libatasmart_version 0.17 %global dbus_version 1.4.0 %global with_gtk_doc 1 -%global libblockdev_version 3.0 +%global libblockdev_version 3.2 %define with_btrfs 1 %ifnarch %{ix86} @@ -25,22 +24,16 @@ Name: udisks2 Summary: Disk Manager -Version: 2.10.1 -Release: 6%{?dist} +Version: 2.10.90 +Release: 1%{?dist} License: GPL-2.0-or-later URL: https://github.com/storaged-project/udisks Source0: https://github.com/storaged-project/udisks/releases/download/udisks-%{version}/udisks-%{version}.tar.bz2 -Patch0: udisks-2.11.0-BLKRRPART_harder.patch -Patch1: udisks-2.11.0-targetcli_config.json_netif_timeout.patch -Patch2: udisks-2.11.0-udiskslinuxmanager_use_after_free.patch -Patch3: udisks-2.11.0-udiskslinuxblock_survive_missing_fstab.patch - BuildRequires: make BuildRequires: glib2-devel >= %{glib2_version} BuildRequires: gobject-introspection-devel >= %{gobject_introspection_version} BuildRequires: libgudev1-devel >= %{systemd_version} -BuildRequires: libatasmart-devel >= %{libatasmart_version} BuildRequires: polkit-devel >= %{polkit_version} BuildRequires: systemd >= %{systemd_version} BuildRequires: systemd-devel >= %{systemd_version} @@ -58,6 +51,7 @@ BuildRequires: libblockdev-mdraid-devel >= %{libblockdev_version} BuildRequires: libblockdev-fs-devel >= %{libblockdev_version} BuildRequires: libblockdev-crypto-devel >= %{libblockdev_version} BuildRequires: libblockdev-nvme-devel >= %{libblockdev_version} +BuildRequires: libblockdev-smart-devel >= %{libblockdev_version} BuildRequires: libmount-devel BuildRequires: libuuid-devel @@ -69,6 +63,7 @@ Requires: libblockdev-mdraid >= %{libblockdev_version} Requires: libblockdev-fs >= %{libblockdev_version} Requires: libblockdev-crypto >= %{libblockdev_version} Requires: libblockdev-nvme >= %{libblockdev_version} +Requires: libblockdev-smart >= %{libblockdev_version} Requires: lib%{name}%{?_isa} = %{version}-%{release} @@ -76,8 +71,6 @@ Requires: lib%{name}%{?_isa} = %{version}-%{release} Requires: dbus >= %{dbus_version} # Needed to pull in the udev daemon Requires: udev >= %{systemd_version} -# We need at least this version for bugfixes/features etc. -Requires: libatasmart >= %{libatasmart_version} # For mount, umount, mkswap Requires: util-linux # For mkfs.ext3, mkfs.ext3, e2label @@ -112,6 +105,10 @@ Recommends: ntfs-3g Recommends: btrfs-progs %endif + +# For /proc/self/mountinfo, only available in 2.6.26 or higher +Conflicts: kernel < 2.6.26 + Provides: storaged = %{version}-%{release} Obsoletes: storaged < %{version}-%{release} @@ -210,6 +207,7 @@ sed -i data/builtin_mount_options.conf -e 's/ntfs_drivers=ntfs3,ntfs/ntfs_driver %else --disable-gtk-doc \ %endif + --enable-smart \ %if 0%{?with_btrfs} --enable-btrfs \ %endif @@ -342,6 +340,9 @@ fi %endif %changelog +* Wed Oct 02 2024 Tomas Bzatek - 2.10.90-1 +- Version 2.10.90 + * Sat Jul 20 2024 Fedora Release Engineering - 2.10.1-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild From a698d1f0a2af188604baae7891d3fbd8f95cf111 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Sun, 19 Jan 2025 13:37:29 +0000 Subject: [PATCH 02/14] Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild --- udisks2.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/udisks2.spec b/udisks2.spec index b5f1a77..b16123b 100644 --- a/udisks2.spec +++ b/udisks2.spec @@ -25,7 +25,7 @@ Name: udisks2 Summary: Disk Manager Version: 2.10.90 -Release: 1%{?dist} +Release: 2%{?dist} License: GPL-2.0-or-later URL: https://github.com/storaged-project/udisks Source0: https://github.com/storaged-project/udisks/releases/download/udisks-%{version}/udisks-%{version}.tar.bz2 @@ -340,6 +340,9 @@ fi %endif %changelog +* Sun Jan 19 2025 Fedora Release Engineering - 2.10.90-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild + * Wed Oct 02 2024 Tomas Bzatek - 2.10.90-1 - Version 2.10.90 From 9423b5cd1fb7c0dc774f6e134d07a37d17b544a1 Mon Sep 17 00:00:00 2001 From: Tomas Bzatek Date: Thu, 19 Jun 2025 15:48:48 +0200 Subject: [PATCH 03/14] * Thu Jun 19 2025 Tomas Bzatek - 2.10.90-3 - Harden temporary private mounts (#2373301) --- ...slinuxfilesystemhelpers_nodev,nosuid.patch | 43 +++++++++++++++++++ udisks2.spec | 8 +++- 2 files changed, 50 insertions(+), 1 deletion(-) create mode 100644 udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch diff --git a/udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch b/udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch new file mode 100644 index 0000000..d6b0f9a --- /dev/null +++ b/udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch @@ -0,0 +1,43 @@ +From 5e7277debea926370e587408517560afe87d28c9 Mon Sep 17 00:00:00 2001 +From: Tomas Bzatek +Date: Wed, 4 Jun 2025 15:26:46 +0200 +Subject: [PATCH] udiskslinuxfilesystemhelpers: Mount private mounts with + 'nodev,nosuid' + +The private mount done in take_filesystem_ownership() should always +default to 'nodev,nosuid' for security and 'errors=remount-ro' for +selected filesystem types to handle an corrupted filesystem. This is +consistent with mount options calculation for regular mounts. +--- + src/udiskslinuxfilesystemhelpers.c | 10 +++++++++- + 1 file changed, 9 insertions(+), 1 deletion(-) + +diff --git a/src/udiskslinuxfilesystemhelpers.c b/src/udiskslinuxfilesystemhelpers.c +index 7c5fc037c4..9eb7742c77 100644 +--- a/src/udiskslinuxfilesystemhelpers.c ++++ b/src/udiskslinuxfilesystemhelpers.c +@@ -123,6 +123,7 @@ take_filesystem_ownership (const gchar *device, + + { + gchar *mountpoint = NULL; ++ const gchar *mount_opts; + GError *local_error = NULL; + gboolean unmount = FALSE; + gboolean success = TRUE; +@@ -151,8 +152,15 @@ take_filesystem_ownership (const gchar *device, + goto out; + } + ++ mount_opts = "nodev,nosuid"; ++ if (g_strcmp0 (fstype, "ext2") == 0 || ++ g_strcmp0 (fstype, "ext3") == 0 || ++ g_strcmp0 (fstype, "ext4") == 0 || ++ g_strcmp0 (fstype, "jfs") == 0) ++ mount_opts = "nodev,nosuid,errors=remount-ro"; ++ + /* TODO: mount to a private mount namespace */ +- if (!bd_fs_mount (device, mountpoint, fstype, NULL, NULL, &local_error)) ++ if (!bd_fs_mount (device, mountpoint, fstype, mount_opts, NULL, &local_error)) + { + g_set_error (error, UDISKS_ERROR, UDISKS_ERROR_FAILED, + "Cannot mount %s at %s: %s", diff --git a/udisks2.spec b/udisks2.spec index b16123b..6846793 100644 --- a/udisks2.spec +++ b/udisks2.spec @@ -25,11 +25,14 @@ Name: udisks2 Summary: Disk Manager Version: 2.10.90 -Release: 2%{?dist} +Release: 3%{?dist} License: GPL-2.0-or-later URL: https://github.com/storaged-project/udisks Source0: https://github.com/storaged-project/udisks/releases/download/udisks-%{version}/udisks-%{version}.tar.bz2 +# https://bugzilla.redhat.com/show_bug.cgi?id=2373301 +Patch0: udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch + BuildRequires: make BuildRequires: glib2-devel >= %{glib2_version} BuildRequires: gobject-introspection-devel >= %{gobject_introspection_version} @@ -340,6 +343,9 @@ fi %endif %changelog +* Thu Jun 19 2025 Tomas Bzatek - 2.10.90-3 +- Harden temporary private mounts (#2373301) + * Sun Jan 19 2025 Fedora Release Engineering - 2.10.90-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild From 4cbf9dc0b36d57ea6dca37d790a932129a6f9adf Mon Sep 17 00:00:00 2001 From: Tomas Bzatek Date: Thu, 19 Jun 2025 16:04:17 +0200 Subject: [PATCH 04/14] * Thu Jun 19 2025 Tomas Bzatek - 2.10.1-7 - Harden temporary private mounts (#2373301) --- ...slinuxfilesystemhelpers_nodev,nosuid.patch | 43 +++++++++++++++++++ udisks2.spec | 7 ++- 2 files changed, 49 insertions(+), 1 deletion(-) create mode 100644 udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch diff --git a/udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch b/udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch new file mode 100644 index 0000000..d6b0f9a --- /dev/null +++ b/udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch @@ -0,0 +1,43 @@ +From 5e7277debea926370e587408517560afe87d28c9 Mon Sep 17 00:00:00 2001 +From: Tomas Bzatek +Date: Wed, 4 Jun 2025 15:26:46 +0200 +Subject: [PATCH] udiskslinuxfilesystemhelpers: Mount private mounts with + 'nodev,nosuid' + +The private mount done in take_filesystem_ownership() should always +default to 'nodev,nosuid' for security and 'errors=remount-ro' for +selected filesystem types to handle an corrupted filesystem. This is +consistent with mount options calculation for regular mounts. +--- + src/udiskslinuxfilesystemhelpers.c | 10 +++++++++- + 1 file changed, 9 insertions(+), 1 deletion(-) + +diff --git a/src/udiskslinuxfilesystemhelpers.c b/src/udiskslinuxfilesystemhelpers.c +index 7c5fc037c4..9eb7742c77 100644 +--- a/src/udiskslinuxfilesystemhelpers.c ++++ b/src/udiskslinuxfilesystemhelpers.c +@@ -123,6 +123,7 @@ take_filesystem_ownership (const gchar *device, + + { + gchar *mountpoint = NULL; ++ const gchar *mount_opts; + GError *local_error = NULL; + gboolean unmount = FALSE; + gboolean success = TRUE; +@@ -151,8 +152,15 @@ take_filesystem_ownership (const gchar *device, + goto out; + } + ++ mount_opts = "nodev,nosuid"; ++ if (g_strcmp0 (fstype, "ext2") == 0 || ++ g_strcmp0 (fstype, "ext3") == 0 || ++ g_strcmp0 (fstype, "ext4") == 0 || ++ g_strcmp0 (fstype, "jfs") == 0) ++ mount_opts = "nodev,nosuid,errors=remount-ro"; ++ + /* TODO: mount to a private mount namespace */ +- if (!bd_fs_mount (device, mountpoint, fstype, NULL, NULL, &local_error)) ++ if (!bd_fs_mount (device, mountpoint, fstype, mount_opts, NULL, &local_error)) + { + g_set_error (error, UDISKS_ERROR, UDISKS_ERROR_FAILED, + "Cannot mount %s at %s: %s", diff --git a/udisks2.spec b/udisks2.spec index 0f0e534..c9dbbf5 100644 --- a/udisks2.spec +++ b/udisks2.spec @@ -26,7 +26,7 @@ Name: udisks2 Summary: Disk Manager Version: 2.10.1 -Release: 6%{?dist} +Release: 7%{?dist} License: GPL-2.0-or-later URL: https://github.com/storaged-project/udisks Source0: https://github.com/storaged-project/udisks/releases/download/udisks-%{version}/udisks-%{version}.tar.bz2 @@ -35,6 +35,8 @@ Patch0: udisks-2.11.0-BLKRRPART_harder.patch Patch1: udisks-2.11.0-targetcli_config.json_netif_timeout.patch Patch2: udisks-2.11.0-udiskslinuxmanager_use_after_free.patch Patch3: udisks-2.11.0-udiskslinuxblock_survive_missing_fstab.patch +# https://bugzilla.redhat.com/show_bug.cgi?id=2373301 +Patch4: udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch BuildRequires: make BuildRequires: glib2-devel >= %{glib2_version} @@ -342,6 +344,9 @@ fi %endif %changelog +* Thu Jun 19 2025 Tomas Bzatek - 2.10.1-7 +- Harden temporary private mounts (#2373301) + * Sat Jul 20 2024 Fedora Release Engineering - 2.10.1-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild From 4eb16e3fd0e48187f50768b10d1d912a55319e97 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Fri, 25 Jul 2025 19:43:03 +0000 Subject: [PATCH 05/14] Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild --- udisks2.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/udisks2.spec b/udisks2.spec index 6846793..76e7b2b 100644 --- a/udisks2.spec +++ b/udisks2.spec @@ -25,7 +25,7 @@ Name: udisks2 Summary: Disk Manager Version: 2.10.90 -Release: 3%{?dist} +Release: 4%{?dist} License: GPL-2.0-or-later URL: https://github.com/storaged-project/udisks Source0: https://github.com/storaged-project/udisks/releases/download/udisks-%{version}/udisks-%{version}.tar.bz2 @@ -343,6 +343,9 @@ fi %endif %changelog +* Fri Jul 25 2025 Fedora Release Engineering - 2.10.90-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild + * Thu Jun 19 2025 Tomas Bzatek - 2.10.90-3 - Harden temporary private mounts (#2373301) From df9cdd8b1690d8f777d27553999dafbfdb7020f3 Mon Sep 17 00:00:00 2001 From: Tomas Bzatek Date: Fri, 29 Aug 2025 13:26:12 +0200 Subject: [PATCH 06/14] * Fri Aug 29 2025 Tomas Bzatek - 2.10.91-1 - Version 2.10.91 --- .gitignore | 1 + sources | 2 +- ...slinuxfilesystemhelpers_nodev,nosuid.patch | 43 ------------------- udisks2.spec | 10 ++--- 4 files changed, 7 insertions(+), 49 deletions(-) delete mode 100644 udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch diff --git a/.gitignore b/.gitignore index 5efa339..459124a 100644 --- a/.gitignore +++ b/.gitignore @@ -20,3 +20,4 @@ /udisks-2.10.0.tar.bz2 /udisks-2.10.1.tar.bz2 /udisks-2.10.90.tar.bz2 +/udisks-2.10.91.tar.bz2 diff --git a/sources b/sources index 55741ad..cf76c85 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (udisks-2.10.90.tar.bz2) = 7e2507ee9b235925af6d367a0d55608f7a2780a07efba9db3c4bc06a3d42728ce74fc9edc42255fc9259aa3426c83eb164e1e99740a2d2c1b80ec2265b51df90 +SHA512 (udisks-2.10.91.tar.bz2) = 85a11c7509317b1d53d2864f474b03a70773cc5964ab16ba42ed2704f9f95aa704585d40e55a5b86a63a8b4363caafafad03b1bdfecf282c9ee05a1b5644d3a2 diff --git a/udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch b/udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch deleted file mode 100644 index d6b0f9a..0000000 --- a/udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch +++ /dev/null @@ -1,43 +0,0 @@ -From 5e7277debea926370e587408517560afe87d28c9 Mon Sep 17 00:00:00 2001 -From: Tomas Bzatek -Date: Wed, 4 Jun 2025 15:26:46 +0200 -Subject: [PATCH] udiskslinuxfilesystemhelpers: Mount private mounts with - 'nodev,nosuid' - -The private mount done in take_filesystem_ownership() should always -default to 'nodev,nosuid' for security and 'errors=remount-ro' for -selected filesystem types to handle an corrupted filesystem. This is -consistent with mount options calculation for regular mounts. ---- - src/udiskslinuxfilesystemhelpers.c | 10 +++++++++- - 1 file changed, 9 insertions(+), 1 deletion(-) - -diff --git a/src/udiskslinuxfilesystemhelpers.c b/src/udiskslinuxfilesystemhelpers.c -index 7c5fc037c4..9eb7742c77 100644 ---- a/src/udiskslinuxfilesystemhelpers.c -+++ b/src/udiskslinuxfilesystemhelpers.c -@@ -123,6 +123,7 @@ take_filesystem_ownership (const gchar *device, - - { - gchar *mountpoint = NULL; -+ const gchar *mount_opts; - GError *local_error = NULL; - gboolean unmount = FALSE; - gboolean success = TRUE; -@@ -151,8 +152,15 @@ take_filesystem_ownership (const gchar *device, - goto out; - } - -+ mount_opts = "nodev,nosuid"; -+ if (g_strcmp0 (fstype, "ext2") == 0 || -+ g_strcmp0 (fstype, "ext3") == 0 || -+ g_strcmp0 (fstype, "ext4") == 0 || -+ g_strcmp0 (fstype, "jfs") == 0) -+ mount_opts = "nodev,nosuid,errors=remount-ro"; -+ - /* TODO: mount to a private mount namespace */ -- if (!bd_fs_mount (device, mountpoint, fstype, NULL, NULL, &local_error)) -+ if (!bd_fs_mount (device, mountpoint, fstype, mount_opts, NULL, &local_error)) - { - g_set_error (error, UDISKS_ERROR, UDISKS_ERROR_FAILED, - "Cannot mount %s at %s: %s", diff --git a/udisks2.spec b/udisks2.spec index 76e7b2b..4fa73de 100644 --- a/udisks2.spec +++ b/udisks2.spec @@ -24,15 +24,12 @@ Name: udisks2 Summary: Disk Manager -Version: 2.10.90 -Release: 4%{?dist} +Version: 2.10.91 +Release: 1%{?dist} License: GPL-2.0-or-later URL: https://github.com/storaged-project/udisks Source0: https://github.com/storaged-project/udisks/releases/download/udisks-%{version}/udisks-%{version}.tar.bz2 -# https://bugzilla.redhat.com/show_bug.cgi?id=2373301 -Patch0: udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch - BuildRequires: make BuildRequires: glib2-devel >= %{glib2_version} BuildRequires: gobject-introspection-devel >= %{gobject_introspection_version} @@ -343,6 +340,9 @@ fi %endif %changelog +* Fri Aug 29 2025 Tomas Bzatek - 2.10.91-1 +- Version 2.10.91 + * Fri Jul 25 2025 Fedora Release Engineering - 2.10.90-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild From d2361d2b6bb5510998ad0031ab59da8834a1640d Mon Sep 17 00:00:00 2001 From: Tomas Bzatek Date: Fri, 29 Aug 2025 14:59:36 +0200 Subject: [PATCH 07/14] * Fri Aug 29 2025 Tomas Bzatek - 2.10.2-1 - Version 2.10.2 --- .gitignore | 1 + sources | 2 +- ...slinuxfilesystemhelpers_nodev,nosuid.patch | 43 ------- ...-targetcli_config.json_netif_timeout.patch | 38 ------ ...iskslinuxblock_survive_missing_fstab.patch | 32 ----- ....0-udiskslinuxmanager_use_after_free.patch | 112 ------------------ udisks2.spec | 12 +- 7 files changed, 7 insertions(+), 233 deletions(-) delete mode 100644 udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch delete mode 100644 udisks-2.11.0-targetcli_config.json_netif_timeout.patch delete mode 100644 udisks-2.11.0-udiskslinuxblock_survive_missing_fstab.patch delete mode 100644 udisks-2.11.0-udiskslinuxmanager_use_after_free.patch diff --git a/.gitignore b/.gitignore index 148ecf9..b25dc22 100644 --- a/.gitignore +++ b/.gitignore @@ -19,3 +19,4 @@ /udisks-2.9.4.tar.bz2 /udisks-2.10.0.tar.bz2 /udisks-2.10.1.tar.bz2 +/udisks-2.10.2.tar.bz2 diff --git a/sources b/sources index 3712713..46f6d57 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (udisks-2.10.1.tar.bz2) = 9cdaeca4306a970c85f88d406dbe5d2dad23d72f47d9ab1c021b8c2888d4c790f680eb94388d86f9255024283b4a36e98b8aee4408d193a7d4aad1e74463356a +SHA512 (udisks-2.10.2.tar.bz2) = 8b2fb6d5a9b5c040f315073d0890cde2cad67f06684e607a31636012a515ec798c2129c3dbc8fcd6655d72b7b4a9485172e5e85795a0aeb4ff20a5ea76e690a8 diff --git a/udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch b/udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch deleted file mode 100644 index d6b0f9a..0000000 --- a/udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch +++ /dev/null @@ -1,43 +0,0 @@ -From 5e7277debea926370e587408517560afe87d28c9 Mon Sep 17 00:00:00 2001 -From: Tomas Bzatek -Date: Wed, 4 Jun 2025 15:26:46 +0200 -Subject: [PATCH] udiskslinuxfilesystemhelpers: Mount private mounts with - 'nodev,nosuid' - -The private mount done in take_filesystem_ownership() should always -default to 'nodev,nosuid' for security and 'errors=remount-ro' for -selected filesystem types to handle an corrupted filesystem. This is -consistent with mount options calculation for regular mounts. ---- - src/udiskslinuxfilesystemhelpers.c | 10 +++++++++- - 1 file changed, 9 insertions(+), 1 deletion(-) - -diff --git a/src/udiskslinuxfilesystemhelpers.c b/src/udiskslinuxfilesystemhelpers.c -index 7c5fc037c4..9eb7742c77 100644 ---- a/src/udiskslinuxfilesystemhelpers.c -+++ b/src/udiskslinuxfilesystemhelpers.c -@@ -123,6 +123,7 @@ take_filesystem_ownership (const gchar *device, - - { - gchar *mountpoint = NULL; -+ const gchar *mount_opts; - GError *local_error = NULL; - gboolean unmount = FALSE; - gboolean success = TRUE; -@@ -151,8 +152,15 @@ take_filesystem_ownership (const gchar *device, - goto out; - } - -+ mount_opts = "nodev,nosuid"; -+ if (g_strcmp0 (fstype, "ext2") == 0 || -+ g_strcmp0 (fstype, "ext3") == 0 || -+ g_strcmp0 (fstype, "ext4") == 0 || -+ g_strcmp0 (fstype, "jfs") == 0) -+ mount_opts = "nodev,nosuid,errors=remount-ro"; -+ - /* TODO: mount to a private mount namespace */ -- if (!bd_fs_mount (device, mountpoint, fstype, NULL, NULL, &local_error)) -+ if (!bd_fs_mount (device, mountpoint, fstype, mount_opts, NULL, &local_error)) - { - g_set_error (error, UDISKS_ERROR, UDISKS_ERROR_FAILED, - "Cannot mount %s at %s: %s", diff --git a/udisks-2.11.0-targetcli_config.json_netif_timeout.patch b/udisks-2.11.0-targetcli_config.json_netif_timeout.patch deleted file mode 100644 index e40f136..0000000 --- a/udisks-2.11.0-targetcli_config.json_netif_timeout.patch +++ /dev/null @@ -1,38 +0,0 @@ -From acae6bf4594f80da57855343ab325f87386178c4 Mon Sep 17 00:00:00 2001 -From: Tomas Bzatek -Date: Fri, 3 Nov 2023 16:40:54 +0100 -Subject: [PATCH] tests: Fix targetcli_config.json - -Not all attributes are available anymore in newer kernel versions. ---- - src/tests/dbus-tests/targetcli_config.json | 3 --- - 1 file changed, 3 deletions(-) - -diff --git a/src/tests/dbus-tests/targetcli_config.json b/src/tests/dbus-tests/targetcli_config.json -index 3be9eac2be..f50bf7d4d2 100644 ---- a/src/tests/dbus-tests/targetcli_config.json -+++ b/src/tests/dbus-tests/targetcli_config.json -@@ -331,7 +331,6 @@ - "demo_mode_write_protect": 0, - "generate_node_acls": 1, - "login_timeout": 15, -- "netif_timeout": 2, - "prod_mode_write_protect": 0, - "t10_pi": 0, - "tpg_enabled_sendtargets": 1 -@@ -393,7 +392,6 @@ - "demo_mode_write_protect": 1, - "generate_node_acls": 0, - "login_timeout": 15, -- "netif_timeout": 2, - "prod_mode_write_protect": 0, - "t10_pi": 0, - "tpg_enabled_sendtargets": 1 -@@ -479,7 +477,6 @@ - "demo_mode_write_protect": 1, - "generate_node_acls": 0, - "login_timeout": 15, -- "netif_timeout": 2, - "prod_mode_write_protect": 0, - "t10_pi": 0, - "tpg_enabled_sendtargets": 1 diff --git a/udisks-2.11.0-udiskslinuxblock_survive_missing_fstab.patch b/udisks-2.11.0-udiskslinuxblock_survive_missing_fstab.patch deleted file mode 100644 index 9acd8bd..0000000 --- a/udisks-2.11.0-udiskslinuxblock_survive_missing_fstab.patch +++ /dev/null @@ -1,32 +0,0 @@ -From 8f62f7c6888659f3b66d5861d46fb9b3a34ff169 Mon Sep 17 00:00:00 2001 -From: Marius Vollmer -Date: Thu, 22 Feb 2024 16:49:24 +0200 -Subject: [PATCH] udiskslinuxblock: Survive a missing /etc/fstab - -This is similar to b79f6840ca82551e672156153b7e13328f0ba19d, which -solved the same problem for /etc/crypttab. ---- - src/udiskslinuxblock.c | 10 +++++++++- - 1 file changed, 9 insertions(+), 1 deletion(-) - -diff --git a/src/udiskslinuxblock.c b/src/udiskslinuxblock.c -index 829dd5f78..a3fa183be 100644 ---- a/src/udiskslinuxblock.c -+++ b/src/udiskslinuxblock.c -@@ -1541,7 +1541,15 @@ add_remove_fstab_entry (UDisksBlock *block, - &contents, - NULL, - error)) -- goto out; -+ { -+ if (g_error_matches (*error, G_FILE_ERROR, G_FILE_ERROR_NOENT)) -+ { -+ contents = g_strdup (""); -+ g_clear_error (error); -+ } -+ else -+ goto out; -+ } - - lines = g_strsplit (contents, "\n", 0); - diff --git a/udisks-2.11.0-udiskslinuxmanager_use_after_free.patch b/udisks-2.11.0-udiskslinuxmanager_use_after_free.patch deleted file mode 100644 index 3157b10..0000000 --- a/udisks-2.11.0-udiskslinuxmanager_use_after_free.patch +++ /dev/null @@ -1,112 +0,0 @@ -From 3dc036fb5045fc068c6abfbe4e62d0871d7ca82a Mon Sep 17 00:00:00 2001 -From: xinpeng wang -Date: Thu, 21 Sep 2023 13:57:40 +0800 -Subject: [PATCH] udiskslinuxmanager:use dbus interface after free - -In handle_get_block_devices, call get_block_objects to obtain iface_block_device -of all current UDisksLinuxBlockObject, and then obtain the corresponding -UDisksLinuxBlockObject's object_path through iface_block_device.iface_block_device -is a GDBusInterfaceSkeleton, which saves the object through -g_dbus_interface_skeleton_set_object. g_object_add_weak_pointer is used here. This -function is not thread-safe.At this time, if other threads are releasing the object, -the program will crash. -This scene can be reproduced by quickly plugging and unplugging the USB disk. -The core is as follows (the redundant stack is omitted): -When accessing object in thread 1, the object is released by thread 2 -info threads - Id Target Id Frame -* 1 Thread 0x7f80979e70 (LWP 24559) 0x0000007f8a48dda0 in -g_dbus_object_get_object_path (object=0x0) at ../../../gio/gdbusobject.c:109 - 2 Thread 0x7f88a43010 (LWP 1159) 0x0000007f8a0a6ae8 in __GI___libc_free -(mem=0x556a919c80) at malloc.c:3093 - -thread 1 -(gdb) bt -0 0x0000007f8a48dda0 in g_dbus_object_get_object_path (object=0x0) at -../../../gio/gdbusobject.c:109 -1 0x000000556a56911c in handle_get_block_devices (object=0x7f7c007ed0, invocation= -0x7f74016f20 [GDBusMethodInvocation], arg_options=) - at udiskslinuxmanager.c:1063 - -(gdb) p ((GObject*)(blocks_p->data))->ref_count -$3 = 1 -(gdb) p *((GDBusInterfaceSkeleton*)(blocks_p->data)) -$6 = {parent_instance = {g_type_instance = {g_class = 0x556a64e740 -[g_type: UDisksLinuxBlock/UDisksBlockSkeleton/GDBusInterfaceSkeleton]}, ref_count = 1, -qdata = 0x0}, priv = 0x7f7c004ac0} -(gdb) p *((GDBusInterfaceSkeleton*)(blocks_p->data))->priv -$7 = {lock = {p = 0x0, i = {0, 0}}, object = 0x0, -flags = G_DBUS_INTERFACE_SKELETON_FLAGS_HANDLE_METHOD_INVOCATIONS_IN_THREAD, -connections = 0x0, object_path = 0x0, hooked_vtable = 0x556a62b9f0} - -thread 2 -(gdb) bt -0 0x0000007f8a0a6ae8 in __GI___libc_free (mem=0x556a919c80) at malloc.c:3093 -1 0x0000007f89ff1224 in () at /lib/aarch64-linux-gnu/libudev.so.1 -2 0x0000007f89ff1348 in () at /lib/aarch64-linux-gnu/libudev.so.1 -3 0x0000007f89ff5520 in () at /lib/aarch64-linux-gnu/libudev.so.1 -4 0x0000007f89fff878 in udev_device_unref () at /lib/aarch64-linux-gnu/libudev.so.1 -5 0x0000007f8a7aeb74 in () at /lib/aarch64-linux-gnu/libgudev-1.0.so.0 -6 0x0000007f8a3193f8 in g_object_unref (_object=) at -../../../gobject/gobject.c:3346 -7 0x0000007f8a3193f8 in g_object_unref (_object=0x7f680038a0) at -../../../gobject/gobject.c:3238 -8 0x000000556a57700c in udisks_linux_device_finalize (object=0x7f5c005730 -[UDisksLinuxDevice]) at udiskslinuxdevice.c:75 -9 0x0000007f8a3193f8 in g_object_unref (_object=) at -../../../gobject/gobject.c:3346 -10 0x0000007f8a3193f8 in g_object_unref (_object=0x7f5c005730) at -../../../gobject/gobject.c:3238 -11 0x000000556a55d0fc in udisks_linux_drive_object_uevent - (object=object@entry=0x556a5df370 [UDisksLinuxDriveObject], -action=action@entry=0x556a87b120 -"remove",device=device@entry=0x7f74007610 [UDisksLinuxDevice]) - at udiskslinuxdriveobject.c:715 -12 0x000000556a54840c in handle_block_uevent_for_drive - (provider=provider@entry=0x556a5c8200 [UDisksLinuxProvider], -action=action@entry=0x556a87b120 "remove",device=device@entry=0x7f74007610 -[UDisksLinuxDevice]) at udiskslinuxprovider.c:1035 -13 0x000000556a548ab8 in handle_block_uevent (device=0x7f74007610 [UDisksLinuxDevice], -action=0x556a87b120 "remove", provider=0x556a5c8200 [UDisksLinuxProvider]) at -udiskslinuxprovider.c:1349 -14 0x000000556a548ab8 in udisks_linux_provider_handle_uevent - (provider=0x556a5c8200 [UDisksLinuxProvider], action=0x556a87b120 "remove", -device=0x7f74007610 [UDisksLinuxDevice]) at udiskslinuxprovider.c:1399 -15 0x000000556a548cac in on_idle_with_probed_uevent (user_data=0x556a7e65a0) at -udiskslinuxprovider.c:230 ---- - src/udiskslinuxmanager.c | 13 +++++++++---- - 1 file changed, 9 insertions(+), 4 deletions(-) - -diff --git a/src/udiskslinuxmanager.c b/src/udiskslinuxmanager.c -index 5bfeec103..491edb92b 100644 ---- a/src/udiskslinuxmanager.c -+++ b/src/udiskslinuxmanager.c -@@ -1196,8 +1196,11 @@ handle_get_block_devices (UDisksManager *object, - blocks = get_block_objects (object, &num_blocks); - block_paths = g_new0 (const gchar *, num_blocks + 1); - -- for (i = 0,blocks_p = blocks; blocks_p != NULL; blocks_p = blocks_p->next, i++) -- block_paths[i] = g_dbus_object_get_object_path (g_dbus_interface_get_object (G_DBUS_INTERFACE (blocks_p->data))); -+ for (blocks_p = blocks; blocks_p != NULL; blocks_p = blocks_p->next) { -+ GDBusObject * block_object = g_dbus_interface_get_object (G_DBUS_INTERFACE (blocks_p->data)); -+ if (block_object) -+ block_paths[i++] = g_dbus_object_get_object_path (block_object); -+ } - - udisks_manager_complete_get_block_devices (object, - invocation, -@@ -1284,9 +1287,11 @@ handle_resolve_device (UDisksManager *object, - } - - ret_paths = g_new0 (const gchar *, num_found + 1); -- for (i = 0,ret_p = ret; ret_p != NULL; ret_p = ret_p->next, i++) -+ for (i = 0,ret_p = ret; ret_p != NULL; ret_p = ret_p->next) - { -- ret_paths[i] = g_dbus_object_get_object_path (g_dbus_interface_get_object (G_DBUS_INTERFACE (ret_p->data))); -+ GDBusObject *block_object = g_dbus_interface_get_object (G_DBUS_INTERFACE (ret_p->data)); -+ if (block_object) -+ ret_paths[i++] = g_dbus_object_get_object_path (block_object); - } - - udisks_manager_complete_resolve_device (object, diff --git a/udisks2.spec b/udisks2.spec index c9dbbf5..96d4060 100644 --- a/udisks2.spec +++ b/udisks2.spec @@ -25,18 +25,13 @@ Name: udisks2 Summary: Disk Manager -Version: 2.10.1 -Release: 7%{?dist} +Version: 2.10.2 +Release: 1%{?dist} License: GPL-2.0-or-later URL: https://github.com/storaged-project/udisks Source0: https://github.com/storaged-project/udisks/releases/download/udisks-%{version}/udisks-%{version}.tar.bz2 Patch0: udisks-2.11.0-BLKRRPART_harder.patch -Patch1: udisks-2.11.0-targetcli_config.json_netif_timeout.patch -Patch2: udisks-2.11.0-udiskslinuxmanager_use_after_free.patch -Patch3: udisks-2.11.0-udiskslinuxblock_survive_missing_fstab.patch -# https://bugzilla.redhat.com/show_bug.cgi?id=2373301 -Patch4: udisks-2.10.91-udiskslinuxfilesystemhelpers_nodev,nosuid.patch BuildRequires: make BuildRequires: glib2-devel >= %{glib2_version} @@ -344,6 +339,9 @@ fi %endif %changelog +* Fri Aug 29 2025 Tomas Bzatek - 2.10.2-1 +- Version 2.10.2 + * Thu Jun 19 2025 Tomas Bzatek - 2.10.1-7 - Harden temporary private mounts (#2373301) From 377b64ef212b22f9b894f611b1dafafc7b6e3f91 Mon Sep 17 00:00:00 2001 From: Tomas Bzatek Date: Thu, 6 Nov 2025 17:34:45 +0100 Subject: [PATCH 08/14] * Thu Nov 06 2025 Tomas Bzatek - 2.11.0-1 - Version 2.11.0 --- .gitignore | 1 + sources | 2 +- udisks2.spec | 7 +++++-- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 459124a..8df46b3 100644 --- a/.gitignore +++ b/.gitignore @@ -21,3 +21,4 @@ /udisks-2.10.1.tar.bz2 /udisks-2.10.90.tar.bz2 /udisks-2.10.91.tar.bz2 +/udisks-2.11.0.tar.bz2 diff --git a/sources b/sources index cf76c85..da0149d 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (udisks-2.10.91.tar.bz2) = 85a11c7509317b1d53d2864f474b03a70773cc5964ab16ba42ed2704f9f95aa704585d40e55a5b86a63a8b4363caafafad03b1bdfecf282c9ee05a1b5644d3a2 +SHA512 (udisks-2.11.0.tar.bz2) = ddf7bbf6d71c100ea2787aa45d51ae84d8184d33d9e0c1c8824e3da1ca34814b3278f9f74a1aab7acc37efe3ed2b702404fbb9dc3733c0accbb366a74e7d3fe5 diff --git a/udisks2.spec b/udisks2.spec index 4fa73de..d086c17 100644 --- a/udisks2.spec +++ b/udisks2.spec @@ -4,7 +4,7 @@ %global systemd_version 208 %global dbus_version 1.4.0 %global with_gtk_doc 1 -%global libblockdev_version 3.2 +%global libblockdev_version 3.4 %define with_btrfs 1 %ifnarch %{ix86} @@ -24,7 +24,7 @@ Name: udisks2 Summary: Disk Manager -Version: 2.10.91 +Version: 2.11.0 Release: 1%{?dist} License: GPL-2.0-or-later URL: https://github.com/storaged-project/udisks @@ -340,6 +340,9 @@ fi %endif %changelog +* Thu Nov 06 2025 Tomas Bzatek - 2.11.0-1 +- Version 2.11.0 + * Fri Aug 29 2025 Tomas Bzatek - 2.10.91-1 - Version 2.10.91 From ff3d7f2ec7906b9b6ba4b00e27ab5795920bdbe0 Mon Sep 17 00:00:00 2001 From: Tom spot Callaway Date: Wed, 17 Dec 2025 13:51:06 -0500 Subject: [PATCH 09/14] rebuild for new libconfig --- udisks2.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/udisks2.spec b/udisks2.spec index d086c17..00db129 100644 --- a/udisks2.spec +++ b/udisks2.spec @@ -25,7 +25,7 @@ Name: udisks2 Summary: Disk Manager Version: 2.11.0 -Release: 1%{?dist} +Release: 2%{?dist} License: GPL-2.0-or-later URL: https://github.com/storaged-project/udisks Source0: https://github.com/storaged-project/udisks/releases/download/udisks-%{version}/udisks-%{version}.tar.bz2 @@ -340,6 +340,9 @@ fi %endif %changelog +* Wed Dec 17 2025 Tom Callaway - 2.11.0-2 +- rebuild for new libconfig + * Thu Nov 06 2025 Tomas Bzatek - 2.11.0-1 - Version 2.11.0 From c73f9d51f8f8363475f8a9084f0f1023c38ca8da Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Sat, 17 Jan 2026 19:32:36 +0000 Subject: [PATCH 10/14] Rebuilt for https://fedoraproject.org/wiki/Fedora_44_Mass_Rebuild --- udisks2.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/udisks2.spec b/udisks2.spec index 00db129..709be46 100644 --- a/udisks2.spec +++ b/udisks2.spec @@ -25,7 +25,7 @@ Name: udisks2 Summary: Disk Manager Version: 2.11.0 -Release: 2%{?dist} +Release: 3%{?dist} License: GPL-2.0-or-later URL: https://github.com/storaged-project/udisks Source0: https://github.com/storaged-project/udisks/releases/download/udisks-%{version}/udisks-%{version}.tar.bz2 @@ -340,6 +340,9 @@ fi %endif %changelog +* Sat Jan 17 2026 Fedora Release Engineering - 2.11.0-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_44_Mass_Rebuild + * Wed Dec 17 2025 Tom Callaway - 2.11.0-2 - rebuild for new libconfig From c46c30a7bb2879b397bbc4f47afb8fab65583b6f Mon Sep 17 00:00:00 2001 From: Tomas Bzatek Date: Wed, 25 Feb 2026 16:32:39 +0100 Subject: [PATCH 11/14] * Wed Feb 25 2026 Tomas Bzatek - 2.11.1-1 - Version 2.11.1 (#2442584,#2442588) --- .gitignore | 1 + sources | 2 +- udisks2.spec | 7 +++++-- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 8df46b3..f1e025e 100644 --- a/.gitignore +++ b/.gitignore @@ -22,3 +22,4 @@ /udisks-2.10.90.tar.bz2 /udisks-2.10.91.tar.bz2 /udisks-2.11.0.tar.bz2 +/udisks-2.11.1.tar.bz2 diff --git a/sources b/sources index da0149d..ecae2c7 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (udisks-2.11.0.tar.bz2) = ddf7bbf6d71c100ea2787aa45d51ae84d8184d33d9e0c1c8824e3da1ca34814b3278f9f74a1aab7acc37efe3ed2b702404fbb9dc3733c0accbb366a74e7d3fe5 +SHA512 (udisks-2.11.1.tar.bz2) = c2ef8c1068f109bcc858a897cb45af970442170fc8dd991d5692b463c7f4693fe4731e4e5010bc923588a7ee9f1c794630ad5fffef454a9d959bcf17e8bf704f diff --git a/udisks2.spec b/udisks2.spec index 709be46..dee75c8 100644 --- a/udisks2.spec +++ b/udisks2.spec @@ -24,8 +24,8 @@ Name: udisks2 Summary: Disk Manager -Version: 2.11.0 -Release: 3%{?dist} +Version: 2.11.1 +Release: 1%{?dist} License: GPL-2.0-or-later URL: https://github.com/storaged-project/udisks Source0: https://github.com/storaged-project/udisks/releases/download/udisks-%{version}/udisks-%{version}.tar.bz2 @@ -340,6 +340,9 @@ fi %endif %changelog +* Wed Feb 25 2026 Tomas Bzatek - 2.11.1-1 +- Version 2.11.1 (#2442584,#2442588) + * Sat Jan 17 2026 Fedora Release Engineering - 2.11.0-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_44_Mass_Rebuild From 53368c732a9153ffc15ee14cb7ac2e674dd3cb2f Mon Sep 17 00:00:00 2001 From: Tomas Bzatek Date: Wed, 1 Apr 2026 16:24:56 +0200 Subject: [PATCH 12/14] * Wed Apr 01 2026 Tomas Bzatek - 2.11.1-2 - Use 'sys_tz' exfat mount option by default (#2403452) --- udisks-2.11.90-exfat_mount_opts.patch | 32 +++++++++++++++++++++++++++ udisks2.spec | 10 ++++++++- 2 files changed, 41 insertions(+), 1 deletion(-) create mode 100644 udisks-2.11.90-exfat_mount_opts.patch diff --git a/udisks-2.11.90-exfat_mount_opts.patch b/udisks-2.11.90-exfat_mount_opts.patch new file mode 100644 index 0000000..2db7040 --- /dev/null +++ b/udisks-2.11.90-exfat_mount_opts.patch @@ -0,0 +1,32 @@ +From b86e14e97f4bbe659bef4d7aaf970df671e78a09 Mon Sep 17 00:00:00 2001 +From: Tomas Bzatek +Date: Wed, 1 Apr 2026 16:08:37 +0200 +Subject: [PATCH] mount options: Sync exfat allowed options with the latest + kernel + +In an ideal case we'd like to have 'sys_tz' turned on by default, +however that option was only added later and the kernel driver +refuses unknown options, so we can't do that to maintain broad +compatibility. +--- + data/builtin_mount_options.conf | 3 +-- + 1 file changed, 1 insertion(+), 2 deletions(-) + +diff --git a/data/builtin_mount_options.conf b/data/builtin_mount_options.conf +index 2a09a109..d9d30422 100644 +--- a/data/builtin_mount_options.conf ++++ b/data/builtin_mount_options.conf +@@ -4,9 +4,8 @@ allow=exec,noexec,nodev,nosuid,atime,noatime,nodiratime,relatime,strictatime,laz + vfat_defaults=uid=$UID,gid=$GID,shortname=mixed,utf8=1,showexec,flush + vfat_allow=uid=$UID,gid=$GID,flush,utf8,shortname,umask,dmask,fmask,codepage,iocharset,usefree,showexec + +-# common options for both the native kernel driver and exfat-fuse + exfat_defaults=uid=$UID,gid=$GID,iocharset=utf8,errors=remount-ro +-exfat_allow=uid=$UID,gid=$GID,dmask,errors,fmask,iocharset,namecase,umask ++exfat_allow=uid=$UID,gid=$GID,umask,dmask,fmask,allow_utime,iocharset,errors,discard,keep_last_dots,sys_tz,time_offset,zero_size_dir,namecase,codepage + + # 'ntfs' signature, definitions for the legacy ntfs kernel driver and the ntfs-3g fuse driver + ntfs:ntfs_defaults=uid=$UID,gid=$GID,windows_names +-- +2.53.0 + diff --git a/udisks2.spec b/udisks2.spec index dee75c8..ba5e5b9 100644 --- a/udisks2.spec +++ b/udisks2.spec @@ -25,11 +25,15 @@ Name: udisks2 Summary: Disk Manager Version: 2.11.1 -Release: 1%{?dist} +Release: 2%{?dist} License: GPL-2.0-or-later URL: https://github.com/storaged-project/udisks Source0: https://github.com/storaged-project/udisks/releases/download/udisks-%{version}/udisks-%{version}.tar.bz2 +# https://bugzilla.redhat.com/show_bug.cgi?id=2403452 +# Please set sys_tz by default for udisks2 exfat mounts +Patch0: udisks-2.11.90-exfat_mount_opts.patch + BuildRequires: make BuildRequires: glib2-devel >= %{glib2_version} BuildRequires: gobject-introspection-devel >= %{gobject_introspection_version} @@ -197,6 +201,7 @@ rm -f src/tests/dbus-tests/config_h.py rm -f src/udisks-daemon-resources.{c,h} # default to ntfs-3g (#2182206) sed -i data/builtin_mount_options.conf -e 's/ntfs_drivers=ntfs3,ntfs/ntfs_drivers=ntfs,ntfs3/' +sed -i data/builtin_mount_options.conf -e 's/exfat_defaults=uid=\$UID,gid=\$GID,iocharset=utf8,errors=remount-ro/exfat_defaults=uid=\$UID,gid=\$GID,iocharset=utf8,errors=remount-ro,sys_tz/' %build # autoreconf -ivf @@ -340,6 +345,9 @@ fi %endif %changelog +* Wed Apr 01 2026 Tomas Bzatek - 2.11.1-2 +- Use 'sys_tz' exfat mount option by default (#2403452) + * Wed Feb 25 2026 Tomas Bzatek - 2.11.1-1 - Version 2.11.1 (#2442584,#2442588) From d0dc33ff9956d23d46fa78ffbcd373a7b255e958 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Fri, 17 Jul 2026 08:06:45 +0000 Subject: [PATCH 13/14] Rebuilt for https://fedoraproject.org/wiki/Fedora_45_Mass_Rebuild --- udisks2.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/udisks2.spec b/udisks2.spec index ba5e5b9..5b09b20 100644 --- a/udisks2.spec +++ b/udisks2.spec @@ -25,7 +25,7 @@ Name: udisks2 Summary: Disk Manager Version: 2.11.1 -Release: 2%{?dist} +Release: 3%{?dist} License: GPL-2.0-or-later URL: https://github.com/storaged-project/udisks Source0: https://github.com/storaged-project/udisks/releases/download/udisks-%{version}/udisks-%{version}.tar.bz2 @@ -345,6 +345,9 @@ fi %endif %changelog +* Fri Jul 17 2026 Fedora Release Engineering - 2.11.1-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_45_Mass_Rebuild + * Wed Apr 01 2026 Tomas Bzatek - 2.11.1-2 - Use 'sys_tz' exfat mount option by default (#2403452) From d15091ac2c8016330a81de72ca8e47d1ee239f6a Mon Sep 17 00:00:00 2001 From: Tomas Bzatek Date: Thu, 6 Aug 2026 17:34:30 +0200 Subject: [PATCH 14/14] * Thu Aug 06 2026 Tomas Bzatek - 2.11.2-1 - Version 2.11.2 --- .gitignore | 1 + sources | 2 +- udisks-2.11.90-exfat_mount_opts.patch | 32 --------------------------- udisks2.spec | 11 +++++---- 4 files changed, 7 insertions(+), 39 deletions(-) delete mode 100644 udisks-2.11.90-exfat_mount_opts.patch diff --git a/.gitignore b/.gitignore index f1e025e..9b451cd 100644 --- a/.gitignore +++ b/.gitignore @@ -23,3 +23,4 @@ /udisks-2.10.91.tar.bz2 /udisks-2.11.0.tar.bz2 /udisks-2.11.1.tar.bz2 +/udisks-2.11.2.tar.bz2 diff --git a/sources b/sources index ecae2c7..e41b09d 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (udisks-2.11.1.tar.bz2) = c2ef8c1068f109bcc858a897cb45af970442170fc8dd991d5692b463c7f4693fe4731e4e5010bc923588a7ee9f1c794630ad5fffef454a9d959bcf17e8bf704f +SHA512 (udisks-2.11.2.tar.bz2) = 3996ac935cb330eb7f286f25a716da52ca374b14cc7b4f2e60a7e4b0b0745559607fa8c6d1e96e777b44eb8e07eb16e1ad6bc00b3051adea14e865df3efa2662 diff --git a/udisks-2.11.90-exfat_mount_opts.patch b/udisks-2.11.90-exfat_mount_opts.patch deleted file mode 100644 index 2db7040..0000000 --- a/udisks-2.11.90-exfat_mount_opts.patch +++ /dev/null @@ -1,32 +0,0 @@ -From b86e14e97f4bbe659bef4d7aaf970df671e78a09 Mon Sep 17 00:00:00 2001 -From: Tomas Bzatek -Date: Wed, 1 Apr 2026 16:08:37 +0200 -Subject: [PATCH] mount options: Sync exfat allowed options with the latest - kernel - -In an ideal case we'd like to have 'sys_tz' turned on by default, -however that option was only added later and the kernel driver -refuses unknown options, so we can't do that to maintain broad -compatibility. ---- - data/builtin_mount_options.conf | 3 +-- - 1 file changed, 1 insertion(+), 2 deletions(-) - -diff --git a/data/builtin_mount_options.conf b/data/builtin_mount_options.conf -index 2a09a109..d9d30422 100644 ---- a/data/builtin_mount_options.conf -+++ b/data/builtin_mount_options.conf -@@ -4,9 +4,8 @@ allow=exec,noexec,nodev,nosuid,atime,noatime,nodiratime,relatime,strictatime,laz - vfat_defaults=uid=$UID,gid=$GID,shortname=mixed,utf8=1,showexec,flush - vfat_allow=uid=$UID,gid=$GID,flush,utf8,shortname,umask,dmask,fmask,codepage,iocharset,usefree,showexec - --# common options for both the native kernel driver and exfat-fuse - exfat_defaults=uid=$UID,gid=$GID,iocharset=utf8,errors=remount-ro --exfat_allow=uid=$UID,gid=$GID,dmask,errors,fmask,iocharset,namecase,umask -+exfat_allow=uid=$UID,gid=$GID,umask,dmask,fmask,allow_utime,iocharset,errors,discard,keep_last_dots,sys_tz,time_offset,zero_size_dir,namecase,codepage - - # 'ntfs' signature, definitions for the legacy ntfs kernel driver and the ntfs-3g fuse driver - ntfs:ntfs_defaults=uid=$UID,gid=$GID,windows_names --- -2.53.0 - diff --git a/udisks2.spec b/udisks2.spec index 5b09b20..0d1136b 100644 --- a/udisks2.spec +++ b/udisks2.spec @@ -24,16 +24,12 @@ Name: udisks2 Summary: Disk Manager -Version: 2.11.1 -Release: 3%{?dist} +Version: 2.11.2 +Release: 1%{?dist} License: GPL-2.0-or-later URL: https://github.com/storaged-project/udisks Source0: https://github.com/storaged-project/udisks/releases/download/udisks-%{version}/udisks-%{version}.tar.bz2 -# https://bugzilla.redhat.com/show_bug.cgi?id=2403452 -# Please set sys_tz by default for udisks2 exfat mounts -Patch0: udisks-2.11.90-exfat_mount_opts.patch - BuildRequires: make BuildRequires: glib2-devel >= %{glib2_version} BuildRequires: gobject-introspection-devel >= %{gobject_introspection_version} @@ -345,6 +341,9 @@ fi %endif %changelog +* Thu Aug 06 2026 Tomas Bzatek - 2.11.2-1 +- Version 2.11.2 + * Fri Jul 17 2026 Fedora Release Engineering - 2.11.1-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_45_Mass_Rebuild