diff options
| author | 2019-05-30 09:17:23 -0700 | |
|---|---|---|
| committer | 2019-05-30 09:17:23 -0700 | |
| commit | c67f43f80c819f17648cd61b6e7b5ce15d759594 (patch) | |
| tree | 35773d660e02e99cacbde90d3d4fca2966ec24ab | |
| parent | da473275207a8aac32bb90906116278f26389134 (diff) | |
| parent | ad0be320e2bce0bd8af266fd4d79031a087f9a9d (diff) | |
Merge "Fix a comment"
am: ad0be320e2
Change-Id: I14842efdaa0747297a550cc7ff53f169b7cf14fc
| -rw-r--r-- | services/core/java/com/android/server/connectivity/Vpn.java | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/services/core/java/com/android/server/connectivity/Vpn.java b/services/core/java/com/android/server/connectivity/Vpn.java index 6cac49d2a90b..e7a8b132d850 100644 --- a/services/core/java/com/android/server/connectivity/Vpn.java +++ b/services/core/java/com/android/server/connectivity/Vpn.java @@ -963,10 +963,11 @@ public class Vpn { // VPN either provide a default route (IPv4 or IPv6 or both), or they are a split tunnel // that falls back to the default network, which by definition provides INTERNET (unless // there is no default network, in which case none of this matters in any sense). - // Also, it guarantees that when a VPN applies to an app, the VPN will always be reported - // as the network by getDefaultNetwork and registerDefaultNetworkCallback. This in turn - // protects the invariant that apps calling CM#bindProcessToNetwork(getDefaultNetwork()) - // the same as if they use the default network. + // Also, always setting the INTERNET bit guarantees that when a VPN applies to an app, + // the VPN will always be reported as the network by getDefaultNetwork and callbacks + // registered with registerDefaultNetworkCallback. This in turn protects the invariant + // that an app calling ConnectivityManager#bindProcessToNetwork(getDefaultNetwork()) + // behaves the same as when it uses the default network. mNetworkCapabilities.addCapability(NetworkCapabilities.NET_CAPABILITY_INTERNET); mNetworkInfo.setDetailedState(DetailedState.CONNECTING, null, null); |