ASAR完整性

    如果你使用 或 >= @electron-forge/core@6.0.0-beta.61 那么将满足所有需求, 你可以直接跳到 章节

    其他构建系统

    Your must then populate a valid ElectronAsarIntegrity dictionary block in your packaged apps Info.plist. An example is included below.

    ASAR integrity checking is currently disabled by default and can be enabled by toggling a fuse. See Electron Fuses for more information on what Electron Fuses are and how they work. When enabling this fuse you typically also want to enable the onlyLoadAppFromAsar fuse otherwise the validity checking can be bypassed via the Electron app code search path.

    1. require('@electron/fuses').flipFuses(
    2. pathToPackagedApp,
    3. {
    4. [FuseV1Options.EnableEmbeddedAsarIntegrityValidation]: true,
    5. [FuseV1Options.OnlyLoadAppFromAsar]: true
    6. }