Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Senor Cuete

macrumors 6502
Original poster
Nov 9, 2011
431
32
Yesterday the code
Code:
OSStatus status = CMSDecoderCreate(&decoder);
status = CMSDecoderUpdateMessage(decoder, receiptData.bytes, receiptData.length);
CMSSignerStatus signerStatus;
status = CMSDecoderCopySignerStatus(decoder, 0, policyRef, TRUE, &signerStatus, &trustRef, &certVerifyResult);
Stopped working. This is weird because this last line has been in the project for years and worked in the app with the same MAS_Receipt from the App Store for a long time. All of the checks work except this last one. It returns a signer status of KCMSSignerInvalid Cert. Why would this stop working all of a sudden when it worked for years?
 
Setting the fourth parameter to NO fixes the error but I think I am skipping a step in validation this way.
 
Now things have gotten weird, it's working again with the same _MASReceipt/receipt with the boolean variable YES or NO. ???
 
This was strange. The function CMSDecoderCopySignerStatus stopped working in the exported application and in XCode for a day and then fixed itself. You have to think that this is a MacOS bug.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.