diff --git a/apps/desktop/src/main/window.main.ts b/apps/desktop/src/main/window.main.ts index f1a55866079..4d9438b588d 100644 --- a/apps/desktop/src/main/window.main.ts +++ b/apps/desktop/src/main/window.main.ts @@ -16,7 +16,15 @@ import { BiometricStateService } from "@bitwarden/key-management"; import { WindowState } from "../platform/models/domain/window-state"; import { applyMainWindowStyles, applyPopupModalStyles } from "../platform/popup-modal-styles"; import { DesktopSettingsService } from "../platform/services/desktop-settings.service"; -import { cleanUserAgent, isDev, isLinux, isMac, isMacAppStore, isWindows } from "../utils"; +import { + cleanUserAgent, + isDev, + isLinux, + isMac, + isMacAppStore, + isSnapStore, + isWindows, +} from "../utils"; const mainWindowSizeKey = "mainWindowSize"; const WindowEventHandlingDelay = 100; @@ -156,9 +164,8 @@ export class WindowMain { } } - // this currently breaks the file portal, so should only be used when - // no files are needed but security requirements are super high https://github.com/flatpak/xdg-desktop-portal/issues/785 - if (process.env.EXPERIMENTAL_PREVENT_DEBUGGER_MEMORY_ACCESS === "true") { + // this currently breaks the file portal for snap https://github.com/flatpak/xdg-desktop-portal/issues/785 + if (!isSnapStore()) { this.logService.info("Disabling memory dumps in main process"); try { await processisolations.disableMemoryAccess();