Skip to content
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

The Mac App store now rejects all Electron versions less than v5 (meteor-desktop only supports up to v4) #261

Open
LDubya opened this issue Jan 15, 2020 · 33 comments

Comments

@LDubya
Copy link

LDubya commented Jan 15, 2020

Submitting an app with Electron v4 results in a rejection citing the use of private APIs, discussed here (electron/electron#20027). It was patched in Electron v5 and v6, but not in any version of v4. If meteor-desktop can't support electrion v5, v6, or a fork of v7 that has been patched to fix this issue, then meteor-desktop can't be used to submit apps to the Mac App Store anymore.

Guideline 2.5.1 - Performance - Software Requirements

Your app includes a version of an SDK from Electron that violates the App Store Review Guidelines. The version of the Electron SDK you are using in your app attempts to hide the use of private APIs. This is a violation Section 2.5.1 of the App Store Review Guidelines.

Guideline 2.5.1: Apps may only use public APIs.

Next Steps

To resolve this issue, please either remove the Electron SDK entirely from your app, or revise your app to utilize a corrected version of the Electron SDK.

I'm also citing this issue (#238), which is similar but supporting Electron v5 (^5.0.13) would also address this.

@LDubya LDubya changed the title The Mac App store now rejects all Electron v4 builds. The Mac App store now rejects all Electron versions less than v5 (meteor-desktop only supports up to v4) Jan 15, 2020
@darqs
Copy link
Collaborator

darqs commented Jan 15, 2020

Hi @LDubya,
you have to make local fork (put all project files to your project) for now from master (it support Electron 5 & 6) or from darqs_2.2.0 (it should working with Electron 7 also). After it you need build it locally (npm install & npm build inside meteor-desktop).

If you need builder and watcher, you can use config below to change Meteor plugins directory:
cross-env METEOR_PACKAGE_DIRS=../path/to/meteor-desktop/plugins/ ...

@LDubya
Copy link
Author

LDubya commented Jan 15, 2020

Hi @darqs, I'm getting an error with a fresh install of Meteor's "simple todos" app. Specifically, either it doesn’t install (first example), or I can get it to install but it will crash upon startup after packaging as a .app and signing.

First example

  1. created a fresh install of meteor simple todos:
meteor create simple-todos
cd simple-todos
  1. add cordova platform ios
    meteor add-platform ios

  2. fork meteor-desktop at LDubya/meteor-desktop

  3. install the forked master branch of meteor-desktop
    meteor npm install --save-dev LDubya/meteor-desktop

leads to the following error:

npm ERR! code ENOENT
npm ERR! syscall chmod
npm ERR! path /Path/To/simple-todos/node_modules/meteor-desktop/dist/bin/cli.js
npm ERR! errno -2
npm ERR! enoent ENOENT: no such file or directory, chmod '/Path/To/simple-todos/node_modules/meteor-desktop/dist/bin/cli.js'
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent

and the package is not added to package.json, and the build script is also not added to package.json.

I also tried...

downloading the master branch, renaming it to meteor-desktop, moving it to the node_modules folder of simple-todos, then cd simple-todos/node_modules/meteor-desktop, then running npm install from inside that meteor-desktop folder. That leads to the same error of:

npm ERR! path /Path/To/simple-todos/node_modules/meteor-desktop/dist/bin/cli.js
npm ERR! code ENOENT
npm ERR! errno -2
npm ERR! syscall chmod
npm ERR! enoent ENOENT: no such file or directory, chmod '/Path/To/simple-todos/node_modules/meteor-desktop/dist/bin/cli.js'
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent

Ignoring that error and running npm run build leads to

Successfully compiled 20 files with Babel.

but of course the package is not added to package.json, and the build script is also not added to package.json.

running npm install again does cause it to say

[meteor-desktop] successfully added a 'desktop' entry to your package.json scripts section.

and when viewing simple-todos/package.json, there is a desktop npm script entry, but 'meteor-desktop' is not listed as a devDependency, nor really anywhere inside of package.json. There also is no version of electron listed as a devDependency.

going back to the meteor app's root directory and running meteor npm install --save-dev [email protected] adds the electron package that I need and lists it in devDependencies in package.json.

but this causes /meteor-desktop to be removed from /node_modules, and I have to start all over again from the start. I do that again and end up back here.

But of course meteor-desktop isn't listed as a dev dependency. After manually hard-coding "meteor-desktop":"^2" into package.json as devDependencies and then running running meteor --mobile-server=127.0.0.1:3000, meteor runs normally. and then in a new tab npm run desktop -- init leads the init script to seemingly run successfully.

Changing the meteor run script to be

cross-env METEOR_PACKAGE_DIRS=node_modules/meteor-desktop/plugins meteor --mobile-server=127.0.0.1:3000.

And the desktop script to be cross-env METEOR_PACKAGE_DIRS=node_modules/meteor-desktop/plugins meteor-desktop, (ensuring that cross-env is installed globally) it seems to make it run with npm run desktop.

However, it doesn't sign and run. If you build a signed .app as a sandboxed app and try to run the .app (with the proper credentials and profiles from App Store Connect), the app just crashes on startup, giving the error:

Could not initialize app. Please contact your support. Error code: 1

@darqs any ideas why the app doesn't run after signing? These are the same credentials and profiles that worked with electron v4.

@LDubya
Copy link
Author

LDubya commented Jan 16, 2020

Update: I've tried it using the darqs_2.2.0 branch as well. Same outcome -- the app will run, but if you sign the app with a sandboxed entitlement (com.apple.security.app-sandbox = YES), it will crash on startup with the error Could not initialize app. Please contact your support. Error code: 1. Switching that app-sandbox entitlement to NO will enable the .app to run. However, the Mac App store requires that entitlement be set to YES since they only accept sandboxed apps.

This is with a vanilla install of Meteor's simple todos using Electron v5.0.13, one of the two official versions of Electron that have been updated to not use private APIs.

Opening up the Mac's console and looking at the crash log, it says

...
Crashed Thread:        0  Dispatch queue: com.apple.main-thread

Exception Type:        EXC_BAD_INSTRUCTION (SIGILL)
Exception Codes:       0x0000000000000001, 0x0000000000000000
Exception Note:        EXC_CORPSE_NOTIFY

Termination Signal:    Illegal instruction: 4
Termination Reason:    Namespace SIGNAL, Code 0x4
Terminating Process:   exc handler [0]

Application Specific Information:
dyld: launch, running initializers
/usr/lib/libSystem.B.dylib
Sandbox registration failed: Process is not in an inherited sandbox.
...

So it looks like this may be due to a binary that wasn't signed? What do you think?

In the .desktop/settings.json, I am using the following for the mac build settings:

...
"type" : "distribution",
"entitlements" : ".desktop/entitlements/entitlements.mas.plist",
"entitlementsInherit" : ".desktop/entitlements/entitlements.mas.inherit.plist",
...

So it should be including those entitlements.

entitlements.mas.plist:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
	<key>com.apple.security.app-sandbox</key>
	<true/>
</dict>
</plist>

entitlements.mas.inherit.plist:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
  <dict>
    <key>com.apple.security.app-sandbox</key>
    <true/>
    <key>com.apple.security.inherit</key>
    <true/>
  </dict>
</plist>

@LDubya
Copy link
Author

LDubya commented Jan 16, 2020

Same app-sandbox issue also exists with Electron 6.1.7.

@darqs
Copy link
Collaborator

darqs commented Jan 16, 2020

I think Could not initialize app... is related to starting local server, I will check it in sandbox mode.

@LDubya
Copy link
Author

LDubya commented Jan 16, 2020

Is there a way to disable the meteor app's attempt to start a local server? Our meteor app doesn't need to connect to a remote server, it's entirely client-side. No remote connection, using Ground DB as the local database. So including an entitlement to enable a server will lead to an App Store rejection. If we could disable meteor even attempting to start a local server, I think it may run sandboxed.

Not sure if this is on meteor (maybe remove/modify a package?) or on Electron (maybe there’s a flag that can be set?)

@LDubya
Copy link
Author

LDubya commented Jan 16, 2020

Update: stripped down Meteor to bare minimum packages, removing packages that may attempt to make a remote connection. Stripped-down version of Meteor does not have an effect. Issue still remains. Packages used:

$ cross-env METEOR_PACKAGE_DIRS=node_modules/meteor-desktop/plugins meteor list :

blaze-html-templates          1.1.2  Compile HTML templates into reactive UI with Meteor Blaze
ecmascript                    0.14.0* Compiler plugin that supports ES2015+ in all .js files
es5-shim                      4.8.0  Shims and polyfills to improve ECMAScript 5 support
jquery                        3.0.0  Manipulate the DOM using CSS selectors
meteor                        1.9.3  Core Meteor environment
omega:meteor-desktop-bundler  2.1.0+ Bundles .desktop dir into desktop.asar.
omega:meteor-desktop-watcher  2.1.0+ Watches .desktop dir and triggers rebuilds on file change.
reactive-var                  1.0.11  Reactive variable
shell-server                  0.4.0  Server-side component of the `meteor shell` command.
standard-minifier-css         1.6.0  Standard css minifier used with Meteor apps by default.
standard-minifier-js          2.6.0  Standard javascript minifiers used with Meteor apps by default.
tracker                       1.2.0  Dependency tracker to allow reactive callbacks
typescript                    3.7.2* Compiler plugin that compiles TypeScript and ECMAScript in .ts and .tsx files
underscore                    1.0.10  Collection of small helpers: _.map, _.each, ...
webapp                        1.8.2  Serves a Meteor app over HTTP

List of Meteor packages removed (while still enabling the app to run):

allow-deny            removed from your project
autopublish           removed from your project
autoupdate            removed from your project
binary-heap           removed from your project
callback-hook         removed from your project
ddp                   removed from your project
ddp-client            removed from your project
ddp-common            removed from your project
ddp-server            removed from your project
geojson-utils         removed from your project
hot-code-push         removed from your project
insecure              removed from your project
launch-screen         removed from your project
livedata              removed from your project
meteor-base           removed from your project
mobile-experience     removed from your project
mobile-status-bar     removed from your project
mongo                 removed from your project
mongo-decimal         removed from your project
mongo-dev-server      removed from your project
npm-mongo             removed from your project
reload                removed from your project
retry                 removed from your project
socket-stream-client  removed from your project

So I'm not sure if removing Meteor packages that may attempt to make remote connections is the way to go.

There's probably an Electron setting somewhere..

@darqs
Copy link
Collaborator

darqs commented Jan 16, 2020

I think local server is required, because it provides client files.

@LDubya
Copy link
Author

LDubya commented Jan 17, 2020

K I'm giving it a shot submitting with the 'server' and 'client' entitlements. Hoping that the app store reviewer understands that there are no server connections besides the self-consuming local server that the app spins up.

@msavin
Copy link

msavin commented Jan 17, 2020

I'm stuck in the same boat, and getting the same crash. It's been over a year, and I might go crazy soon.

FWIW, there is a fork of meteor-desktop which has a number of bugs fixed:
https://github.com/sharekey/meteor-desktop

I downgraded it to Electron 5.0.13, which should be patched for the private APIs. The v6 release runs three new GPU helper instances, so I avoided it because there appear to be other code signing bugs there. However, even with v5 even getting the DMG to run seems to be a hit or miss, even with code signing disabled.

--

FWIW, I had found a few patches that have helped:

@msavin
Copy link

msavin commented Jan 17, 2020

I have noticed that the application makes a request for a file using a relative path, which is outside of the application bundle. I wonder if that's where the sandbox problem is kicking in. Probably, this is a bug with meteor-desktop, and I notice @Strangerxxx had fixed similar bugs in his fork.

Sandbox: MyApp(84797) deny(1) file-read-data /Users/max/Documents/GitHub/myapp-app/package.json
Violation:       deny(1) file-read-data /Users/max/Documents/GitHub/myapp-app/package.json 
Process:         MyApp [84797]
Path:            /Users/max/Documents/GitHub/myapp-app/.desktop-installer/mac/MyApp.app/Contents/MacOS/MyApp
Load Address:    0x10c7fe000
Identifier:      ooo.company.app
Version:         8 (1.0.0)
Code Type:       x86_64 (Native)
Parent Process:  launchd [1]
Responsible:     /Users/max/Documents/GitHub/myapp-app/.desktop-installer/mac/MyApp.app/Contents/MacOS/MyApp
User ID:         501

Also, it's also getting a lot of denial for files that are with-in app 🤔

Sandbox: App(84797) deny(1) file-write-create /Users/max/Documents/GitHub/my-app/.desktop-installer/mac/App.app/Contents/Resources/app/.reify-cache/5b2f15d8f3cee98562d05fb435a01e6b003053c3.js

@msavin
Copy link

msavin commented Jan 20, 2020

@LDubya any luck with the client and server entitlements?

@LDubya
Copy link
Author

LDubya commented Jan 20, 2020

@msavin I was able to get the app to run with the entitlements, but am still in App Store Review limbo. They questioned the server entitlement. I wrote a response, but I also removed the client entitlement since the app still runs without it. 4 days ago they said to add the client entitlement metadata in App Store Connect but do not submit a new build, just leave a comment. I do that and then a whole 3 days later they come back and say I need to submit a new build (yep it took them 3 days to write one a sentence response that directly contradicts what they wrote previously). This is ridiculous. I still don’t know whether the server entitlement will be approved — the app doesn’t make any remote connections.

@LDubya
Copy link
Author

LDubya commented Jan 20, 2020

@msavin well. this is beyond frustrating. While signing, the package adds the "com.apple.security.application-groups" entitlement, even though it's not listed anywhere in our entitlements files. Because of this, the app is getting rejected (and we can't come to any conclusion about the client/server entitlements yet). Since that entitlement is not included in our entitlement plist files, we're not sure where it's being set, and so we don't know how to prevent the packager from including that entitlement. Any ideas?

