From 83956e2a5d48e7859968e8d96a7d4e272072dce7 Mon Sep 17 00:00:00 2001 From: Yan Yan Date: Wed, 24 Mar 2021 11:20:31 -0700 Subject: [PATCH] Create TunnelConnectionParams interface TunnelConnectionParams represents configurations for setting up a secure encrypted tunnel with a remote endpoint. TunnelConnectionParams will be used to configure a VCN and will be used for VPN configuration in the future. Bug: 180664474 Test: make update-api Change-Id: Ic8e5c8535e84971517f16c54ce8b8645cfc7f944 --- core/api/current.txt | 3 ++ .../android/net/TunnelConnectionParams.java | 29 +++++++++++++++++++ 2 files changed, 32 insertions(+) create mode 100644 core/java/android/net/TunnelConnectionParams.java diff --git a/core/api/current.txt b/core/api/current.txt index f7cc6599f8d15..82acc7698bc37 100644 --- a/core/api/current.txt +++ b/core/api/current.txt @@ -25138,6 +25138,9 @@ package android.net { field public static final int UNSUPPORTED = -1; // 0xffffffff } + public interface TunnelConnectionParams { + } + public abstract class Uri implements java.lang.Comparable android.os.Parcelable { method public abstract android.net.Uri.Builder buildUpon(); method public int compareTo(android.net.Uri); diff --git a/core/java/android/net/TunnelConnectionParams.java b/core/java/android/net/TunnelConnectionParams.java new file mode 100644 index 0000000000000..f5b35395b0bf2 --- /dev/null +++ b/core/java/android/net/TunnelConnectionParams.java @@ -0,0 +1,29 @@ +/* + * Copyright (C) 2021 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package android.net; + +/** + * TunnelConnectionParams represents a configuration to set up a tunnel connection. + * + *

Concrete implementations for a control plane protocol should implement this interface. + * Subclasses should be immutable data classes containing connection, authentication and + * authorization parameters required to establish a tunnel connection. + * + * @see android.net.ipsec.ike.IkeTunnelConnectionParams + */ +// TODO:b/186071626 Remove TunnelConnectionParams when non-updatable API stub can resolve +// IkeTunnelConnectionParams +public interface TunnelConnectionParams {}