File tree Expand file tree Collapse file tree 2 files changed +13
-7
lines changed
Expand file tree Collapse file tree 2 files changed +13
-7
lines changed Original file line number Diff line number Diff line change @@ -277,12 +277,6 @@ Security.runVerification(isProduction).then(async isValid => {
277277 } )
278278
279279 if ( isMainWindow ) {
280- ipcMain . once ( `commoners:ready:${ __id } ` , ( ) => {
281- Window . setMainWindow ( win )
282- Window . setFirstInitialized ( )
283- Window . flushReadyQueue ( win )
284- } )
285-
286280 win . once ( 'close' , ( ) => {
287281 Window . setMainWindow ( null )
288282 } )
Original file line number Diff line number Diff line change @@ -160,9 +160,21 @@ async function injectSEABlob(
160160 // Set executable permissions
161161 chmodSync ( executablePath , 0o755 )
162162 } else if ( platform === 'win32' ) {
163- // Windows: Direct injection
163+ // Windows: Remove signature before injection (if present)
164+ try {
165+ // Try to remove signature using signtool (from Windows SDK)
166+ execSync ( `signtool remove /s "${ executablePath } "` , { stdio : 'pipe' } )
167+ } catch {
168+ // Ignore if signtool is not available or signature removal fails
169+ // postject can still work but may show warnings
170+ }
171+
172+ // Inject with postject
164173 const injectCmd = `npx postject "${ executablePath } " NODE_SEA_BLOB "${ blobPath } " --sentinel-fuse ${ sentinelFuse } `
165174 execSync ( injectCmd , { stdio : 'pipe' } )
175+
176+ // Note: Executable will be unsigned after injection
177+ // Re-sign later as part of the Electron app signing process
166178 } else {
167179 throw new PlatformError (
168180 'SEA not supported on platform' ,
You can’t perform that action at this time.
0 commit comments