I'm working on an audio plugin, and when I set the target to VST3 instead of Standalone Plugin and check the "Debug Executable" box, I get this error:
Message from debugger: attach failed (Not allowed to attach to process. Look in the console messages (Console.app), near the debugserver entries, when the attach failed. The subsystem that denied the attach permission will likely have logged an informative message about why it was denied.)
I found this post, which seems to be about this same issue, and I followed the recommended solution:
I made sure CODE_SIGN_INJECT_BASE_ENTITLEMENTS is true and DEPLOYMENT_POSTPROCESSING is false. I also checked the entitlements on the .app using codesign -d --entitlements
, and it returned:
[Key] com.apple.security.get-task-allow
[Value]
[Bool] true
This seems like it has the proper entitlements, but it is still breaking with the above error message when I clean and build. Any ideas?
I'm using Ableton Live as the executable.
Thanks for that info.
This seems to be production software distributed directly by another third-party developer. That makes it tricky to debug your plug-in when it’s loaded by this app.
When you directly distributes an app, you have to enabled the hardened runtime [1]. By default, the hardened runtime prevents folks from attaching with the debugger. You can opt out of that [2], but most app developers don’t.
So, unless the app developer has a special version of their app that enables debugging for the benefit of plug-in developers like yourself, there’s no good way to resolve this.
Notably, this error doesn't occur when I am using something local to my project as the executable, like a standalone plugin or the built-in JUCE audio plugin host.
Right. If you built the app locally, it’s likely that Xcode added the get-task-allow entitlement automatically.
You might be able to get this working by disabling System Integrity Protection (SIP).
IMPORTANT Don’t disable SIP on a machine you care about. If you go down this path, set up a ‘victim’ machine for this specific task. I usually do this sort of thing in a VM.
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"
[1] It’s a requirement of the notary service.
[2] See this discussion.