I'm trying to generate a JWT token for Apple Connect but It's look like something is missing in the "Verify signature" field.
- From the API Apple Store Connect dashboard, I'm only able to download the "private key" name AuthKey_{kid}.p8.
- From https://jwt.io/, I select the "ALGORITHM" as "ES256" then two field appears in the "SIGNATURE" section:
a) Public key or certificate
b) Private key or certificate (AuthKey_{kid}.p8)
Issue :
- I do have the "Invalid Signature" message displaying ...
- I don't have any idea where to find the "Public key or cerficate"
I'm following these docs :
- https://developer.apple.com/documentation/appstoreconnectapi/generating_tokens_for_api_requests
- https://medium.com/xcblog/generating-jwt-tokens-for-app-store-connect-api-2b2693812a35
Do you have any idea how to fix find the "Public key"?
The .p8 file includes the private and public keys. You need to extract those using OpenSSL.
To get the private key:
To get the public key:
Using keys generated via these commands got the signature verified on jwt.io.