xcode - 发送Apple Event的“Prompting policy for hardened runtime; invalid entitlement”错误

标签 xcode electron code-signing

我正在尝试将Apple Event发送到另一个进程,并收到一条错误消息,指示我没有适当的权利:

Prompting policy for hardened runtime; invalid entitlement for responsible={identifier=com.ishaangandhi.ishan, pid=1595, auid=501, euid=501, responsible_path=/path/to/my/Shell Notebook, binary_path=/path/to/my/Shell Notebook.app/Contents/MacOS/Shell Notebook}, accessing={identifier=com.barebones.bbedit-tool, pid=1613, auid=501, euid=501, binary_path=/Applications/BBEdit.app/Contents/Helpers/bbedit_tool}, requesting={identifier=com.apple.appleeventsd, pid=303, auid=55, euid=55, binary_path=/System/Library/CoreServices/appleeventsd},
我的Info.plist中具有以下值:
<dict>
    <key>NSAppleEventsUsageDescription</key>
    <string>Allow Shell Notebook to run Apple scripts.</string>  
    <key>NSAppleScriptEnabled</key>
    <string>YES</string>
</dict>
这是我的titles.plist中的 key :
    <key>com.apple.security.automation.apple-events</key>
    <string>YES</string>
我还需要发送什么其他Apple事件?当我尝试发送它们时,与其他应用程序不同,永远不会提示用户允许它们。
如果有所作为,这是一个 Electron 应用程序。

最佳答案

几个小时后解决了该问题:

    <key>com.apple.security.automation.apple-events</key>
    <string>YES</string>
将失败。
    <key>com.apple.security.automation.apple-events</key>
    <true/>
作品。

关于xcode - 发送Apple Event的“Prompting policy for hardened runtime; invalid entitlement”错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/65404011/

相关文章:

xcode - IMFResponse responseWithWLResponse 无法识别的选择器发送到类

objective-c - XCode:发送到实例的无法识别的选择器

amazon-s3 - 自动更新程序不适用于Amazon S3专用存储桶

objective-c - 门卫是否允许两个具有相同标识符和不同证书的应用程序

java - 如何检查 Java Web Start 应用程序是否会在证书过期后继续工作

objective-c - NSCFString objectAtIndex 无法识别的选择器发送到实例 0x5d52d70

ios - UI 测试 - 如何检查我是否在正确的 Controller 中?

node.js - Windows 路径上的 path.dirname 给出 `.`

node.js - 使用Visual Studio 2017开发和调试Electron Node js-调试器附加但应用程序窗口不正确

android - 在不发布应用的情况下添加 Google Play "security metadata"