Commit graph android_packages_modules_Co.../framework
Message SHA1
API to get network visible network capability name
Test: atest DataConnectionTest, DcTrackerTest
Bug: 181916712
CTS-Coverage-Bug: 183553812
Change-Id: Iae63ac4d62641cee2bd0f0c5f50dd729750d514c

Sarah Chin   commited 2021-03-24 00:27:11 +00:00
34fbbbb6b9
Merge "Remove Network, NetworkRequest metrics from jobscheduler" into sc-dev
Aaron Huang   authored and   Android (Google) Code Review   commited 2021-03-23 13:22:32 +00:00
c34dcd5c3e
Merge "Move deduceRestrictedCapability to libs/net and rename it" into sc-dev
Aaron Huang   authored and   Android (Google) Code Review   commited 2021-03-23 12:50:40 +00:00
7609660f73
Merge "Expose NetworkAgent constructor taking a NetworkScore parameter" into sc-dev
TreeHugger Robot   authored and   Android (Google) Code Review   commited 2021-03-23 12:45:24 +00:00
3cccf48918
Merge "Expose NetworkScore to external caller" into sc-dev
Lucas Lin   authored and   Android (Google) Code Review   commited 2021-03-23 12:18:23 +00:00
d8e8a9557b
Merge "[JS01]Remove hidden API usage of Connectivity Sevice" into sc-dev
Frank Li   authored and   Android (Google) Code Review   commited 2021-03-23 10:22:28 +00:00
d968d80146
Remove Network, NetworkRequest metrics from jobscheduler
These metrics are deprecated so remove them from jobscheduler.
Also remove dumpDebug method from Network, NetworkRequest and
NetworkCapabilities because there's no caller anymore.

This change also for connectivity mainline module. These
three classes are inculded in framework-connectivity so
external module cannot have dependencies on its hidden API.
With this change, the dependencies can be removed.

Bug: 178777253
Test: FrameworksNetTests
      JobStoreTest
      adb shell dumpsys jobscheduler --proto
      CtsIncidentHostTestCases:JobSchedulerIncidentTest
Change-Id: Ie0c540303ba06b8fba029d2b98ae753afb08c963

Aaron Huang   commited 2021-03-23 10:19:41 +00:00
967f77c269
Expose NetworkAgent constructor taking a NetworkScore parameter
Vpn constructs NetworkAgent with this exposed NetworkAgent
constructor. Given NetworkAgent is moving into the incoming
connectivity module, Vpn which is outside the module will not
be able to access it if it's not in the API surface. Thus,
expose it to allow Vpn to use it.

Bug: 182963397
Test: make update-api
Change-Id: Ic2357dcfff3233e0dd17b48b0e376a5095ef60fa
CTS-Coverage-Bug: 172183305

Chiachang Wang   commited 2021-03-23 08:51:05 +00:00
3ee63e5132
Expose NetworkScore to external caller
NetworkScore will be a part of mainline module, so the external
callers cannot call its hidden APIs. Expose needed APIs to
the external callers.

CTS-Coverage-Bug: 182963397
Bug: 182963397
Test: m
Change-Id: Iddf8c71a5f51a40bc6ff78626b3e8ee530d1b7eb

lucaslin   commited 2021-03-23 16:17:37 +08:00
18158aa33b
Merge "Add NDK API for getprocnetwork" into sc-dev
Remi NGUYEN VAN   authored and   Android (Google) Code Review   commited 2021-03-23 07:11:06 +00:00
56db6551f5
[JS01]Remove hidden API usage of Connectivity Sevice
The Connectivity service will become the mainline module.
Therefore, remove the caller of using Connectivity's
hidden API outside the module and expose the required
connectivity API used in Jobscheduler.

Bug: 183456204
CTS-Coverage-Bug: 170598012
Test: atest JobStoreTest
Change-Id: Ie6bc81ff382fb242b98f35d28a96defc207c7987

lifr   commited 2021-03-23 13:58:48 +08:00
308bcccd2b
Merge "[TL02]Remove hidden API usage of NetworkAgent" into sc-dev
Frank Li   authored and   Android (Google) Code Review   commited 2021-03-23 02:03:59 +00:00
6fa238f167
[TL02]Remove hidden API usage of NetworkAgent
The connection service will become the mainline module.
Remove the hidden API usage of NetworkAgent.

Bug: 170598012
CTS-Coverage-Bug: 170598012
Test: atest FrameworksNetTests FrameworksTelephonyTests
      atest FrameworksWifiTests
Change-Id: I4e4040ae7f94bdf479c7df9ec2ffabafbe06331c

