on Android, i can store files into a fairly-protected file by using Context.openfileoutput
. it'll save to internal disk that is specific to my app, which isn't accessible to other apps, and the only way to get this is via connecting debugger/rooting device. this isn't 100% hack-proof, but it's good enough.
Is this something that exists on iOS?
i read https://developer.apple.com/library/content/qa/qa1699/_index.html, but is this safe? like i'm guessing it looks something like
NSArray *paths = NSSearchPathForDirectoriesInDomains(NSLibraryDirectory, NSUserDomainMask, YES);
NSString *librariesDirectory = [paths objectAtIndex:0];
NSLog(@"%@", librariesDirectory);
NSString *filePath = [NSString stringWithFormat:@"%@/%@/%@", librariesDirectory,@"Private", @"internal_image.jpg"];
Would this file be something that
- other apps can not access
- does not backup to icloud
- is easily visible to the app but NOT the end user
?