MacOS system extension not being started

I am recently learning Apple's system extension using MacOS and downloaded a sample from apple's official document. https://developer.apple.com/documentation/networkextension/filtering_network_traffic, which use to filter incoming connections. An video talking about it can be found here, though a bit old.

Although I can build the sample code successfully using xcode, but the system extension is actually not started. (I have added log to verify this), specifically the main.swift under SimpleFirewallExtension folder is not loaded

I have read this article - https://www.avanderlee.com/debugging/network-extension-debugging-macos, saying if the main.swift in not loaded, there must some configuration issue in the project setup. But the project is downloaded from Apple's sample. Anyone has encounter this before?

I am using macOS Ventura version 13.1.1, Xcode version 14.3.

Accepted Reply

Yes, I need to change quite a bit in order to make the app to run successfully. But still, the network extension seems is not running? I have also captured the system log when the app is running. Can you kindly help to see any abnormal thing happen? https://drive.google.com/file/d/1jUsGxEAFrLpjI2JxSCsBYZWAnnR-aIMM/view

Replies

Hey hey, that article was… well… inspired by my Debugging a Network Extension Provider post (-:

saying if the main.swift in not loaded, there must some configuration issue in the project setup.

So, to be clear, you added a ‘first light’ log point to your sysex and did not see it logged, right?

But the project is downloaded from Apple's sample.

That’s doesn’t mean what you think it means. In situations like this, where the sample requires code signing and complex packaging, it can be tricky to get a sample working locally.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Yes, I need to change quite a bit in order to make the app to run successfully. But still, the network extension seems is not running? I have also captured the system log when the app is running. Can you kindly help to see any abnormal thing happen? https://drive.google.com/file/d/1jUsGxEAFrLpjI2JxSCsBYZWAnnR-aIMM/view