Commit Graph

5707 Commits

Author SHA1 Message Date
Kenny Root
8b0a22dbad Merge changes from topic "usb-adb-separation"
* changes:
  Update USB tests for ADB split
  Move AdbDebuggingManager to AdbService
  AdbService: move source of truth for enabled
  Add empty AdbHandler
  Add systemReady call for AdbService
  Add function to query ADB state
  Register USB as an ADB transport type
  Add ADB transport skeleton
  Add empty AdbManagerInternal for system server
  Add empty AdbService to SystemServer
  Move ADB debugging manager to core
  Rename to AdbDebuggingManager
  Move UsbDebuggingManager to new package
2018-11-02 00:43:05 +00:00
Paul Hu
7a2e9caacf Merge "Support backward compatibility for restricted network permission" am: dffb7d988c am: 8fc1f68512
am: fe32d95a33

Change-Id: Icdf485f714e05fa8500ea785230444fbeac98cc5
2018-11-01 01:13:32 -07:00
Paul Hu
dffb7d988c Merge "Support backward compatibility for restricted network permission" 2018-11-01 07:20:05 +00:00
paulhu
3b0f5ea29e Support backward compatibility for restricted network permission
Some native daemons legacy design work with SYSTEM_UID. If none of
SYSTEM_UID apps declare the restricted network permission, it will
result in permission denial in daemons. Allow SYSTEM_UID in the
devices shipped before Q to support backward compatibility.

Bug:114245686
Test: 1. runtest frameworks-net
      2. atest FrameworksNetTests
      3. Native daemons with SYSTEM_UID can work normally

Change-Id: I6f3f0d83bcae74ef5389535b528af3baf649fa48
2018-11-01 10:38:11 +08:00
Kenny Root
c2a54e8b36 Update USB tests for ADB split
The AdbService handles all the ADB keys and toggling, so remove the
calls to it from the UsbTests which won't necessarily run on devices
that only have ADB but no USB ports.

Test: cts-tradefed run cts -m CtsUsbTests
Change-Id: I3242d4d2f80e71a744fc52645daffb8344717d4d
2018-10-31 16:11:02 +09:00
Junyu Lai
74d5f7f24a Merge "Fix negative uid stats caused by 464xlat adjust when eBPF is on." am: 0d63da86e2 am: d62c2baa6d
am: cadfe44e05

Change-Id: I9d0d8b67ed0159ba2a71059620ebe5698eb79ccb
2018-10-30 19:56:01 -07:00
junyulai
c33ac0d43b Fix negative uid stats caused by 464xlat adjust when eBPF is on.
When using xt_qtaguid to count per uid stats,
NetworkStatsService needs to adjust the 464xlat traffic since
iptables module would double count for ipv4 and ipv6 packet.
But for eBPF, the per uid stats is collected in a different
hook, so the adjustment on root uid would only be needed in tx
direction.

Bug: 112226716
Test: 1. Make ipv4 traffic in ipv6-only network and check data
         usage.
      2. Make ipv4 traffic in a client which connect to
         ipv6-only hotspot.
      3. runtest frameworks-net
      4. cts-tradefed run cts -m CtsNetTestCases -t \
                 android.net.cts.TrafficStatsTest
      5. cts-tradefed run cts -m CtsUsageStatsTestCases

Change-Id: Ic9a84f5446eddc943c255d5f3b89dad171f53cac
2018-10-30 21:23:38 +08:00
Luke Huang
8c12dcd11a Merge "Refactor UidRange by using stable aidl structure" am: d1d3b374b7 am: 53c8b8a939
am: 68f4bd92bc

Change-Id: I82e06fe93a3ed88368b649ef8d3283322191ffe7
2018-10-28 18:06:15 -07:00
Treehugger Robot
d1d3b374b7 Merge "Refactor UidRange by using stable aidl structure" 2018-10-29 00:17:34 +00:00
Junyu Lai
0d73f4451d Merge "No-op refactoring of VPN lockdown status check." am: 5c67de8417 am: f03247ac4e
am: 4c2b34797e

