Inconsistent behaviour of System Preferences for VPNs

We are developing a VPN app using SystemExtension and PacketTunnel provider. Everything is working fine in the SystemExtension but the information displayed Network Preferences and VPN menu item are missing or inconsistent or even duplicates. In the below screenshot, you can see time mismatch between VPN status and menu item.

In below screenshot, you can see duplicate Disconnect and show time options for single configured VPN:

and in below screenshot, you can see the show time and status options completely missing even though VPN is running for some time:

We see this issue on macOS Big Sur as well as Monterey. Is there any way we can control or make this behaviour consistent?

Just to confirm, are you saying that you have two NEPacketTunnelProvider that are both up and claiming traffic on the system at the same time? The reason I am asking is because a NEPacketTunnelProvider is consider to be an Enterprise VPN and only one of them should be running on a machine at a give time. See more on this here.

There is only one PacketTunnel provider configured and running, the one in Connected state. The other one in Running state is a content filter. We see duplicates and inconsistent information for same one packet tunnel VPN.

Thank you for confirming.

information displayed Network Preferences and VPN menu item are missing or inconsistent or even duplicates.

So based on your screen shots it looks like there is more of an inconsistency (connected times mis-matching) issue. What I would recommend here is to fire up a clean VM with a single NEPacketTunnelProvider on it and reproduce the problem with the VPN debug profile installed on the VM. Then, once you have done so here, please take a sysdiagnose and open a bug report. Please post the Feedback ID here.

Thanks Matt, I will do that. It's just that we don't have definite steps to reproduce this issue. It happens after a long time of running the packet tunnel provider. We will try to reproduce and file a bug report.

Inconsistent behaviour of System Preferences for VPNs
 
 
Q