I\'m looking to encrypt user data in an app, and the NSFileProtection mechanism looks perfect for this.
This SO Question / Answer thread pointed me at the WWDC 2011
I have tried data protection using entitlements and it works fine. The trick is to make sure your entitlements file entry in your Xcode project is the same as that of your provisioning profile.
Specifically, the following 2 settings in entitlements file and provisioning profile should be same:- "com.apple.developer.default-data-protection" - I have set this as NSFileProtectionComplete. "application-identifier" - I am not using wildcards in identifier though I think it should work as well.