I'm developing a macOS app where users load files from all kinds of internal and external volumes for editing. Whenever the user loads a folder, I'm keeping a secure bookmark internally and use this is combination with
startAccessingSecurityScopedResource() and stopAccessingSecurityScopedResource()
This works fine most of the time. However, there is one situation where it doesn't work as expected and this is when the following conditions are met:
The sandboxd metadata shows "storage-class":"TemporaryItems" which might be related.
Any help is much appreciated!
startAccessingSecurityScopedResource() and stopAccessingSecurityScopedResource()
This works fine most of the time. However, there is one situation where it doesn't work as expected and this is when the following conditions are met:
The file in question is on an external FAT32 thumb drive
The editing process requires a temporary file
Code Block NSUnderlyingError=0x600003cf1e00 {Error Domain=NSPOSIXErrorDomain Code=1 "Operation not permitted"} System Policy: deny(1) file-read-data /Volumes/...
The sandboxd metadata shows "storage-class":"TemporaryItems" which might be related.
Any help is much appreciated!