Closed magua-io closed 4 years ago
Since you can encode the Data
and [Data]
types, you could make this a step inside your encoding and decoding whereby when you go to save the data, you encrypt it, then store it onto the disk.
Here's an article on how to interact with the built in CommonCrypto
Working with CommonCrypto for AES256 Encryption
I would use iOS's keychain to store any encryption and decryption keys, otherwise storing the key on disk would pose the same security issues as not encrypting.
When storing data in .documents, the data itself is not encrypted, and if users try to backup the app by iTunes without the encryption option, the stored data could be viewed directly as the plain text. Is it possible to encrypt the data that stores into the file system by using Disk? Any suggestions? Thanks!