Change-Id: I3fb09861c6e6d4c6db2a4105b464018d0b1d8224
2018-10-25 23:28:21 -07:00
markchien
7018cc1e8b Merge "Reduce excess local prefix computations" am: 35d9291ca7 am: 069fd8e996
am: 7b86429051

Change-Id: I9f196b866e8518c9fa0dd22ee5e2a7725130361d
2018-10-25 16:58:22 -07:00
junyulai
8ed8915e53 No-op refactoring of VPN lockdown status check.
Currently, if VPN lockdown is disabled, the blocking judgement
inside VPN will return false immediately. It will make
ConnectivityService hard to check blocked status by a given
VPN lockdown status.

Thus, move this check into ConnectivityService and check it
externally.

Bug: 117814902
Test: 1. manual test with 3rd-party vpn app
      2. runtest frameworks-net

Change-Id: Ia8319b1a1a12f1058c24badf2431f2ec69bc78e7
2018-10-25 16:43:50 +08:00
Luke Huang
77017913a4 Refactor UidRange by using stable aidl structure
Use stable aidl generated structure instead of UidRange

Test: runtest frameworks-net passes
Test: manual testing of UidRange related function works
Change-Id: Iaf1c10777dc1e71df2be2a57533a10257b12626b
2018-10-24 19:45:09 +09:00
John Reck
8884cfc13e Merge "Rename & package shuffle" 2018-10-23 20:02:00 +00:00
TreeHugger Robot
f52b0cf908 Merge "Use existing getProcessPid method to get pid of system_server." 2018-10-23 08:14:48 +00:00
Richard Uhler
d64bdbccf4 Use existing getProcessPid method to get pid of system_server.
Rather than using custom logic for it.
Test: atest -v system-memory-test
Bug: 111830582

Change-Id: I94cb856fbedbdf2b653f448857024f7f79f3de6f
2018-10-22 11:48:19 +01:00
Weien Wang
4710c04e1f Add new WallpaperInfo attr settingsSliceUri.
Add settingsSliceUri attribute for supporting live wallpaper inline-
control, public for AOSP live wallpaper to use.

Bug: 117200693
Test: atest tests/Internal/src/android/app/WallpaperInfoTest.java

Change-Id: Iffe9fbd9f49daf8a63d5745f91532de13b7288e3
2018-10-22 14:16:55 +08:00
markchien
69955497d4 Reduce excess local prefix computations
only recomputing on the LISTEN_ALL callback

Test: - build, flash, booted
      - runtest frameworks-net

bug: 110335330

Change-Id: I606574f1a8a2899ed4688d7d5ec2cbe0f2638a94
2018-10-22 12:37:42 +09:00
Junyu Lai
47d413df18 Merge "Add tests for the network blocked status change" am: af0de1a2e9 am: 43d8774f68
am: 9944d7f079

Change-Id: I0e3367d9641717676653bd54ca41d85422c5d81c
2018-10-19 09:54:18 -07:00
Junyu Lai
43d8774f68 Merge "Add tests for the network blocked status change"
am: af0de1a2e9

Change-Id: I0f3f93807d9089239f572c487d791acd7a324a2e
2018-10-19 09:18:38 -07:00
Mike Yu
f9729757f9 Add tests for the network blocked status change
onBlockedStatusChanged is intruduced for network blocked status.
The changes in this patch are:
  - Test onBlockedStatusChanged which tells apps whether the
    network is blocked.
  - Fixed the tests which is affected by the order changed in
    onAvailable.

Test: as follows
    - runtest frameworks-net
    - runtest -x NetworkPolicyManagerServiceTest.java
Bug: 74575553
Change-Id: I383c037ed895ef69c478dc3cff69fb1e27c42845
2018-10-19 19:52:50 +08:00
Mathieu Chartier
196b939a10 Merge "Sleep 1s before force stop and use killBackgroundApp" am: 2417859fa5 am: 96cb6d97e1
am: c3359b60ca