lifr   authored and   Paul Hu   commited 2021-03-23 02:01:38 +00:00
c4fd62072b
Merge "[VCN15] expose addUnwantedCapability and related APIs" into sc-dev
Lorenzo Colitti   authored and   Android (Google) Code Review   commited 2021-03-23 01:19:39 +00:00
1cd2428be0
Add NDK API for getprocnetwork
The API is the getter couterpart for setprocnetwork.
Use it in NetworkUtils so that the NDK API can be the source of truth
for the process network.

Bug: 171540887
Test: atest CtsNetTestCases
      Tests in change I311b58585033c2ca50ce5477ea9cd94b6f127507
Change-Id: Ie8f68cf1fa57deddb63324c1abf3d6fd5b0ef500

Remi NGUYEN VAN   commited 2021-03-23 01:01:06 +00:00
31f329e987
Revert "Have a new method in NetworkAgentConfig.Builder to set allowBypass"
This reverts commit 974644dd3c.

Reason for revert: Broken build b/183416288

Change-Id: Id9ec9fb98b8f88eeb7db1d1442d76456aaf350d1

Joshua Mccloskey   commited 2021-03-22 18:55:32 +00:00
02da918919
Have a new method in NetworkAgentConfig.Builder to set allowBypass
Have a new method in NetworkAgentConfig.Builder for Vpn to set
allowBypass.

Bug: 182963397
Test: m
Change-Id: I3f244464438325ee7f8a1b953d3fb28186293628

lucaslin   authored and   Lucas Lin   commited 2021-03-22 18:44:48 +00:00
974644dd3c
Move deduceRestrictedCapability to libs/net and rename it
NetworkCapabilities is included in framework-connectivity, so external
module cannot have dependencies on its hidden API. Move the method to
libs/net so that external modules can use it by including the library.

Bug: 178777253
Test: FrameworksNetTests
Change-Id: I77970b3a5e5e0e9d263639694b1f06519169bf64

Aaron Huang   commited 2021-03-22 22:35:10 +08:00
f0fc6d7f68
Merge "Add NetworkRequest.Builder creating from an existing instance" into sc-dev
Chiachang Wang   authored and   Android (Google) Code Review   commited 2021-03-22 13:17:43 +00:00
577911cc62
Add NetworkRequest.Builder creating from an existing instance
Provide a formal way to construct a new NetworkRequest from an
existing instance. The network capabilities inside the
NetworkRequest is hidden. There is no way to pass a
NetworkRequest and update its capabilities. Add
NetworkRequest.Builder creating from an existing instance to
allow to clone the network capabilities.

Bug: 172183305
Test: make update-api
Change-Id: I068462b2a1410daf67b0c95f2b643d396f079531
CTS-Coverage-Bug: 172183305

Chiachang Wang   commited 2021-03-22 13:05:10 +00:00
7625498617
Merge "Move trimV4AddrZeros to libs/net" am: 22cb7841a5 am: bc1c1bc38e am: 7fd39d2852
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1636022

Change-Id: I7908772ff2f3b2c5fc1dd9a3510fce0f7ee78ba5

Treehugger Robot   authored and   Automerger Merge Worker   commited 2021-03-22 12:31:39 +00:00
80d92cb03c
Merge "Swap parameters in QosCallback#registerQosCallback" am: dcc2fb2a19 am: 507df2663e am: 2e744846a0
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1628901

Change-Id: Ice84bb2e6d855ed88e7e432cf49739e69c9e01de

Jayachandran Chinnakkannu   authored and   Automerger Merge Worker   commited 2021-03-22 12:30:40 +00:00
687d2a3118
[VCN15] expose addUnwantedCapability and related APIs
Test: m -j doc-comment-check-docs
Bug: 175662146
Change-Id: I3f2e6a99e015f09cc4405f6804eac4ae33e3dcc7

junyulai   authored and   Junyu Lai   commited 2021-03-22 11:11:26 +00:00
e76b5f7004
Merge "Add NetworkFactory to connectivity jarjar rules" into sc-dev
Remi NGUYEN VAN   authored and   Android (Google) Code Review   commited 2021-03-22 09:27:06 +00:00
411f6477c6
Expose some APIs from ConnectivityManager
- Expose setRequireVpnForUids to Vpn.java
- Expose setLegacyLockdownVpnEnabled to LockdownVpnTracker.java
- Expose requestRouteToHostAddress to
  GnssNetworkConnectivityHandler.java

Bug: 182963397
Test: m
Change-Id: I1fb5ecfbe37878ba3534e6c6c7599ca29db2735c

lucaslin   commited 2021-03-22 11:51:27 +08:00
97fb10a3a6
Add NetworkFactory to connectivity jarjar rules
NetworkFactory is part of net-utils-device-common, but is outside of
the com.android.net.module.util and needs a separate jarjar rule.

