6 if (len(sys.argv) < 1):
7 print("Usage: %s <VPN connection id>" % (sys.argv[0]))
10 bus = dbus.SystemBus()
12 manager = dbus.Interface(bus.get_object("net.connman.vpn", "/"),
13 "net.connman.vpn.Manager")
15 connections = manager.GetConnections()
17 path = "/net/connman/vpn/connection/" + sys.argv[1]
19 print("Attempting to disconnect VPN %s" % (path))
21 connection = dbus.Interface(bus.get_object("net.connman.vpn", path),
22 "net.connman.vpn.Connection")
24 connection.Disconnect()