Change-Id: I1697d8fefc5d549438f05f14527b6fee88e97a6c
2018-10-19 00:26:48 -07:00
Mathieu Chartier
96cb6d97e1 Merge "Sleep 1s before force stop and use killBackgroundApp"
am: 2417859fa5

Change-Id: I92d83f16123dd16f68eb0d95d83f9dbabd493d01
2018-10-18 23:52:16 -07:00
Mathieu Chartier
5615adf824 Sleep 1s before force stop and use killBackgroundApp
Leave a bit of time before force stopping the application. This might
help prevent bad numbers.

Call killbackgroundApp after doing force-stop to make sure nothing is
still running.

Bug: 117094510
Bug: 117888316
Test: atest google/perf/app-startup/third-party-apps/cold-dropcache-stable-test
Change-Id: I47792f99b38edf2c40f61cc3f6817d82e6339d12
2018-10-18 22:03:47 +00:00
Sundong Ahn
a1bc1b1331 Merge "Build com.android.media.remotedisplay with java_sdk_library"
am: 1ad4aed0b9

Change-Id: Icb633bd7f8cc0ed932c0aa70ef9dfe475722ada0
2018-10-14 18:48:01 -07:00
Treehugger Robot
1ad4aed0b9 Merge "Build com.android.media.remotedisplay with java_sdk_library" 2018-10-15 01:32:16 +00:00
Neil Fuller
c83ed07391 Merge "Remove explicit dependencies on "core" libraries" am: 18f9a2c24d am: d252f61f66
am: ad3947bb43

Change-Id: I4eec960d3925bd6c30ac91f072883af8fddbd825
2018-10-12 03:36:23 -07:00
Neil Fuller
d252f61f66 Merge "Remove explicit dependencies on "core" libraries"
am: 18f9a2c24d

Change-Id: I326380ec0c10f29c09c64f4044a9c79c9ab2648f
2018-10-12 03:12:22 -07:00
Neil Fuller
066ca17372 Remove explicit dependencies on "core" libraries
The dependencies are unnecessary since bouncycastle, okhttp
and conscrypt are included in the "standard libraries".

Test: build
Bug: 113148576
Change-Id: Ic8d15d911decbdd6391db8c1231b845353586a54
2018-10-11 16:57:18 +01:00
Luke Huang
f33cfcf50d Merge "Refactor tetherGetStats by using stable aidl structure" am: 335253df0f am: f81dce0f79
am: 7ec816b07c

Change-Id: Id3d6e57c10afb06271228b59a40cec91edaed7e4
2018-10-11 00:38:42 -07:00
Luke Huang
f81dce0f79 Merge "Refactor tetherGetStats by using stable aidl structure"
am: 335253df0f

Change-Id: Ibaefeee3e115cc04163f1b07cdba148f9e9ab3b5
2018-10-10 23:10:10 -07:00
Luke Huang
335253df0f Merge "Refactor tetherGetStats by using stable aidl structure" 2018-10-11 05:58:22 +00:00
Colin Cross
62df67ddf7 Remove workarounds for b/79755007 am: f5c86dc1c1
am: 9428a92293

Change-Id: I89276e49bf16da997cc4501067caa946054af3b4
2018-10-10 22:54:33 -07:00
Colin Cross
9428a92293 Remove workarounds for b/79755007
am: f5c86dc1c1

Change-Id: I5bb981fdf807749c88492dfb2c24ea8b936992cf
2018-10-10 16:45:01 -07:00
Colin Cross
bfff7e2fe8 Merge changes from topic "aapt2-manifest-elements"
am: e75f2f504e

Change-Id: I2cf054f942109e539c2439887078a6e182603456
2018-10-10 16:13:26 -07:00
Treehugger Robot
e75f2f504e Merge changes from topic "aapt2-manifest-elements"
* changes:
  Remove workarounds for b/79755007
  AAPT2: Add the rest of supported manifest elements
  AAPT2: Add supported manifest elements
