-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Missing signature on Squirrel ExecutionStub #8952
Comments
@beyondkmp can you please take a look at this when you have a chance? |
Based on the analysis of Squirrel Windows source code, when createExecutableStubForExe is executed, WriteZipToSetup writes information to the file, essentially creating a new file, which invalidates the original signature. It seems Windows Installer doesn't support hookFunction(electron/windows-installer#548), and electron-builder can't re-sign the newly generated stubExe file. Currently, there are three potential solutions:
@mmaietta Which solution do you think is better? |
Empirically this did not work for me, given I'm just using the system signtool.exe + and it was failing as you previously investigated |
I've come up with a solution. Apply a patch to the Squirrel Windows source code. For the existing stub exe files, don't generate them anymore. Then, a new stub exe can be generated in Electron Builder and signed. The version of Squirrel Windows 2 has been around for nearly five years. In fact, its develop branch has been constantly updated and many bugs have been fixed. So we can take this opportunity to directly generate and use the latest version. |
I've already compiled Squirrel Windows locally. I'll trigger a release on GitHub Actions, so there won't be any security concerns either. |
Sure thing @beyondkmp - started tests in element-hq/element-desktop#2211 - will report back in the PR |
@beyondkmp , what do you mean by this? |
I mean these files are all generated by GitHub Actions, directly compiled from source code. They are not compiled on my local machine, so there's no need to worry about any backdoors being injected. These vendor files are copied from the GitHub Actions workflow at https://github.com/beyondkmp/Squirrel.Windows/actions/runs/13871759240/job/38819263248 and the other files(like 7zip,nuget) are copiled from https://github.com/electron/windows-installer/tree/main/vendor. https://github.com/Squirrel/Squirrel.Windows/pull/1903/files |
element-hq/element-desktop#2204 for context
Missing sig on the execution stub e.g.
Broken:

Good:

(same was true for 1.11.94 but we had to pull the package due to Node N-API issues)
Good in 26.0.1
Bad in 26.0.8
Still bad in 26.0.11
The text was updated successfully, but these errors were encountered: