Commit Graph

7376 Commits

Author SHA1 Message Date
Luke Huang
0911250db9 [automerger skipped] Add Rfc6724 style sort for DnsResolver and fix potential bug am: 51b9f6c069 -s ours
am: 2fdaf771d6 -s ours
am skip reason: change_id I0323f5c7f32fc3fa589b9e87f8e7c9caf744dbd4 with SHA1 d352f4ca85 is in history

Change-Id: Icf444abe7175a0709701fa2865d6c324f911a06f
2019-05-27 22:57:32 -07:00
Luke Huang
f0b1dc8df4 Merge changes from topic "am-851f19c8d7d34bb48accd48868aae501-qt-dev" into qt-dev
am: d8bc2b5a15

Change-Id: I8cd6013a4312d945936a38026285b2e33f6c7c49
2019-05-27 22:52:59 -07:00
Luke Huang
2fdaf771d6 [automerger skipped] Add Rfc6724 style sort for DnsResolver and fix potential bug
am: 51b9f6c069 -s ours
am skip reason: change_id I0323f5c7f32fc3fa589b9e87f8e7c9caf744dbd4 with SHA1 d352f4ca85 is in history

Change-Id: Ie4e69c27646febd06df2b93361f431dbd51bde4f
2019-05-27 22:52:47 -07:00
Luke Huang
d8bc2b5a15 Merge changes from topic "am-851f19c8d7d34bb48accd48868aae501-qt-dev" into qt-dev
* changes:
  Remove broken test testRfc6724Sort
  Add Rfc6724 style sort for DnsResolver and fix potential bug
2019-05-28 05:38:49 +00:00
Luke Huang
4aa400f7eb Remove broken test testRfc6724Sort
This test is conitnuely fail in cuttlefish.
Lack of ipv6 default route in cuttlefish caused the test failed.
The reason is that the result of rfc6724Sort depends on on the route in system.
It is not good to expect any route should exists, so remove it.

Bug: 133649648
Test: atest DnsUtilsTest

Merged-In: Idc6db433585de067e45088b43665c8e37b310397
(cherry picked from commit 91b35f88429d77ddce0e3f539690e6370b89915b)

Change-Id: Idb6f4c094d3466772e3bfc98a57505bf38f381ef
2019-05-28 03:24:14 +00:00
Xiao Ma
322abd62d9 Merge "Wipe the data in IpMemoryStore database upon network factory reset." am: 5ad000a641 am: 0b9f498f86
am: 71950d27d8

Change-Id: Ic042119f35a50cd9abb4c243fc3ba4d767fe2cd4
2019-05-27 18:17:43 -07:00
Xiao Ma
71950d27d8 Merge "Wipe the data in IpMemoryStore database upon network factory reset." am: 5ad000a641
am: 0b9f498f86

Change-Id: I13ad04454e638905b74dd42a1c83266c7c37652f
2019-05-27 18:12:49 -07:00
Xiao Ma
5ad000a641 Merge "Wipe the data in IpMemoryStore database upon network factory reset." 2019-05-28 00:52:00 +00:00
Luke Huang
35c43432dc Merge "Remove broken test testRfc6724Sort" am: ac6c768bd6 am: 79e97b7d21
am: 577b90a8ef

Change-Id: Id9bd0d7cb15a7c04102013f9008abc9ce344d5d2
2019-05-27 07:38:27 -07:00
Luke Huang
577b90a8ef Merge "Remove broken test testRfc6724Sort" am: ac6c768bd6
am: 79e97b7d21

Change-Id: I37aa8acc6beeb1e20b99098b1f9e8d5ef800c4eb
2019-05-27 07:33:33 -07:00
Luke Huang
ac6c768bd6 Merge "Remove broken test testRfc6724Sort" 2019-05-27 14:12:05 +00:00
Chalard Jean
ddfa1f5f4d Reinstate access to a forgotten member
Followup to aosp/964440

Bug: 131764329
Test: none
Merged-In: I6f6b2cf75793532d3d537a223b8e15d7304a1e3f
Change-Id: Ib279c0076016c53e0491fc0df8cefff8ae280d66
(cherry picked from commit 41bd3c57b4ba347ac6eb4546855daf5473264a29)
2019-05-27 12:21:15 +00:00
Chalard Jean
c055af9d6d Merge "Reinstate access to a forgotten member" am: c73af87b45 am: 2f4bd91b99
am: bdee05bfd1

Change-Id: If2cce67f40381e3edc8d43a263ea0e5be4af39d0
2019-05-27 04:38:07 -07:00
Chalard Jean
bdee05bfd1 Merge "Reinstate access to a forgotten member" am: c73af87b45
am: 2f4bd91b99

Change-Id: Ib279c0076016c53e0491fc0df8cefff8ae280d66
2019-05-27 04:33:13 -07:00
Treehugger Robot
c73af87b45 Merge "Reinstate access to a forgotten member" 2019-05-27 11:14:37 +00:00
Luke Huang
179c33f322 Remove broken test testRfc6724Sort
This test is conitnuely fail in cuttlefish.
Lack of ipv6 default route in cuttlefish caused the test failed.
The reason is that the result of rfc6724Sort depends on on the route in system.
It is not good to expect any route should exists, so remove it.

Bug: 133649648
Test: atest DnsUtilsTest
Change-Id: I91f89782b9b989fa1a49e666bb5ce2df3a0dbbf7
2019-05-27 17:49:32 +08:00
Chalard Jean
b807dd8884 Let the system server have CONNECTIVITY_USE_RESTRICTED_NETWORKS.
Also :
- Fix testUidFilteringDuringVpnConnectDisconnectAndUidUpdates that
  was failing on devices with a first released SDK >= Q
- Add a test actually tests that the system has the permission, as
  the test was only testing what's in the mock

Bug: 119770201
Test: New test making sure this stays true
Change-Id: I74cf5f0fa17fcf818f1fed78c7e3e4375c20152e
2019-05-27 16:35:22 +09:00
Xiao Ma
555e408928 Wipe the data in IpMemoryStore database upon network factory reset.
Bug:128499160
Test: manual
Test: atest FrameworksNetTests NetworkStackTests
Change-Id: Ib563463a861a5d27b1e9b5fbb92342249b573802
2019-05-27 15:05:09 +09:00
Chiachang Wang
1be379bbb4 Clean up for multiple validation result update
This is a follow-up commit for aosp/955431 to update commets
and minor updates in unit test.

Test: atest com.android.server.ConnectivityServiceTest#testCaptivePortalOnPartialConnectivity
Bug: 130683832
Change-Id: I581eae8daeddd2c4c186e7b40e27fef2aaa7ab43
Merged-In: I9087ef791b3fee5399ba8e83ef9d8a544845a4dd
Merged-In: I4424663292c5ad29eb7a888fa6975835721a5d2e
(cherry picked from commit 3d3a9fff7b7fa0df4ee627cb082668e642d6f754)
2019-05-27 00:54:53 +00:00
Chiachang Wang
807fa67f75 Merge "Clean up for multiple validation result update" am: 7a5b9c2d0a am: 0d018cdaec
am: 9ec2c725c8

Change-Id: Ia9dc0f944d6f7aa146124b6899832e27cd530950
2019-05-25 03:09:42 -07:00
Chiachang Wang
9ec2c725c8 Merge "Clean up for multiple validation result update" am: 7a5b9c2d0a
am: 0d018cdaec

