Skip to content

Normalize zip host os byte for cross os determinism#107

Merged
SimonCropp merged 5 commits into
mainfrom
Normalize-ZIP-host-OS-byte-for-cross-OS-determinism
Jun 30, 2026
Merged

Normalize zip host os byte for cross os determinism#107
SimonCropp merged 5 commits into
mainfrom
Normalize-ZIP-host-OS-byte-for-cross-OS-determinism

Conversation

@SimonCropp

Copy link
Copy Markdown
Owner

No description provided.

ZipArchive stamps the build OS into each central-directory record
(version-made-by high byte 0 on Windows, 3 on Unix), so output bytes
differed by OS. ZipPlatformNormalizer rewrites that byte to 0 and clears
external attributes after building into a buffer; Convert/ConvertAsync
now buffer-then-normalize-then-copy.
@SimonCropp SimonCropp added this to the 0.28.0 milestone Jun 30, 2026
@SimonCropp SimonCropp merged commit 8d2b65c into main Jun 30, 2026
2 of 4 checks passed
@SimonCropp SimonCropp deleted the Normalize-ZIP-host-OS-byte-for-cross-OS-determinism branch June 30, 2026 11:37
@0xced

0xced commented Jun 30, 2026

Copy link
Copy Markdown

So, you already had a DeterministicIoPackaging project for this kind of stuff. 😲
And you just implemented patching of version made by in a few minutes. You're a legend, Simon!

@SimonCropp

Copy link
Copy Markdown
Owner Author

@0xced but i need to crash now. will deploy tomorrow

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants