[tbb-commits] [Git][tpo/applications/tor-browser-build][main] Bug 40844: Fix reproducibility issue in hfsplus-tools when hwclock is set to local time

boklm (@boklm) git at gitlab.torproject.org
Mon Apr 17 16:58:44 UTC 2023



boklm pushed to branch main at The Tor Project / Applications / tor-browser-build


Commits:
a00cfb3c by Nicolas Vigier at 2023-04-17T18:58:08+02:00
Bug 40844: Fix reproducibility issue in hfsplus-tools when hwclock is set to local time

- - - - -


4 changed files:

- projects/hfsplus-tools/build
- projects/hfsplus-tools/config
- + projects/hfsplus-tools/ignore-timezone.diff
- tools/signing/gatekeeper-bundling.sh


Changes:

=====================================
projects/hfsplus-tools/build
=====================================
@@ -11,6 +11,7 @@ tar -xf diskdev_cmds-[% c("version") %].tar.gz
 cd diskdev_cmds-[% c("version") %]
 
 patch -p1 < $rootdir/newfs_hfs.diff
+patch -p1 < $rootdir/ignore-timezone.diff
 
 make -j[% c("num_procs") %]
 


=====================================
projects/hfsplus-tools/config
=====================================
@@ -21,3 +21,6 @@ input_files:
   # exist on Linux (at that path) and is not required on Linux either, and make
   # the UUID deterministic.
   - filename: newfs_hfs.diff
+  # Remove UTCToLocal conversion to avoid a different result when hwclock
+  # is set to local time or utc time (tor-browser-build#40844)
+  - filename: ignore-timezone.diff


=====================================
projects/hfsplus-tools/ignore-timezone.diff
=====================================
@@ -0,0 +1,13 @@
+diff -ru diskdev_cmds-540.1.linux3/newfs_hfs.tproj/makehfs.c diskdev_cmds-540.1.linux3.n/newfs_hfs.tproj/makehfs.c
+--- diskdev_cmds-540.1.linux3/newfs_hfs.tproj/makehfs.c	2012-02-02 23:36:59.000000000 +0100
++++ diskdev_cmds-540.1.linux3.n/newfs_hfs.tproj/makehfs.c	2023-04-17 13:59:41.993000000 +0200
+@@ -463,8 +463,7 @@
+ 	}
+ 	hp->lastMountedVersion = kHFSPlusMountVersion;
+ 
+-	/* NOTE: create date is in local time, not GMT!  */
+-	hp->createDate = UTCToLocal(defaults->createDate);
++	hp->createDate = defaults->createDate;
+ 	hp->modifyDate = defaults->createDate;
+ 	hp->backupDate = 0;
+ 	hp->checkedDate = defaults->createDate;


=====================================
tools/signing/gatekeeper-bundling.sh
=====================================
@@ -45,7 +45,7 @@ test -f "$libdmg_file" || \
              "You can build it with:" \
              "  ./rbm/rbm build --target no_containers libdmg-hfsplus" \
              "See var/deps in projects/libdmg-hfsplus/config for the list of build dependencies"
-hfstools_file="$script_dir/../../out/hfsplus-tools/hfsplus-tools-540.1.linux3-66de66.tar.gz"
+hfstools_file="$script_dir/../../out/hfsplus-tools/hfsplus-tools-540.1.linux3-81ff5b.tar.gz"
 test -f "$hfstools_file" || \
   exit_error "$hfstools_file is missing." \
              "You can build it with:" \



View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser-build/-/commit/a00cfb3ccb3253fbb25efe91c030617fef5f7fef

-- 
View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser-build/-/commit/a00cfb3ccb3253fbb25efe91c030617fef5f7fef
You're receiving this email because of your account on gitlab.torproject.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.torproject.org/pipermail/tbb-commits/attachments/20230417/f3b8e953/attachment-0001.htm>


More information about the tbb-commits mailing list