@msavin
Copy link

msavin commented Jan 20, 2020 via email

@LDubya
Copy link
Author

LDubya commented Jan 20, 2020

@msavin that is how it's set. Specifically, it's TEAM_ID.appID, exactly how this package sets it when you tell it to build for mas. We're not using a third-party app to sign it. The problem is, it looks like Apple wants it gone. And we don't know how to prevent it from being included. It's being included as an entitlement even though we don't set it in our entitlement plist files.

Also, Apple's instructions are confusing, because they say we should be able to edit this metadata inside of App Store Connect and not submit a new build, but there is nowhere to remove entitlements that we can find using the interface.

Guideline 2.4.5(i) - Performance


Your app incorrectly implements sandboxing, or it contains one or more entitlements with invalid values. Please review the included entitlements and sandboxing documentation and resolve this issues before resubmitting a new binary.

"com.apple.security.application-groups"

Next Steps

For information on common app sandboxing issues, please see Technical Q&A QA1773 Common app sandboxing issues.

See App Sandboxing for links to essential video and documentation to learn how to sandbox your application.

Should you need code-level assistance implementing sandboxing, contact Apple Developer Technical Support.

@msavin
Copy link

msavin commented Jan 20, 2020 via email

@msavin
Copy link

msavin commented Jan 20, 2020 via email

