1
My company made a developer certificate on the Apple Developer platform. At this point I need to link a key file to my iOS build in Phonegap.
I'm trying to generate this key file where I need the .p12
file and the provisioning profile
file. I've got myself the provisioning profile
file, but I can't seem to generate the .p12
file.
I'm using Openssl to generate my files and I tried this command to generate the last file:
openssl pkcs12 -export -inkey ios.key -in ios_development.pem -out ios_development.p12
Enter pass phrase for ios.key: *********
No certificate matches private key
What exactly am I doing wrong here? Can I find the private key on the developer.apple.com website?
UPDATE: here are the steps I'm performing to get to this problem:
- Generate private key:
openssl genrsa -des3 -out ios.key 2048
and enter a passwordpass123
- Generate CSR file:
openssl req -new -key ios.key -out ios.csr -subj "/emailAddress=info@company.com, CN=company, C=BE"
and enter the password from the private keypass123
- Go to your Apple Developer iOS Provisioning Portal and download the development certificate
.cer
file - Convert the certificate to a PEM file:
openssl x509 -in ios_development.cer -inform DER -out ios_development.pem -outform PEM
- Generate the P12 file using the private key (ios.key) and the iOS development certificate (ios_development.pem):
openssl pkcs12 -export -inkey ios.key -in ios_development.pem -out ios_development.p12
and enter the password from the private keypass123
- Error message:
No certificate matches private key