Accessing a file in the sandboxed main app, which was selected in a Finder Sync Extension

Hi there,

I have a Finder Sync extension, which adds a simply entry to the context menu of the finder. When this option is clicked, the selected files (URL objects) are sent to the main app using a URL Scheme. When I attempt to handle them there (e.g. read/write, access information about the file) I get a permission error. This only happens when using files from anything but the Downloads/Music/Pictures/Movies (all the folders which I already have given access to)

I know that this denying of permission when the user hasn't selected it is intended by the sandbox and that I can access them in the extension because they're selected, but this access gets lost as soon as I send them to the main app.

I simply can't find a way to send these paths to the main app without losing the aforementioned access, is there any way to do this, or am I forced to request full disk access from the user?

Standard practice here is to pass a security-scoped bookmark between the processes.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Accessing a file in the sandboxed main app, which was selected in a Finder Sync Extension
 
 
Q