Phonegap Build Error - Certificate doesn't match profile: The default keychain doesn't have an identity matching - phonegap-build

I've tried creating the certificate and provisioning profile over and over again, but I cannot get it to build on iOS through Phonegap Build. I get this error every time:
Error - Certificate doesn't match profile: The default keychain doesn't have an identity matching
I've done this many times in the past, but for whatever reason I can't get it to work now.
The provisioning profile contains the certificate and I can generate the .p12 file just fine.
My mac will only allow me to upgrade OS up to 10.13.6 and xcode up to 10.1. Is there any issue with keychain using older versions of these?
How do I solve this issue?

I figured it out.
After updating OS and xcode I scrubbed keychain, created new certificate signing requests, revoked all the old certificates in apple developer and then created a new certificate and profile.

Related

iOS device won't allow to open the app with distribution certificate not expired nor revoked

Our enterprise app was distributed through Fabric Crashlytics Beta but after a year the app won't open from the device. When you tap the icon it will just close. It can't be download also.
The distribution certificate was not expired nor revoked.
And releasing a build with a new generated certificate fixed the issue but the cause is still unknown.
The certificate is valid for 3 years, but the provisioning profile you used to build the app with is valid for 1 year at most. You can push a new provisioning profile to the devices without having to re-build the app, but without a non-expired provisioning profile that is valid for the app's bundle ID and the certificate used to sign it, the app will refuse to run.
Long story short, if you are doing enterprise distributions, you will need to push out a provisioning profile (either through mobile device management [MDM] or by building the app again with a new provisioning profile [the profile is bundled with the ipa when you package the app]) at least once a year. Then once every 3 years, you will need to get a new certificate, generate a new profile for that certificate, and build and deploy a new binary that has been signed with the new cert.

Xamarin.iOS - Using IPhoneSimulator's Keychain with a free iOS Development certificate

I have troubles with saving an account credentials inside an IPhoneSimulator's Keychain. I cannot use AccountSaver.Create().Save(credentials, "app") without Entitlements.plist. However when I add it to my project, compilation error shows up:
Could not find any available provisioning profiles for iOS.
I've added iOS Development certifcate to my account on Mac and tried to create a free provisioning profile but failed due to a lack of IPhone device.
Suprisingly, when I tried to build dummy project with added Keychain to Entitlements inside Xcode on my Mac and run it on a simulator no compilation errors occured.
My questions are: Do I have to make Apple Developer Account to test my Xamarin.iOS app inside IPhoneSimulator or is it possible without it and I'm doing something wrong? If so, what should I do to be able to compile my app?
I use Visual Studio 2017 on Windows 8 connected to a Mac Agent (Mac Mini).
P.S.: Most posts states, that simulator doesn't need provisioning profile, but according to this thread:
Starting with Xamarin.iOS 8.10, if the Entitlements.plist file is set at all for the iPhoneSimulator build configuration, then codesigning is required and thus an iOS code signing certificate is required to be installed in your keychain. ~ Xamarin Forum
Some time has passed since I asked this question, but I think it deserves an answer not only in the comments.
As #wottle wrote it is required to be enrolled i Apple Developer Program in order to have access to Keychain.
I sugest also to use Xamarin.Essentials' SecureStore instead of AccountSaver.
We have a bunch of Apple Store applications that had their Apple Distribution profiles expired. The issue was gone once we regenerated the Apple Distribution Certificate and created a new Distribution Profile for the impacted Applications.

"Valid signing identity not found" Xcode 4.6

I bought a new Mac, and installed Xcode again etc.
But I have problems with certificates and provisioning profiles.
In Organizer, Xcode is giving the error under the status of all my provisioning profiles:
"Valid signing identity not found"
Is it because I bought a new Mac?
I searched on the web a lot, but I couldn't find a working solution.
1)
do you have an older Macintosh that you used to build your iOS / MacOS apps on?
If so, you need to migrate your certificates and provisioning profiles.
This tutorial shows you how to do that.
2)
If you never built iOS or Mac apps before, then you need to create new certificates and provisioning profiles.
This related question should point you the right direction.

Code signing on multiple computers

I use 2 machines for developing a Mac application. I just submitted my app to the app store from my desktop (generating and using the appropriate certificates from Apple for code signing).
I exported and installed the certificates on my laptop so that they show up in the keychain but, yet, I'm unable to build my app on my laptop because of the following error:
Check dependencies
[BEROR]Code Sign error: The identity '3rd Party Mac Developer Application' doesn't match any valid certificate/private key pair in the default keychain
Is there any way to use the same certificates for code signing on more than 1 machine?
Yes, I use multiple computers and the same certificates all the time.
You need to also make sure you have the private keys imported into your keychains.

Why can't I code sign this Mac app?

I started some days ago a small Mac app for Mac OS X Lion. I've never uploaded a Mac app before, so this is the very first time.
This is what I've already done:
Created App ID
Created Certificate
Installed Certificate
Created a Production Provisioning Profile
Changed the App ID to my generated one
Created a new Configuration based on "Release"
Changed its Code Signing to 3rd Party Mac Developer Application
Selected the "Production"-Configuration which I created for the Archive-Scheme
Archived the Application
Now I wanted to "Share" the Application. Xcode (4.1 btw) said to me, there were no valid signing identities. Does I need to add an Entitlement.plist like in iOS? Have I forgotten something?
Update:
I just figured out, that I have to sign my app twice. I've still selected "3rd Party Mac Developer Application" but I can't select the Installer cert while submitting my app.
Have you installed the WWDR intermediate certificate? I just had the exact same problems and my issue was that the intermediate certificate was not installed on my machine. Granted, nowhere does Apple explicitly say you need it installed, more like suggestions. But, you do need it. You can find it here, or by going to Developer Certificate Utility under the Mac Developer Center.
I got it to work. I deleted my App and created it new.
I didn't create a new Configuration, and I only changed the Code Signing Indentity of the Target to 3rd Party Mac Developer Application. After this, I archived the app and then I was able to select the installer cert.

Resources