Is container migration manifest required to access 3rd party file in ~/Library/Preferences from sandboxed Cocoa app in OS X 10.8 SDK?
Is container migration manifest required to access 3rd party file in ~/Library/Preferences from sandboxed Cocoa app in OS X 10.8 SDK?
- Subject: Is container migration manifest required to access 3rd party file in ~/Library/Preferences from sandboxed Cocoa app in OS X 10.8 SDK?
- From: Public <email@hidden>
- Date: Thu, 06 Jun 2013 23:03:34 +0800
I'm building a Cocoa app (using OS X 10.8 SDK) to access a file (that was not created or owned by my app) in ~/Library/Preferences/.
I'm able to access the ~/Library/Preferences from a non-sandboxed app, however when I run my NSTask from my sandboxed app, the path returned is
/Users/username/Library/Containers/com.companyname.Download-Log/Data/Library/Preferences/com.apple.LaunchServices.QuarantineEventsV2: No such file or directory
At this point I'm guessing the above error message is a result of not finding the preference file I want in my app's sandbox rather than because NSTask (running from within my app) has no access to that preference file. Reading page 36 of the App Sandbox Design Guide suggests that "Preferences for other sandboxed apps are inaccessible".
I've created an entitlement file. So my question is is it possible to use a container migration manifest to copy the file (that was not created or owned by my app) from ~/Library/Preferences to my app's sandbox. I only need read access and need not modify or write that preference file back out to ~/Library/Preferences.
Thanks for any pointers and suggestions.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden