I use NSUserAppleScriptTask in my app to call Apple Script method to send Apple Events to Finder and System Events.
The script has been deployed in the folder ~/Library/Application Scripts/{app bundle id}/
I have configured the com.apple.security.automation.apple-events in the .entitlements file, but how to configure com.apple.security.scripting-targets to meet the AppStore review requirements
The existing official documentation is too incomplete to be of much use. If anyone has had similar experience, could you please share?
I think you’re confused here. NSUserAppleScriptTask
runs the script out of process, and thus the entitlements of your app don’t affect the behaviour of the script. That’s the whole reason why NSUserScriptTask
exists, as I explain in Implementing Script Attachment in a Sandboxed App.
Given that, there’s no reason to sign your app with either com.apple.security.automation.apple-events
or com.apple.security.scripting-targets
.
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"