Bug: 171540887
Test: atest FrameworksNetTests
Change-Id: Iec828a789175acdbe4e7f35e4cc942922540495c

Remi NGUYEN VAN   commited 2021-03-22 03:50:15 +00:00
8c1b75521a
Merge "Move trimV4AddrZeros to libs/net" am: 22cb7841a5
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1636022

Change-Id: Ifbad5630a39f8990479a5f20e018a3a499334fe1

Treehugger Robot   authored and   Automerger Merge Worker   commited 2021-03-22 03:23:48 +00:00
bc1c1bc38e
Merge "Swap parameters in QosCallback#registerQosCallback" am: dcc2fb2a19
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1628901

Change-Id: I2c371b6f1dc25f84a389480e46d9d582e9da148b

Jayachandran Chinnakkannu   authored and   Automerger Merge Worker   commited 2021-03-22 03:18:17 +00:00
507df2663e
Merge "Move trimV4AddrZeros to libs/net"
Treehugger Robot   authored and   Gerrit Code Review   commited 2021-03-22 01:37:06 +00:00
22cb7841a5
Merge "Use jniThrowErrnoException from JNIHelp" into sc-dev
Remi NGUYEN VAN   authored and   Android (Google) Code Review   commited 2021-03-22 00:20:36 +00:00
e8753c9a7d
Merge "Swap parameters in QosCallback#registerQosCallback"
Jayachandran Chinnakkannu   authored and   Gerrit Code Review   commited 2021-03-21 21:02:36 +00:00
dcc2fb2a19
resolve merge conflicts of 454f122745 to stage-aosp-master
Merged-In: Ib9d7923104ac0a60f6af5a3a2d2b7f13bc0262e3
Change-Id: Ib9d7923104ac0a60f6af5a3a2d2b7f13bc0262e3

Roshan Pius   commited 2021-03-21 19:20:35 +00:00
122fc06389
resolve merge conflicts of 403b7fd0b0a6736bcee1817fb5c774f8c8a040de to stage-aosp-master
Change-Id: Ib9d7923104ac0a60f6af5a3a2d2b7f13bc0262e3

Roshan Pius   commited 2021-03-21 19:16:33 +00:00
1e97e45498
Merge changes from topics "revert-1645768-revert-1626206-replaceUidRange-MSYTKFNGUE-HIUTVTIGIR", "ti_redaction"
* changes:
  TransportInfo: Add a generic redaction mechanism
  Revert "Revert "Expose uids related APIs in NetworkRequest and N..."
  Revert^2 "Replace the usage of UidRange"

Treehugger Robot   authored and   Gerrit Code Review   commited 2021-03-21 16:41:13 +00:00
454f122745
Add connectivity protos to framework-connectivity
The protos are built separately by framework-connectivity from framework
protos, keeping only android.net protos for the connectivity jar.

Bug: 171860710
Test: m framework-connectivity.impl
Change-Id: I2c4a37ff2ee9e8efde49885feeafa27dcff7ca2c
Merged-In: I2c4a37ff2ee9e8efde49885feeafa27dcff7ca2c

Remi NGUYEN VAN   authored and   Lorenzo Colitti   commited 2021-03-20 22:51:35 +09:00
f96b26606a
Move connectivity AIDLs to android.net
java_sdk_libraries and apexes need to contain bootclasspath classes
under predefined packages. Tethering currently uses android.net, so make
sure all the connectivity bootclasspath classes are under android.net.

This avoids maintaining two packages for the tethering APEX, where
com.android.connectivity.aidl is only used by internal AIDL files.

Bug: 182984842
Test: m
Change-Id: I611f1941698c574e37aea912ee76dadc8b32e41a
Merged-In: I611f1941698c574e37aea912ee76dadc8b32e41a

Remi NGUYEN VAN   authored and   Lorenzo Colitti   commited 2021-03-20 22:51:35 +09:00
43dea2835e
Migrate framework-connectivity internal resources
Use ServiceConnectivityResources instead.
Start by creating resources in the ServiceConnectivityResources package
to match the internal configuration, and common overlays.

Bug: 182125649
Test: device boots, has connectivity
Change-Id: I77a3efca2cd644f9828db1ed5d3cae8070fb8363
Merged-In: I77a3efca2cd644f9828db1ed5d3cae8070fb8363

Remi NGUYEN VAN   authored and   Lorenzo Colitti   commited 2021-03-20 22:35:16 +09:00
5245c4c0f0
Add multipath preference, background status API
Add APIs for getMultipathPreference and getRestrictBackgroundStatus.
Both are used by Connectivity to back the external
ConnectivityManager.getRestrictBackgroundStatus, and
ConnectivityManager.getMultipathPreference APIs.

