【发布时间】:2013-08-24 07:03:40
【问题描述】:
我正在使用 Magical Record 来保存我的数据。该数据需要加密,因此我尝试将其与 SQLCipher 库(http://sqlcipher.net/ios-tutorial/)结合使用。
我已经设置了 SQLCipher 并使用 Core Data 成功地对其进行了测试,使用此示例中的 EncryptedStore 文件https://github.com/project-imas/encrypted-core-data:
我所做的只是像这样更改 NSPersistentStoreCoordinator:
NSPersistentStoreCoordinator *coordinator = [EncryptedStore makeStore:[self managedObjectModel]:[SSKeychain passwordForService:myservice account:myaccount]];
所以我认为我需要更改在 MagicalRecord 中创建 NSPersistentStoreCoordinator 的方式,但我没有运气,因此将不胜感激。
【问题讨论】:
标签: iphone ios magicalrecord sqlcipher