Change-Id: I4424663292c5ad29eb7a888fa6975835721a5d2e
2019-05-25 02:53:44 -07:00
Android Build Merger (Role)
e188af49a9 Merge "[automerger skipped] Merge "Update multiple validation result to ConnectivityService" into qt-dev am: 399b7500af -s ours am: fcf0ced706 -s ours am skip reason: change_id I243db4c406cca826e803c8035268bc0c6e6e01e2 with SHA1 2c593ec776 is in history" into qt-r1-dev-plus-aosp 2019-05-25 05:38:36 +00:00
Chiachang Wang
85885358e2 [automerger skipped] Merge "Update multiple validation result to ConnectivityService" into qt-dev am: 399b7500af -s ours
am: fcf0ced706 -s ours
am skip reason: change_id I243db4c406cca826e803c8035268bc0c6e6e01e2 with SHA1 2c593ec776 is in history

Change-Id: I5ddb5d0d856960d226d41ca561d665be1accd4d2
2019-05-24 22:37:54 -07:00
Chiachang Wang
7b5d4c2fae [automerger skipped] Merge "Update multiple validation result to ConnectivityService" into qt-dev am: 399b7500af
am: ff9340a1b0 -s ours
am skip reason: change_id I243db4c406cca826e803c8035268bc0c6e6e01e2 with SHA1 2c593ec776 is in history

Change-Id: Ic0b0150bb5c5ddcaeff17b27f454d96b795892ca
2019-05-24 22:34:22 -07:00
Chiachang Wang
fcf0ced706 [automerger skipped] Merge "Update multiple validation result to ConnectivityService" into qt-dev
am: 399b7500af -s ours
am skip reason: change_id I243db4c406cca826e803c8035268bc0c6e6e01e2 with SHA1 2c593ec776 is in history

Change-Id: I09ce684da6680c5c20de4e3f0a7cf741f85131ec
2019-05-24 22:01:20 -07:00
Chiachang Wang
0a10069a9a Merge "Update multiple validation result to ConnectivityService" am: 5af07137d7 am: a0e9af113c
am: 2c593ec776

Change-Id: I3bb06a758571bc1dcf2ccf683db391c742f7a5b5
2019-05-24 01:50:11 -07:00
Chenbo Feng
6879cc6bc1 [automerger skipped] Merge "Fix the internet permission for native services" into qt-dev am: 2e17b24023 -s ours
am: 6e300a80fb -s ours
am skip reason: change_id I84cde7d3757953bc0bf761727d64a715bcdd68bb with SHA1 99869f413a is in history

Change-Id: I810ad402c4bef38fe1f2c7dcb0e0ab543d81b69b
2019-05-24 01:32:47 -07:00
Etan Cohen
37eb1e4f65 [automerger skipped] Merge changes from topic "on_unavailable_fix" into qt-dev am: 285b665784 -s ours
am: d954300cb5 -s ours
am skip reason: change_id Ia2cc04b42288ea987483e5ab0e0a10093dc49502 with SHA1 c8289e40a4 is in history

Change-Id: I304be543fe4f0323804da4da0b4b68c63942a264
2019-05-23 23:22:31 -07:00
Chiachang Wang
dc07f26256 Update multiple validation result to ConnectivityService
Once a network is determined to have partial connectivity, it
cannot go back to full connectivity without a disconnect. This
is because NetworkMonitor can only communicate either
PARTIAL_CONNECTIVITY or VALID, but not both. Thus, multiple
validation results allow ConnectivityService to know the real
network status.

Bug: 129662877
Bug: 130683832
Test: atest FrameworksNetTests
Test: atest NetworkStackTests
Test: atest --generate-new-metrics 50
NetworkStackTests:com.android.server.connectivity.NetworkMonitorTest
Test: Simulate partial connectvitiy
Change-Id: I406c9368617c03a2dd3ab15fb1f6dbf539d7c714
Merged-In: I243db4c406cca826e803c8035268bc0c6e6e01e2
(cherry picked from commit 4532abd4d2af9ad118873a63cafc6028ed87c52e)
2019-05-24 06:15:25 +00:00
Chiachang Wang
2c593ec776 Merge "Update multiple validation result to ConnectivityService" am: 5af07137d7
am: a0e9af113c