Test: atest CtsNetTestCases
      atest ConnectivityServiceTests
      atest NetworkPolicyManagerServiceTest
Bug: 176289731
Change-Id: I8a03162b2f6691086bb64e75ffd354cdfca7f86a
Merged-In: I8a03162b2f6691086bb64e75ffd354cdfca7f86a

Remi NGUYEN VAN   authored and   Lorenzo Colitti   commited 2021-03-20 22:23:16 +09:00
e62e7ff645
TransportInfo: Add a generic redaction mechanism
This replaces the existing mechanism for redacting location sensitive
fields with a more extensible mechanism. Currently supported redactions
are for the following permissions:
i. ACCESS_FINE_LOCATION
ii. LOCAL_MAC_ADDRESS
iii. NETWORK_SETTINGS

Also, removed WifiInfo from ConnectivityServiceTest to reduce cross
dependencies on wifi code.

Bug: 156867433
Bug: 162602799
Test: atest android.net
Test: atest com.android.server
Change-Id: I2bb980c624667a55c1383f13ab71b9b97ed6eeab

Roshan Pius   commited 2021-03-19 20:15:21 +00:00
e2d2838805
Merge "Fix InetAddressCompat exception handling" into sc-dev
TreeHugger Robot   authored and   Android (Google) Code Review   commited 2021-03-19 16:14:10 +00:00
a9a0b49bbc
Fix InetAddressCompat exception handling
Fix InetAddressCompat exception handling to throw the original exception
in case of InvocationTargetException, rather than wrapping in a generic
IllegalStateException.

Bug: 183198868
Test: Test device with and without connectivity
Change-Id: Idc4d678afe9f20f920d7061790af4203ab75be26

Remi NGUYEN VAN   commited 2021-03-19 23:56:27 +09:00
257d49c300
Fix InetAddressCompat exception handling
Fix InetAddressCompat exception handling to throw the original exception
in case of InvocationTargetException, rather than wrapping in a generic
IllegalStateException.

Bug: 183198868
Test: Test device with and without connectivity
Change-Id: Idc4d678afe9f20f920d7061790af4203ab75be26

Remi NGUYEN VAN   commited 2021-03-19 14:45:48 +00:00
57707a50da
Merge "Reland: CaptivePortalData: use CharSequence in VenueFriendlyName API" into sc-dev
Chalard Jean   authored and   Android (Google) Code Review   commited 2021-03-19 14:26:06 +00:00
4be4b3eee7
Use jniThrowErrnoException from JNIHelp
Use the jniThrowErrnoException that is available in JNIHelp, instead of
reimplementing in NetworkUtils.

Bug: 179229316
Test: device boots and has connectivity
Change-Id: I257a9d55ce1f5a7c588e209b4a89d3e7a3e09994

Remi NGUYEN VAN   commited 2021-03-19 13:44:11 +00:00
c1f2d31b39
Merge "Move NetworkUtils JNI out of core/jni" into sc-dev
Remi NGUYEN VAN   authored and   Android (Google) Code Review   commited 2021-03-19 13:42:54 +00:00
d5248e068a
Merge "Add startCaptivePortalApp to system API" am: 1756295fc5 am: c5472a3cf7 am: 8020cb4517
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1639899

Change-Id: Ia3be29892f62b82d23a165bc8334a083c674aefb

Chiachang Wang   authored and   Automerger Merge Worker   commited 2021-03-19 13:09:03 +00:00
abe928e7eb
Merge "[NS03] Mix in other CS-managed properties" am: 80e17b0086 am: e5421446a7 am: 69c741ec42
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1556101

Change-Id: I20c4d8392dba72b142cd9cdf15bed94d52848b81

Chalard Jean   authored and   Automerger Merge Worker   commited 2021-03-19 11:32:34 +00:00
4a22d06d85
Merge "Expose getCapabilities" am: ca98471c77 am: f21c73b7ad am: 00a76b180b
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1641919

Change-Id: I9a6b6f405ee4b7d5d03173d6c5e22e1018dc3417

Lucas Lin   authored and   Automerger Merge Worker   commited 2021-03-19 11:32:07 +00:00
7ead06e186
Merge "Add startCaptivePortalApp to system API"
Chiachang Wang   authored and   Gerrit Code Review   commited 2021-03-19 11:30:20 +00:00
1756295fc5
Move NetworkUtils JNI out of core/jni
Keep the utilities included via a library, but move them out of
core/jni, and prepare a library to package them together with
framework-connectivity.

Also remove unnecessary dependencies in framework-connectivity.

Bug: 171540887
Test: device boots and has connectivity

Change-Id: I0b55dfe92f3cb6e848d79ac7953756f39aaa2597

Remi NGUYEN VAN   commited 2021-03-19 11:01:17 +00:00
c58c993dda