Skip to content

Release: sign a copy of the exe and write it back in place - #508

Merged
fstubner merged 1 commit into
mainfrom
fix/sign-pe-copy-back
Oct 4, 2026
Merged

fstubner merged 1 commit into
mainfrom
fix/sign-pe-copy-back

Conversation

@fstubner

@fstubner fstubner commented Oct 4, 2026

Copy link
Copy Markdown
Owner

The job summary from #506 gave the v0.3.4 failure: ssign's in-place signing ends in atomically replacing ...netscli-gui.exe: Access is denied (os error 5). Inside tauri build the patched exe is still held open without delete sharing, so ssign's rename over it is refused.

The wrapper now signs into a temp directory (ssign -o) and writes the signed bytes back over the original, which needs only write access, with up to ten one-second retries.

Reproduced and verified on a Windows runner (temporary PR #507) with the real signer and the test exe held open without FileShare.Delete:

  • old wrapper: exit 1, atomically replacing ... Access is denied. (os error 5), file NotSigned
  • new wrapper: exit 0, Get-AuthenticodeSignature → Valid, signed by the Certum certificate

Once merged, re-running the failed v0.3.4 release job picks this up (the wrapper is fetched from the default branch).

Inside tauri build, ssign's in-place signing failed with "atomically
replacing ...netscli-gui.exe: Access is denied (os error 5)": the bundler
still holds the patched exe open without delete sharing, so a rename over
it is refused. This lost v0.3.4 its Windows build.

Sign into a temporary directory with -o and copy the bytes back over the
original, which needs only write access, retrying for up to ten seconds.
Reproduced on a Windows runner with the real signer and the exe held open
without FileShare.Delete: the old wrapper fails with the same error, the new
one exits 0 and Get-AuthenticodeSignature reports Valid.
@fstubner
fstubner merged commit 7a84ca7 into main Oct 4, 2026
15 checks passed
@fstubner
fstubner deleted the fix/sign-pe-copy-back branch October 6, 2026 18:29
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.

1 participant