Change-Id: I243db4c406cca826e803c8035268bc0c6e6e01e2
2019-05-23 22:57:18 -07:00
Chenbo Feng
073dcff305 [automerger skipped] Merge "Fix the internet permission for native services" into qt-dev am: 2e17b24023
am: f68f9d9f36 -s ours
am skip reason: change_id I84cde7d3757953bc0bf761727d64a715bcdd68bb with SHA1 99869f413a is in history

Change-Id: Ie09912db7602806b34700fb6553334413f9aafc0
2019-05-23 22:15:34 -07:00
Chiachang Wang
b8d3727aa1 Clean up for multiple validation result update
This is a follow-up commit for aosp/955431 to update commets
and minor updates in unit test.

Test: atest com.android.server.ConnectivityServiceTest#testCaptivePortalOnPartialConnectivity
Bug: 130683832
Change-Id: I581eae8daeddd2c4c186e7b40e27fef2aaa7ab43
2019-05-24 03:29:56 +00:00
Chenbo Feng
6e300a80fb [automerger skipped] Merge "Fix the internet permission for native services" into qt-dev
am: 2e17b24023 -s ours
am skip reason: change_id I84cde7d3757953bc0bf761727d64a715bcdd68bb with SHA1 99869f413a is in history

Change-Id: I5cdb1fd2821c1cee229ca541c8ab02da66d9f474
2019-05-23 20:14:37 -07:00
Chiachang Wang
5af07137d7 Merge "Update multiple validation result to ConnectivityService" 2019-05-24 02:50:54 +00:00
Etan Cohen
d954300cb5 [automerger skipped] Merge changes from topic "on_unavailable_fix" into qt-dev
am: 285b665784 -s ours
am skip reason: change_id Ia2cc04b42288ea987483e5ab0e0a10093dc49502 with SHA1 cc65a628eb is in history

Change-Id: Iddb2d6487a118102eeeedd03c876cd4ec137427e
2019-05-23 18:23:32 -07:00
TreeHugger Robot
2e17b24023 Merge "Fix the internet permission for native services" into qt-dev 2019-05-24 01:18:19 +00:00
Chenbo Feng
8b9a2f571b Merge "Fix the internet permission for native services" am: dcc6ebb96f am: 5d4822bcd2
am: d053460495

Change-Id: I7f22aafe3b35f24e68fff85723aaceb4a0444af5
2019-05-23 17:22:39 -07:00
Etan Cohen
1dc7494bbb [automerger skipped] Merge changes from topic "on_unavailable_fix" into qt-dev am: 285b665784
am: 9c1c1c03ff -s ours
am skip reason: change_id Ia2cc04b42288ea987483e5ab0e0a10093dc49502 with SHA1 cc65a628eb is in history

Change-Id: I356601b3d10f4b3fdbe7fcf3e46762715a7cc86a
2019-05-23 16:14:59 -07:00
Chenbo Feng
d053460495 Merge "Fix the internet permission for native services" am: dcc6ebb96f
am: 5d4822bcd2

Change-Id: I795bc87ad6cba7c40974136ca3b122540679c684
2019-05-23 13:51:43 -07:00
Chenbo Feng
158ac5a39e Fix the internet permission for native services
The native services should specify their permissions in platform.xml if
they need internet permission, otherwise the eBPF program will block the
socket creation request. Fixing the known services that are in group
AID_INET but didn't specify their permission in the xml file.

Bug: 132217906
Test: CtsJdwpTestCases dumpsys netd trafficcontroller
Change-Id: I84cde7d3757953bc0bf761727d64a715bcdd68bb
Merged-In: I84cde7d3757953bc0bf761727d64a715bcdd68bb
(cherry picked from commit e5d6f0fa6c3fd77572f5b29f416acbf304abf9da)
2019-05-23 11:54:49 -07:00
Treehugger Robot
dcc6ebb96f Merge "Fix the internet permission for native services" 2019-05-23 18:40:42 +00:00
Etan Cohen
566a97bc7a Merge "[CM] Fix NPE due to unvalidated callback value" am: 62790fbdfe am: cc65a628eb
am: a255662062