2018-10-10 22:29:57 +00:00
Yan Yan
01b46f8ffd Merge changes I10c01f2b,Ie05bc535 am: 277d42a035 am: 47a589c945
am: 73d9c32aaa

Change-Id: I074056f861332835adaed32ad7d43ed36667ffa3
2018-10-05 12:35:56 -07:00
Yan Yan
47a589c945 Merge changes I10c01f2b,Ie05bc535
am: 277d42a035

Change-Id: I2e55a266f65268ca734c028d4da7add14a281d75
2018-10-05 11:47:12 -07:00
Yan Yan
277d42a035 Merge changes I10c01f2b,Ie05bc535
* changes:
  Check to ensure UDP-encap is used only for IPv4
  Add UDP encapsulation tests for IpSecService.
2018-10-05 17:38:41 +00:00
TreeHugger Robot
8e78d358ba Merge "Convert native processes memory test to JUnit4 test" 2018-10-05 17:15:18 +00:00
John Reck
32f140aa67 Rename & package shuffle
Rename DisplayListCanvas -> RecordingCanvas
Move RecordingCanvas to android.graphics
Move RenderNode to android.graphics

Bug: 112709971
Test: make & boot
Change-Id: Iddeb6a89f8923ea81a1f37bbee4e9b1db8ede238
2018-10-04 16:18:12 -07:00
evitayan
e4259d3e53 Check to ensure UDP-encap is used only for IPv4
This commit checks if UDP-encapsulation is used
for unsupported address family and throws
IllegalArgumentException when it happens.

Bug: 74213459
Test: Tests added in testCreateTransportModeTransformWithEncap
      and testCreateTunnelModeTransformWithEncap.
      Command: runtest frameworks-net
      Verified on taimen.
Change-Id: I10c01f2bad6aca23430849ea9ef6c1eb157ae131
2018-10-04 11:44:00 -07:00
evitayan
0a7d3e3424 Add UDP encapsulation tests for IpSecService.
This commit adds tests to ensure that IpSecService properly
handles UDP-encapsulation transforms correctly.

Bug: 76110065
Test: Added: testCreateTransportModeTransformWithEncap,
             testCreateTunnelModeTransformWithEncap.
      Command: runtest frameworks-net
      Verified on taimen.
Change-Id: Ie05bc5354266806c2d03b0b3d73a4696a89eccf2
2018-10-04 10:37:47 -07:00
Ng Zhi An
cf6b343b84 Convert native processes memory test to JUnit4 test
Bug: 117128561
Test: atest native-processes-memory-test
Change-Id: I1bf8abf23b5cb315f45ce2446f001a1fa5ef59f1
2018-10-04 10:06:21 -07:00
Luke Huang
13b79e83aa Refactor tetherGetStats by using stable aidl structure
Use stable aidl structure instead of persistbundle

Test: runtest frameworks-net passes
Test: manual testing of tetherGetStats function works

Change-Id: I6835541d450446ba7993ac9f5b783d34229b79cb
2018-10-04 16:24:44 +08:00
Tiger Huang
e91ae63374 Merge "Track focus changes on external displays (2/4)" 2018-10-04 05:58:00 +00:00
Remi NGUYEN VAN
939e83d2ad Merge "Send hostname and MTU options in DHCP ACK/OFFER" am: 3b12359e4c am: 94b0562628
am: 04615b7999

Change-Id: Ibae5f00e85b7f6ff2f62f72f1d5f8bfb3bca9f8e
2018-10-03 19:40:11 -07:00
Remi NGUYEN VAN
94b0562628 Merge "Send hostname and MTU options in DHCP ACK/OFFER"
am: 3b12359e4c

Change-Id: I47972e25fd69471aacd52b58ffed67be1e685557
2018-10-03 19:08:34 -07:00
Remi NGUYEN VAN
3b12359e4c Merge "Send hostname and MTU options in DHCP ACK/OFFER" 2018-10-04 01:08:19 +00:00
Kweku Adams
a23c0f09b5 Merge "Initial unit test for DeviceIdleController." 2018-10-03 23:27:30 +00:00