ENT-13792: Made Windows MSI assembly fully reproducible#2366
Open
larsewi wants to merge 3 commits into
Open
Conversation
larsewi
force-pushed
the
reproducible-msi-builds
branch
from
July 21, 2026 14:58
4a42102 to
bb5abf3
Compare
The issue was that wixl bakes a random package code, wall-clock summary-info timestamps, and per-file CAB timestamps into the MSI. Furthermore, the wxs file used a random ProductCode. Hence, two builds of identical source produced different MSIs. Fixed it by deriving the ProductCode and package code deterministically from the version, pinning the CAB file mtimes and summary-info to SOURCE_DATE_EPOCH. Ticket: ENT-13792 Signed-off-by: Lars Erik Wik <lars.erik.wik@northern.tech>
build-scripts/package-msi now uses uuidgen for deterministic MSI GUIDs. Ticket: ENT-13792 Signed-off-by: Lars Erik Wik <lars.erik.wik@northern.tech>
larsewi
force-pushed
the
reproducible-msi-builds
branch
from
July 21, 2026 15:18
ab91c5e to
4ee1901
Compare
Early placement deleted equal-versioned shared DLLs on upgrade, leaving cf-agent unable to load. Installing new files before removing the old product keeps them via refcounting. Ref: https://learn.microsoft.com/en-us/windows/win32/msi/removeexistingproducts-action Signed-off-by: Lars Erik Wik <lars.erik.wik@northern.tech>
larsewi
marked this pull request as ready for review
July 22, 2026 10:48
Contributor
Author
Contributor
Author
|
^ packages-based tests are unrealted to MinGW only build |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The issue was that wixl bakes a random package code, wall-clock summary-info timestamps, and per-file CAB timestamps into the MSI. Further more the wxs file used a random ProductCode. Hence, two builds of identical source produced different MSIs.
Fixed it by deriving the ProductCode and package code deterministically from the version, pinning the CAB file mtimes and summary-info to
SOURCE_DATE_EPOCH.