Change-Id: Iecfa40fe34c2054d58a9e8239b855c1a831764c0
2019-05-23 10:31:44 -07:00
Etan Cohen
a255662062 Merge "[CM] Fix NPE due to unvalidated callback value" am: 62790fbdfe
am: cc65a628eb

Change-Id: I5a6e2e92852f76251e8c1bfcd3c06c6773ec1fe4
2019-05-23 09:42:00 -07:00
Etan Cohen
c8289e40a4 [CM] Fix NPE due to unvalidated callback value
Fix flaky test resulting from the above fix.

Bug: 132950880
Test: atest ConnectivityServiceTest
Merged-In: Ia2cc04b42288ea987483e5ab0e0a10093dc49502
Change-Id: Ia2cc04b42288ea987483e5ab0e0a10093dc49502
(cherry picked from commit cc65a628eb1172dc7b942d7f51b702099c15c23b)
2019-05-23 16:23:13 +00:00
Etan Cohen
0da57a8b67 [CM] Fix NPE due to unvalidated callback value
When unregistering callback due to ON_UNAVAILABLE did not check for
a non-null callback.

Bug: 132950880
Test: atest ConnectivityServiceTest
Merged-In: Ib3fde31d88c36469cdee1e3578606d130a9817cb
Change-Id: Ib3fde31d88c36469cdee1e3578606d130a9817cb
(cherry picked from commit 51ddc176abd23bd3ddbc26124e5541a983a1db07)
2019-05-23 16:20:15 +00:00
Etan Cohen
62790fbdfe Merge "[CM] Fix NPE due to unvalidated callback value" 2019-05-23 16:01:51 +00:00
Luke Huang
e9d9026ec2 Merge "Add Rfc6724 style sort for DnsResolver and fix potential bug" am: 7a1133eb44 am: d352f4ca85
am: 387e63d68b

Change-Id: I913b31586d15c24d1535e8d7cd0b158c25892286
2019-05-23 08:55:06 -07:00
Etan Cohen
1f1bcb0b68 [CM] Fix NPE due to unvalidated callback value
Fix flaky test resulting from the above fix.

Bug: 132950880
Test: atest ConnectivityServiceTest
Change-Id: I1ddf3bb016239bf88cdd8843a71dcb5e582e83ac
2019-05-23 08:16:20 -07:00
Luke Huang
51b9f6c069 Add Rfc6724 style sort for DnsResolver and fix potential bug
1. pass default network explicitly to fix potential
   mis-sync network problem in DnsResolver#query
2. Add rfc6724 sort and related test
3. DnsResolver do rfc6724 sort before response InetAddress answers
4. move haveIpv* function from DnsResolver to DnsUtils

Bug: 129530368
Test: atest DnsResolverTest DnsUtilsTest

Merged-In: I0323f5c7f32fc3fa589b9e87f8e7c9caf744dbd4
(cherry picked from commit d352f4ca85ff8418a5a58d32fb03b85d7e0b843b)

Change-Id: I98455045fa43cc5a5902a08232251c1734feaac3
2019-05-23 14:36:21 +00:00
Remi NGUYEN VAN
671a0df6d6 [automerger skipped] Merge "Properly use versioned interfaces." into qt-dev am: efc774b76c -s ours
am: be092469ac -s ours
am skip reason: change_id Idf49e840263ef32b9ee4fafa6718d4f893ea7c87 with SHA1 91ddb23d66 is in history

Change-Id: I6b541348f904d737cc79fb1b6e1c1bbc54b5e184
2019-05-23 07:35:00 -07:00