@LDubya
Copy link
Author

LDubya commented Jan 20, 2020

Nope, it's not in any of our settings file. A grep returns nothing of the sort. We only set the sandboxed keys:

  • com.apple.security.network.server
  • com.apple.security.network.client
  • com.apple.security.app-sandbox

But when the app is built, the main app includes the following keys (additional ones are in bold)

  • com.apple.application-identifier
  • com.apple.security.network.server
  • com.apple.developer.team-identifier
  • com.apple.security.application-groups
  • com.apple.security.network.client
  • com.apple.security.app-sandbox

So it adds entitlements that we don't tell it to.

Specifically the following file will force-add the application-group entitlement.

/node_modules/app-builder-lib/electron-osx-sign/util-entitlements.js

the specific lines of code are:

// Init entitlements app group key to array if not exists
  if (!entitlements['com.apple.security.application-groups']) {
    entitlements['com.apple.security.application-groups'] = []
  }
  // Insert app group if not exists
  if (Array.isArray(entitlements['com.apple.security.application-groups']) && entitlements['com.apple.security.application-groups'].indexOf(appIdentifier) === -1) {
    debuglog('`com.apple.security.application-groups` not found in entitlements file, new inserted: ' + appIdentifier)
    entitlements['com.apple.security.application-groups'].push(appIdentifier)
  } else {
    debuglog('`com.apple.security.application-groups` found in entitlements file: ' + appIdentifier)
  }

