Failed to find a com.apple.networkextension.filter-data extension inside of app

Hello

I'm trying to launch this sample from NetworkExtension on Catalina.

https://developer.apple.com/videos/play/wwdc2019/714/


I set app group, changed bundle identifiers and just launching the app shows me error in System Console:

nesessionmanager Adding event subscription 713 for provider org.cloudveil.PacketTunnelProviderApp.PacketTunnelProvider with extension point com.apple.networkextension.filter-datanesessionmanager NESMFilterSession[SimpleFirewall:FAA0005C-BF89-4FF2-AFA5-C46DE826F82D]: Check Filter Plugin installation for org.cloudveil.PacketTunnelProviderApp (isIP 1)
nesessionmanager NESMFilterSession[SimpleFirewall:FAA0005C-BF89-4FF2-AFA5-C46DE826F82D]: Check Filter Plugin installation for org.cloudveil.PacketTunnelProviderApp (isIP 0)
nesessionmanager NEFilterPlugin(org.cloudveil.PacketTunnelProviderApp[inactive]): Sending start command
nesessionmanager org.cloudveil.PacketTunnelProviderApp[inactive]: starting
neagent Failed to find a com.apple.networkextension.filter-data extension inside of app org.cloudveil.PacketTunnelProviderApp


What could be the possible issues?

Thanks

Replies

The Filtering Network Traffic sample makes no mention of packet tunnel providers at all, and yet that the log messages you posted are full of references to packet tunnel providers. What’s up with that?

Anyway, I took the current Filtering Network Traffic code and tried it here in my office. Specifically, here’s what I did:

  1. Using Xcode 11.3, I opened the project.

  2. I searched for

    com.example.apple-samplecode
    and replaced that with
    com.example.apple-samplecode.126992
    . This makes the App IDs used by the project unique, which is necessary due to the way that things are provisioned.
  3. I set the team on both targets; at this point Xcode sorted out the provisioning automatically.

  4. I built the app.

  5. On a fresh 10.15 VM, I copied the app to

    /Applications
    .
  6. I ran the app.

  7. I clicked Start.

  8. In the System Extension Blocked alert, I clicked Open Security Preferences.

  9. In System Preferences, I authenticated and clicked Allow.

  10. In the Would Like to Filter Network Content alert, I clicked Allow.

  11. In Terminal, I ran the following:

    $ ps ajxww | grep SimpleFirewall
    quinn … /Applications/SimpleFirewall.app/Contents/MacOS/SimpleFirewall
    root  … /Library/SystemExtensions/5FEA26FE-C7F9-48C4-BB83-F1936B2E43E9/com.example.apple-samplecode.126992.SimpleFirewall.SimpleFirewallExtension.systemextension/Contents/MacOS/com.example.apple-samplecode.126992.SimpleFirewall.SimpleFirewallExtension
    …

    As you can see, both the app and the system extension are running.

Share and Enjoy

Quinn “The Eskimo!”
Apple Developer Relations, Developer Technical Support, Core OS/Hardware

let myEmail = "eskimo" + "1" + "@apple.com"