Assistance Required: Invalid CSR File Format While Uploading to APNs

Dear Apple Developer Support Team,

I hope this message finds you well.

I am currently utilizing the services at https://identity.apple.com for mobile device management and encountered an issue while attempting to upload a Certificate Signing Request (CSR) file to the portal. The system generated an error indicating that the file format was invalid.

Below are the steps I followed to generate the CSR:

I first created a private key on my server using the following command:

openssl genrsa -out private.key 2048

Next, I generated the CSR file with the following command:

openssl req -new -key private.key -out request.csr

Despite following these steps, I could not successfully upload the CSR file and obtain the APNs certificate. I would greatly appreciate your guidance on creating and uploading a valid CSR file to avoid this error.

Please let me know if there are any specific formatting requirements or additional steps I need to follow. Thank you in advance for your assistance and support.

Answered by DTS Engineer in 810926022

If, just for the sake of testing, you generate a CSR using Certificate Assistant on the Mac [1], do you still see this problem?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

[1] Access this via Keychain Access. If you’re using macOS 15, Keychain Access has been removed from the Utilities folder, but you can easily find it using Spotlight.

Accepted Answer

If, just for the sake of testing, you generate a CSR using Certificate Assistant on the Mac [1], do you still see this problem?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

[1] Access this via Keychain Access. If you’re using macOS 15, Keychain Access has been removed from the Utilities folder, but you can easily find it using Spotlight.

We followed Apple’s official guidance via Keychain Access to create a CSR and MDM Vendor certificate, but when extracting and uploading the private key and certificate in the required format, we again encountered the same error. We need assistance in resolving this issue and ensuring the CSR format meets APNS requirements.

I’m confused. What exactly are you doing with a private key here?

The site you mentioned requires just a CSR.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

It’s better if you reply as a reply; if you reply in the comments, I might not see it. See Quinn’s Top Ten DevForums Tips for this and other titbits.

Could you kindly guide us on creating a CSR that adheres to the necessary format and requirements for successful submission?

No, sorry, I can’t do that.

DevForums is primarily focused on code-level issues, and this is more of an admin thing. I work with CSRs because they’re using for code signing, which is why I waded into this in the first place. However, I’m not able to provide a detailed spec of what this site expects from its CSRs.

There are three different roles here:

  • Apple

  • MDM vendor

  • MDM vendor customer

Which are you?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Assistance Required: Invalid CSR File Format While Uploading to APNs
 
 
Q