This is also not documented anywhere that I could find, besides a github issue chat where the conversation was about unanimously deciding to add this functionality. Which makes me wonder if it's actually supposed to be there and my Apple reviewer needs an explanation, not for me to remove it. And if that's the case then this should be documented somewhere so that anyone submitting for MAS will know to include that explanation.

@LDubya
Copy link
Author

LDubya commented Jan 20, 2020

Yeah this is ridiculous. Preventing the entitlement from being included (by removing that block of code) prevents the app from running on startup. Electron seems to need it in order to run sandboxed.

@LDubya
Copy link
Author

LDubya commented Jan 22, 2020

K,

Approved with the following entitlements on Electron 5.0.13 uploaded as a .pkg (the .app should properly run locally even after code signing for mas).

Entitlements

  • App.app/Contents/Frameworks/Electron Framework.framework/Versions/A/Electron Framework
    • com.apple.security.inherit: true
    • com.apple.security.app-sandbox: true
  • App.app/Contents/MacOS/App
    • com.apple.application-identifier: TeamID.com.company.app
    • com.apple.security.network.server: true
    • com.apple.developer.team-identifier: TeamID
    • com.apple.security.application-groups: ( "TeamID.com.company.app" )
    • com.apple.security.network.client: true
    • com.apple.security.app-sandbox: true
  • App.app/Contents/Frameworks/Electron Framework.framework/Versions/A/Libraries/libffmpeg.dylib
    • com.apple.security.inherit: true
    • com.apple.security.app-sandbox: true
  • App.app/Contents/Library/LoginItems/App Login Helper.app/Contents/MacOS/App Login Helper
    • com.apple.security.inherit: true
    • com.apple.security.app-sandbox: true
  • App.app/Contents/Frameworks/App Helper.app/Contents/MacOS/App Helper
    • com.apple.security.inherit: true
    • com.apple.security.app-sandbox: true

