diff --git a/electron/main.js b/electron/main.js index 5a83afaf..4441288f 100644 --- a/electron/main.js +++ b/electron/main.js @@ -1105,7 +1105,8 @@ app.whenReady().then(async () => { // Strip X-Frame-Options and CSP frame-ancestors directives on iframe subframe loads so the Windows BrowserCard iframe fallback (used because tag commit segfaults on Chromium 144 + this Electron 40 CastLabs build) can render sites that normally refuse to be embedded. Scoped to types:['sub_frame'] so OAuth popups, the main app frame, deep-link redirects, and DRM license fetches keep their security headers intact. urls filter limits to http/https so file:// loads of the bundled frontend are untouched. session.defaultSession.webRequest.onHeadersReceived( - { urls: ['http://*/*', 'https://*/*'], types: ['sub_frame'] }, + // Electron's webRequest type name for iframes is 'subFrame' (camelCase), not the Chrome-extension 'sub_frame' — passing the wrong name throws "Invalid type sub_frame" synchronously which becomes an unhandledRejection and prevents the app from booting. + { urls: ['http://*/*', 'https://*/*'], types: ['subFrame'] }, (details, callback) => { const headers = { ...(details.responseHeaders || {}) }; for (const k of Object.keys(headers)) { diff --git a/electron/package.json b/electron/package.json index 4bfdad82..b546b81b 100644 --- a/electron/package.json +++ b/electron/package.json @@ -1,6 +1,6 @@ { "name": "openswarm", - "version": "1.1.55", + "version": "1.1.56", "description": "OpenSwarm — AI Agent Orchestrator", "author": "openswarm-ai", "main": "main.js",