Timac / VPNStatus

VPNStatus, a replacement for macOS builtin VPN Status
https://blog.timac.org/2018/0719-vpnstatus/
MIT License
221 stars 31 forks source link

Is there a way to configure vpnutil to ignore some of the VPNs? #25

Closed skoch13 closed 12 months ago

skoch13 commented 1 year ago

Thank you for these beautiful tool!

I tried the suggested option defaults write org.timac.VPNStatus IgnoredVPNs "Little Snitch,HiddenVPN,AnotherHiddenVPN", but I guess it works only for the VPNStatus app, while I'm solely using the cli one.

So the question is there a way to hide some of the VPNs from the list?

Timac commented 12 months ago

The command line tool vpnutil has no embedded info.plist. As such it has no BundleID and can't load the preferences that you could set using:

defaults write org.timac.vpnutil IgnoredVPNs "Little Snitch,HiddenVPN,AnotherHiddenVPN"

The right solution would be to embed an Info.plist as I documented for other command line tools here: https://blog.timac.org/2021/0516-mac-app-store-embedding-a-command-line-tool-using-paths-as-arguments/#infoplist

Timac commented 12 months ago

@skoch13 I added the embedded Info.plist. If you recompile the command line tool vpnutil, you should now be able to hide the VPNs using:

defaults write org.timac.vpnutil IgnoredVPNs "Little Snitch,HiddenVPN,AnotherHiddenVPN"
skoch13 commented 12 months ago

@Timac wow! thank you!