Post

Replies

Boosts

Views

Activity

Reply to Fail to load system extension due to invalid code signature or missing entitlements
This part looks OK. Other things to check, just in case: the Network Extension has the Network Extension permission. the Network Extension app ID starts with the app ID of the embedding application. the Team Prefix is the same for both app IDs. the profiles for the Network Extension and the Application uses the same Developer ID Application certificate. In the case the certificate used to create the profile is not the same instance that is selected in Xcode, Xcode will warn you in the project settings.
Jul ’20
Reply to Fail to load system extension due to invalid code signature or missing entitlements
I encountered this issue but do not remember in which specific scenario. Reading my "don't" notes, this reminds me of this case: Avoid creating a macOS App Development provisioning profile: you probably will end up with a system extension that can not be loaded because the signature can not be verified (and the parent app will tell you everything is fine). Otherwise, you probably need to check that the entitlements are correctly set up as documented in this thread: https://developer.apple.com/forums/thread/125508
Jul ’20
Reply to Is Network Extension -- XPC --> launchd daemon possible?
@Babse In my case, the XPC service is in a launchd daemon. To figure out how to make this work, I had the XPC service client code in both the Network Extension and in an app. Because the results of stopping and starting a Network Extension on Catalina are totally unreliable, having the same code in an app helped making sure that the XPC service was correctly started by launchd and that messaging through a proxy object worked. This proved to be useful to detect little mistakes such as not having the same mach service name in the launchd .plist file and the listener code. For the name of the service, I used the following pattern: TeamID.bundle_identifier_of_the_app_embedding_the_network_extension.some_service_name Currently, I have 3 XPC service names defined in the launchd .plist of a single daemon and all services are visible and usable from the Network Extension. I'm not sure whether the name of the launchd .plist file and the Label values matter but, just in case (because of the strange sandbox idea of relying on a group name), I used the same value for both of them with the following pattern: bundle_identifier_of_the_app_embedding_the_network_extension.something Because starting and stopping Network Extensions is unreliable, when something does not work, I usually restart the Mac, thus removing the Network Extension through the System Preferences > Network pref pane seem to also work in most cases. So far, I've probably restarted the Mac more than I did when developing the kernel extension flavor…
Jul ’20