If you're not making remote connections you need to explain the requirement for the server and client entitlements due to the way electron SDK sets up a local server for self-consumption while the app is running.

You need to explain the requirement for the application-groups entitlement due to Electron SDK’s need for using the Mach IPC, which is not normally available to a sandboxed app but is made available via the application-groups entitlement.

Don’t explain those things and lose weeks going back and forth during review and being told you’re incorrectly implementing sandboxing or using more entitlements than you need.

@darqs maybe this should be documented somewhere?

@msavin
Copy link

msavin commented Feb 14, 2020

@LDubya are you setting all these in entitlements.mas.plist? Can you please share what that file looks like for you?

@msavin
Copy link

msavin commented Feb 14, 2020

@darqs now that 2.2.5 is out, do you still recommend using your branch?

@darqs
Copy link
Collaborator

darqs commented Feb 14, 2020

@msavin Hi, version 2.2.5 should work with Electron >= 7.1.10 || >= 8.0.0. My branch fix some issue for Electron 7.1.8, but now it is not required.

@LDubya
Copy link
Author

LDubya commented Feb 17, 2020

Hey @msavin, that's the final output. You can scan a .app to find its lists of entitlements. Within the meteor-desktop settings, some are set in entitlements.mas.plist, helpers plist, etc. Others are set automatically by the builders. I can send you sample plists if needed.

Would love to get some help from someone with this other issue though: #265

@msavin
Copy link

msavin commented Feb 23, 2020

@LDubya if you can send the sample plists, along with any code changes you had to make to meteor-desktop/etc, that would be great. I have gone through ten builds already and I think the App Store people are starting to get annoyed.

@LDubya
Copy link
Author

LDubya commented Feb 23, 2020

@msavin

barebones:

AppRoot/.desktop/entitlements/entitlements.mas.plist

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
  <dict>
    <key>com.apple.security.app-sandbox</key>
    <true/>
    <key>com.apple.security.network.client</key>
    <true/>
    <key>com.apple.security.network.server</key>
    <true/>
  </dict>
</plist>

AppRoot/.desktop/entitlements/entitlements.mas.inherit.plist

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
  <dict>
    <key>com.apple.security.app-sandbox</key>
    <true/>
    <key>com.apple.security.inherit</key>
    <true/>
  </dict>
</plist>

And in your AppRoot/.desktop/settings.json

