Hello to everyone,
my iOS banking app has a WKWebView that shows a webpage from an external supplier.
For security reasons the file Cookies.binarycookies generated by this webpage should not be present in the backup of the app.
I've implemented this code but it doesn't work
if ([[NSFileManager defaultManager] fileExistsAtPath:filePath]) {
BOOL result = NO;
NSURL *url = [NSURL URLWithString:filePath];
result = [url setResourceValue:[NSNumber numberWithBool:YES] forKey:NSURLIsExcludedFromBackupKey error:&error];
}
The result value is YES after the execution but the file is still present in the backup.
I doubt that this file is protected and this fix won't work.
Have you any suggestion on how I can proceed?
Thank you,
Chiara