Verifying receipt with Xcode 12 + StoreKit configuration file

I'm trying to verify receipts with Xcode 12 and a StoreKit config file, but keep getting a 21002 error. According to the docs, I need to use a different cert. I generated the cert but it's not clear what to do with it?

Code Block
#if DEBUG
let certificate = “StoreKitTestCertificate”
#else
let certificate = “AppleIncRootCertificate”
#endif


That's great, but what uses certificate ?

Replies

Same question -- anyone figure this one out yet...
Same problem here, documentation isn't clear on this point.. can you suggest a solution?
Same issue... please help, validating the receipt on the client is a very time consuming option... https://developer.apple.com/forums/thread/662932
Those are certificates for testing your receipt signature validation.
What is a signature?
It provides by apple with your receipt and you can verify it either it is from apple or any bad action happen.
How to validate a receipt then?
several ways. server site validation. in mobile(local) validation or validation with the app store. Below are some documents for different validations.