electron-builder: InvalidConfigurationError: Cannot find valid "3rd Party Mac Developer Installer" identity to sign MAS installer
- Electron-Builder Version: 22.14.11
- Node Version: v17.2.0
- Electron Version: 14.2.3
- Electron Type (current, beta, nightly):
- Target: mac/mas
It complains like that when you try to build a final mas pkg even if I have a valid identity in the keychain. It seems to have detected the certificate according to a debug message.
7) F561~~C9 "3rd Party Mac Developer Installer: ~~ Inc. (~~~)"
7 valid identities found
just fyi, export CSC_LINK didn’t help.
About this issue
- Original URL
- State: open
- Created 3 years ago
- Reactions: 1
- Comments: 15 (4 by maintainers)
I have been tormented by this issue for hours. It all started when one or both of these things happened:
a) My app’s “Developer ID Installer” expired (“easily” fixed) b) I added “Apple Distribution” for a second organization, effectively making two available, and electron-builder was silently choosing the first
To troubleshoot I used the trusty:
security find-identity -vI’ve found a few ways to mitigate this issue:
I need to get a “F@%& CODE SIGNING” t-shirt made. This stuff is brutal.
According to this snippet code which generated error debug message, I found a way to solve this issue. We just need to select both
Apple Distributionand3rd Party Mac Developer Installercertificates in the keychain and export them in a single p12 file, and then add to our project, then everything works fine.I AGREE with you. This “F@%& CODE SIGNING” requirement is silly trick of Apple to stop you making profit. They are arrogant to provide few instructions and rename the FXXKING certificates randomly.
As a stopgap measure, I commented out that portion of code in the
node_modules/app-builder-lib/out/macPackager.jsand just didproductbuildmanually