Re: App Sandbox Container or Data Directory
Re: App Sandbox Container or Data Directory
- Subject: Re: App Sandbox Container or Data Directory
- From: Richard Somers <email@hidden>
- Date: Tue, 23 Oct 2012 16:06:07 -0600
On Oct 23, 2012, at 2:43 PM, Kyle Sluder <email@hidden> wrote:
> If by "unapproved" you mean "my app's sandbox hasn't been extended to
> include this path" then you are incorrect. The user can choose the
> destination, and the NSURL you get back from the open panel will carry
> the rights to access that location.
>
> If by "unapproved" you mean "the user my app is running as doesn't have
> write permission to this location", then yes that is expected behavior.
I sandboxed my app in Xcode. In the app target entitlement area there are access control options for Music, Movies, Pictures, and Downloads folders. Access to these folders remained the default "No Access". I launched the app and and saved a new document. In the save panel the Music folder was showing as a Recent Place. I selected this as the save location and saving was a success. As a developer, based on the entitlement settings, I was expecting failure.
Saving a new document to the users home directory (choose the home directory in the save panel) resulted in failure. "The document could not be saved. You don't have permission." As a developer this is what I expected. From a users point of view I was surprised that the save panel let the user choose a location where a save was not allowed and subsequently would result in failure.
--Richard Somers
_______________________________________________
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