How to use resources in CloudKit?

I am trying to use CloudKit with assets.

I created RecordType, which includes an asset in the iCloud developer toolbar.

Then I created a default entry in the shared database and uploaded the file to the entry asset.

I wrote this code to get a record.

CKContainer *defaultContainer =[CKContainer defaultContainer]; CKDatabase *publicDatabase = [defaultContainer publicCloudDatabase]; CKRecordID *wellKnownID = [[CKRecordID alloc] initWithRecordName:@"RECORDKEY"]; [publicDatabase fetchRecordWithID:wellKnownID completionHandler:^(CKRecord *fetchedParty, NSError *error) { NSLog(@"erorr : %@", error) }]; 

And I got this error message.

2014-06-28 21: 42: 50.148 AppName [10634: 1068121] erorr: <CKError 0xc81b4a0: "Internal error" (1/5001); "Record <CKRecordID: 0xc035b50; RECORDKEY: (_ defaultZone: __ defaultOwner __)> has elements that require encryption, but no security information was found in the record">

What is protection data? Do I have to encrypt data before downloading?

+8
ios assets icloud cloudkit
source share
1 answer

Did you download data using the web console? I also experienced it when I do this. So far, my solution has been to download resources using the device and then use them as usual.

+2
source share

All Articles