{
    ... (name, version, etc)
    "builderOptions": {
        ...
        "appId" : "Your App Bundle ID",
        "mac": {
            ... (icon, etc)
            "type" : "distribution",
            "target" : "mas",
            "entitlements" : ".desktop/entitlements/entitlements.mas.plist",
            "entitlementsInherit" : ".desktop/entitlements/entitlements.mas.inherit.plist",
            "hardenedRuntime" : false,
            "identity" : "Your Developer Identity"
        },
    }
}

Make sure the script is in your AppRoot/package.json

{
  "scripts": {
    ...
    "desktop": "meteor-desktop"
  }
},

Have all the necessary app signing certificates installed on your machine, XCode, etc.

Run the following to build and sign and package

npm run desktop -- build-installer --mac;

Should output .app and .pkg in AppRoot/.desktop-installer/mas
.pkg can be transported to App Store

@msavin
Copy link

msavin commented Feb 26, 2020

@LDubya thank you, that was very helpful. Are you passing in anything for extendInfo?

Here's what my configuration looks like, going to try again this week. Please let me know if you spot any issues.

settings.json

"mac": {
          "type": "distribution",
          "icon": "logo.icns",
          "extendInfo": {
             "ElectronTeamID": "XXX",
             "com.apple.developer.team-identifier": "XXX",
             "com.apple.application-identifier": "XXX.com.corp.app",
             "com.apple.security.application-groups": "XXX.com.corp.app"
           },
          "entitlements": "entitlements.mas.plist",
          "entitlementsInherit": "entitlements.mas.inherit.plist",
          "provisioningProfile": "embedded.provisionprofile",
          "target": ["mas"],
          "bundleVersion": "10",
          "hardenedRuntime": false
      }

entitlements.mas.plist

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
	<dict>
		<key>com.apple.security.app-sandbox</key>
		<true/>
		<key>com.apple.security.network.server</key>
		<true/>
		<key>com.apple.security.network.client</key>
		<true/>
	</dict>
</plist>

entitlements.mas.inherit.plist

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
	<dict>
		<key>com.apple.security.app-sandbox</key>
		<true/>
		<key>com.apple.security.inherit</key>
		<true/>
	</dict>
</plist>

@LDubya
Copy link
Author

LDubya commented Feb 26, 2020

@LDubya thank you, that was very helpful. Are you passing in anything for extendInfo?

Nope. Full mac for us is:

"mac": {
            "icon": ".desktop/assets/MyIcon.icns",
            "type" : "distribution",
            "darkModeSupport": true,
            "target" : "mas",
            "entitlements" : ".desktop/entitlements/entitlements.mas.plist",
            "entitlementsInherit" : ".desktop/entitlements/entitlements.mas.inherit.plist",
            "hardenedRuntime" : false,
            "identity" : "REDACTED"
        }

Your provisioning profiles and other credentials should be installed on your device's keychain, registered on App Store Connect, and will be pulled automatically during signing.

Try the barebones config and see what happens during packaging and signing.

This is on Electron v5 btw. We're migrating to V6 now, though, and looks like we're running into some build upload issues on the App Store, with the build no longer passing their automated integrity checks. ITMS-90287: Invalid Code Signing Entitlements (appears to have been solved by including the provisioning profile as a build setting) and ITMS-90277: Invalid Bundle Identifier -- working on this one -- maybe solvable by the link you included earlier (electron-userland/electron-builder#4151)

@msavin
Copy link

msavin commented Feb 27, 2020

@LDubya awesome, thanks.

By the way, it looks like Electron 8 has been patched for MAS

@msavin
Copy link

msavin commented Apr 6, 2020

Can confirm 8.0.2 can be published to Mac App Store with above instructions and the workaround posted here.

@linegel
Copy link
Contributor

linegel commented Jun 24, 2020

@msavin @LDubya we made fork here sharekey/meteor-desktop or npm using our repo you will have no problems with the latest version of electron and no need for any workaround

@LDubya
Copy link
Author

LDubya commented Jul 14, 2023

@msavin and @linegel , we've been making updates to the desktop app for the first time in a couple years. It looks like Apple is making it hard to test MAS builds locally, so when we build for MAS, the app doesn't load. This makes it hard to test the production build, which is under tighter restrictions. How are you guys able to test your MAS builds before submitting to Apple? We tried the @sharekey/meteor-desktop build, and can't seem to find a setting to allow for testing production MAS builds.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants