blob: 3c030fe527c50d5a4e3ae6316872724933caebe6 [file] [log] [blame]
// Copyright 2016 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
module ash.mojom;
import "mojo/common/time.mojom";
// Describes a third-party VPN provided by an extension (e.g. Cisco AnyConnect).
struct ThirdPartyVpnProvider {
string name;
string extension_id;
};
// Describes an Arc VPN provider. last_launch_time is used to sort the list of
// Arc VPN providers.
struct ArcVpnProvider {
// Unique android package name of the Arc VPN provider. e.g. vpn.app.package
string package_name;
// App name of Arc VPN provider. e.g. VPNapp
string app_name;
// Unique app id for launching the app. e.g. pbmkokpdlpfmapoiccpblbmjjhhabjaa
string app_id;
// Last launch time of the Arc VPN provider.
mojo.common.mojom.Time last_launch_time;
};
// Manages the VPN provider list in ash. Allows extension-backed VPN providers
// to be added. Ash handles the built-in OpenVPN / L2TP provider internally.
// Allows Arc VPN providers to be added and removed, updates providers' launch
// time so that they are shown in LRU order, updates providers' name change.
interface VpnList {
// Sets the list of third-party VPN providers. The |providers| array may be
// empty to clear the list (e.g. after the last third-party VPN extension is
// uninstalled).
SetThirdPartyVpnProviders(array<ThirdPartyVpnProvider> providers);
// Sets the list of Arc VPN providers.
SetArcVpnProviders(array<ArcVpnProvider> arc_providers);
// Adds or updates an Arc VPN provider.
AddOrUpdateArcVPNProvider(ArcVpnProvider arc_provider);
// Removes an Arc VPN provider.
RemoveArcVPNProvider(string package_name);
};