Commit Graph

3218 Commits

Author SHA1 Message Date
Treehugger Robot
acb4e9fc59 Merge "Add shared jarjar rule for tethering tests" am: d75774dfe0 am: 2dc283eeca am: bdca380803 am: 6e654cd7cd
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1473223

Change-Id: I24795bc612d7956ea8f2776c90810ea5c5eca39e
2020-10-26 13:22:26 +00:00
Treehugger Robot
6e654cd7cd Merge "Add shared jarjar rule for tethering tests" am: d75774dfe0 am: 2dc283eeca am: bdca380803
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1473223

Change-Id: Ie1e828e976b798c65df688b2ce43f60fc07d633b
2020-10-26 12:57:09 +00:00
Treehugger Robot
bdca380803 Merge "Add shared jarjar rule for tethering tests" am: d75774dfe0 am: 2dc283eeca
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1473223

Change-Id: I34c41fbbe5f034a2ed332c784ab0decb2c6b2add
2020-10-26 12:40:34 +00:00
Treehugger Robot
d75774dfe0 Merge "Add shared jarjar rule for tethering tests" 2020-10-26 11:43:59 +00:00
markchien
e3126480ba Add shared jarjar rule for tethering tests
Also jarjar com.android.net.module.util* to
com.android.networkstack.tethering.util*.

Bug: 171670016
Test: atest TetheringCoverageTests
Change-Id: I3bde9ad3c41adf36da99bd944303d88ce992201c
2020-10-26 18:20:25 +08:00
Treehugger Robot
0de5fc06aa [automerger skipped] Merge "Import translations. DO NOT MERGE ANYWHERE" am: b7dc979577 -s ours am: fba69cad44 -s ours am: 30bc6bf3d0 -s ours am: 6e766a7728 -s ours
am skip reason: subject contains skip directive

Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1470260

Change-Id: I3f77259fb8f6b746e06441c9ddd075a3f8b745fc
2020-10-23 21:17:59 +00:00
Treehugger Robot
6e766a7728 [automerger skipped] Merge "Import translations. DO NOT MERGE ANYWHERE" am: b7dc979577 -s ours am: fba69cad44 -s ours am: 30bc6bf3d0 -s ours
am skip reason: subject contains skip directive

Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1470260

Change-Id: I79e5efb3a72153fdf1cf7ae5e6ab84e3e10bec3f
2020-10-23 21:02:47 +00:00
Treehugger Robot
30bc6bf3d0 [automerger skipped] Merge "Import translations. DO NOT MERGE ANYWHERE" am: b7dc979577 -s ours am: fba69cad44 -s ours
am skip reason: subject contains skip directive

Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1470260

Change-Id: I668a3b52ea71aa484a8a56f4835764a778398324
2020-10-23 20:24:05 +00:00
Bill Yi
479e5b17ef Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: I34e8bcf3c3f0a5db3522b6ff499ba1583577b250
2020-10-22 23:40:39 -07:00
Mark Chien
ae83d10c32 Merge "Bump Tethering apex version code" into rvc-d1-dev-plus-aosp am: 491463a35f am: b68c8bf414
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12890938

Change-Id: I9bf34252d723acb513935596e93ab8d748187041
2020-10-23 04:13:50 +00:00
Mark Chien
b68c8bf414 Merge "Bump Tethering apex version code" into rvc-d1-dev-plus-aosp am: 491463a35f
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12890938

Change-Id: I5770c27e0078a71b8e41ea4915b5f7439f45e8a2
2020-10-23 03:49:21 +00:00
markchien
0582605da7 Bump Tethering apex version code
The version code in the manifest is only used for development
builds, as release builds dynamically replace it.

Bug: 170183552
Test: m
Change-Id: I51916756f41672d372e3a4adce3a8edf5d472c0d
2020-10-22 06:49:24 +00:00
markchien
7896ebd443 [automerger skipped] Add the flag and default enable selectAllPrefixRange am: 29e047778a -s ours
am skip reason: Change-Id I434dda81eb5fab700d873a8ff3429b4222f0c7e6 with SHA-1 4607c5535b is in history

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12872219

Change-Id: Ifd87c881607d3cd38700782a41613a40504d1b6b
2020-10-19 14:30:31 +00:00
Mark Chien
d1c31a2c11 Merge "Add the flag and default enable selectAllPrefixRange" am: 02fe8ac161 am: d11a25eb56 am: a1468b6591 am: c43f48d6cb
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1461742

Change-Id: I232a3a52daeed69230215f3be135881415dbdb5c
2020-10-19 13:33:30 +00:00
Mark Chien
c43f48d6cb Merge "Add the flag and default enable selectAllPrefixRange" am: 02fe8ac161 am: d11a25eb56 am: a1468b6591
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1461742

Change-Id: Iedffd6305dcd8dd73236ac086078dbde1ff92899
2020-10-19 13:20:42 +00:00
Mark Chien
a1468b6591 Merge "Add the flag and default enable selectAllPrefixRange" am: 02fe8ac161 am: d11a25eb56
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1461742

Change-Id: Ic540b8b0c562a730d4da307aa6890226099e9b46
2020-10-19 13:04:37 +00:00
Mark Chien
d11a25eb56 Merge "Add the flag and default enable selectAllPrefixRange" am: 02fe8ac161
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1461742

Change-Id: I6055ea6ac737bb94bd9bc8c8642e86222f1e1d1a
2020-10-19 12:46:44 +00:00
markchien
29e047778a Add the flag and default enable selectAllPrefixRange
Also add MtsTetheringTest which only run if tethering mainline
module is installed.

Bug: 166057846
Bug: 170265597
Test: atest TetheringTests
Change-Id: I434dda81eb5fab700d873a8ff3429b4222f0c7e6
Merged-In: I434dda81eb5fab700d873a8ff3429b4222f0c7e6
2020-10-19 19:15:18 +08:00
markchien
4607c5535b Add the flag and default enable selectAllPrefixRange
Also add MtsTetheringTest which only run if tethering mainline
module is installed.

Bug: 166057846
Bug: 170265597
Test: atest TetheringTests
Change-Id: I434dda81eb5fab700d873a8ff3429b4222f0c7e6
2020-10-19 16:50:29 +08:00
TreeHugger Robot
f8cb12ea14 [automerger skipped] Merge "Fix miss tracking downstream problem in PrivateAddressCoordinator" into mainline-prod am: f1ad3b3416 -s ours
am skip reason: Change-Id Ide5206b013acdc499344e1c839a830c5b245af41 with SHA-1 634f0a8ec1 is in history

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12847482

Change-Id: I5d3c5a119bceb600049025a4f5c9e5517c633c97
2020-10-16 05:44:55 +00:00
TreeHugger Robot
e75adeb0ff [automerger skipped] Merge "Test conflict notification work when using cached address" into mainline-prod am: b2c2e72be7 -s ours
am skip reason: Change-Id Id0c1afb5563954ffee1f598a3a5de6a245d77a0e with SHA-1 ccf07b1dd6 is in history

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12847481

Change-Id: Ieda918e1cce7696c4523b4829ea7dd78d407aa82
2020-10-16 02:54:25 +00:00
Mark Chien
2bafaf0dfe Fix miss tracking downstream problem in PrivateAddressCoordinator
The downstream do not be tracked if PrivateAddressCoordinator just
return cached address. Then, PrivateAddressCoordinator would not notify
that downstream if conflict happen.

Also remove the null check in getDownstreamPrefix because:
- An IpServer is only added to mDownstreams by requestDownstreamAddress.
- That method will only add the IpServer to mDownstreams if it has an
IPv4 address.
- As soon as that method returns, the IpServer sets mIpv4Address to the
address that was returned.
- When an IpServer is torn down, mIpv4Address is set to null after
releaseDownstream is called.

So it should never be possible for this to return null.

Bug: 168169687
Test: atest CtsTetheringTest
      atest TetheringTests

Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1459887

Change-Id: I4b4d75c8a4f1de07aa7bb68b12d150d7c85c9cc1
Merged-In: Ide5206b013acdc499344e1c839a830c5b245af41
(cherry picked from commit 0854becd64)
2020-10-15 15:39:03 +00:00
Treehugger Robot
55be5eee64 Test conflict notification work when using cached address
This test catch the regression introduced in r.android.com/1432958.

Bug: 1432958
Test: atest TetheringTest
Change-Id: Id0c1afb5563954ffee1f598a3a5de6a245d77a0e

Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1459889

Change-Id: Ie80d4d5d535d70df493cad0a80166d779bc6ab77
Merged-In: Id0c1afb5563954ffee1f598a3a5de6a245d77a0e
(cherry picked from commit c46006da45)
2020-10-15 15:36:21 +00:00
Mark Chien
3910988c18 Merge "Fix miss tracking downstream problem in PrivateAddressCoordinator" am: 8565b0244a am: a5b9e4a1b4 am: 7c1badf9b0 am: 0854becd64
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1459887

Change-Id: I9262e13e3f3919c2b36bb8765a09c4abf2e31aa4
2020-10-15 14:20:00 +00:00
Mark Chien
0854becd64 Merge "Fix miss tracking downstream problem in PrivateAddressCoordinator" am: 8565b0244a am: a5b9e4a1b4 am: 7c1badf9b0
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1459887

Change-Id: I4b4d75c8a4f1de07aa7bb68b12d150d7c85c9cc1
2020-10-15 13:49:16 +00:00
Mark Chien
7c1badf9b0 Merge "Fix miss tracking downstream problem in PrivateAddressCoordinator" am: 8565b0244a am: a5b9e4a1b4
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1459887

Change-Id: I33842982a1a94a37d2e8b7aa78f5bc9b6e86326e
2020-10-15 13:16:01 +00:00
Mark Chien
a5b9e4a1b4 Merge "Fix miss tracking downstream problem in PrivateAddressCoordinator" am: 8565b0244a
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1459887

Change-Id: I2874508c560cc31f99e88c02fd63995f62f86a2f
2020-10-15 12:46:39 +00:00
Anton Hansson
1df3db2dfc [automerger skipped] Merge "Remove Tethering @TestApi" am: bd175573a5 am: 67f88535d1 am: 96a954a8d6 am: f3b20fff0e -s ours
am skip reason: Change-Id I6e2c8298e90b4b54f0264be974d036fa08cd5632 with SHA-1 f8f8967d0e is in history

Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1460522

Change-Id: Ie918c3443f454be3b481ed4899baee3c126c71b4
2020-10-15 12:40:31 +00:00
Mark Chien
8565b0244a Merge "Fix miss tracking downstream problem in PrivateAddressCoordinator" 2020-10-15 12:07:19 +00:00
Anton Hansson
f3b20fff0e Merge "Remove Tethering @TestApi" am: bd175573a5 am: 67f88535d1 am: 96a954a8d6
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1460522

Change-Id: I53a8acb3de1550281a6feb15ebfb07c73cef072c
2020-10-15 11:47:59 +00:00
Anton Hansson
96a954a8d6 Merge "Remove Tethering @TestApi" am: bd175573a5 am: 67f88535d1
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1460522

Change-Id: I6d44cc10ae75426e715c95540f64e788b506f83b
2020-10-15 11:29:19 +00:00
Anton Hansson
67f88535d1 Merge "Remove Tethering @TestApi" am: bd175573a5
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1460522

Change-Id: I3dcf776384d6c53876acaeb344820a88c19027da
2020-10-15 11:11:02 +00:00
Anton Hansson
9dfd9a13fc [automerger skipped] Merge "Remove Tethering @TestApi" into mainline-prod am: eccc277066 -s ours
am skip reason: Change-Id I6e2c8298e90b4b54f0264be974d036fa08cd5632 with SHA-1 44b2ebcf34 is in history

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12836355

Change-Id: I1431227440105d36d6f6f79e6fadad84bad518d0
2020-10-15 10:53:46 +00:00
Anton Hansson
eccc277066 Merge "Remove Tethering @TestApi" into mainline-prod 2020-10-15 10:05:16 +00:00
markchien
634f0a8ec1 Fix miss tracking downstream problem in PrivateAddressCoordinator
The downstream do not be tracked if PrivateAddressCoordinator just
return cached address. Then, PrivateAddressCoordinator would not notify
that downstream if conflict happen.

Also remove the null check in getDownstreamPrefix because:
- An IpServer is only added to mDownstreams by requestDownstreamAddress.
- That method will only add the IpServer to mDownstreams if it has an
IPv4 address.
- As soon as that method returns, the IpServer sets mIpv4Address to the
address that was returned.
- When an IpServer is torn down, mIpv4Address is set to null after
releaseDownstream is called.

So it should never be possible for this to return null.

Bug: 168169687
Test: atest CtsTetheringTest
      atest TetheringTests
Change-Id: Ide5206b013acdc499344e1c839a830c5b245af41
2020-10-15 16:21:12 +08:00
Anton Hansson
f8f8967d0e Remove Tethering @TestApi
Modules shouldn't have TestApis, as documented in go/android-api-types.
Additionally, nothing depends on these TestApis existing.

Bug: 170395679
Test: m checkapi
Change-Id: I6e2c8298e90b4b54f0264be974d036fa08cd5632
Merged-In: I6e2c8298e90b4b54f0264be974d036fa08cd5632
2020-10-15 07:55:00 +00:00
Anton Hansson
b66b46f933 Merge "Remove Tethering @TestApi" 2020-10-15 07:43:03 +00:00
Anton Hansson
44b2ebcf34 Remove Tethering @TestApi
Modules shouldn't have TestApis, as documented in go/android-api-types.
Additionally, nothing depends on these TestApis existing.

Bug: 170395679
Test: m checkapi
Exempt-From-Owner-Approval: cherry-pick
Change-Id: I6e2c8298e90b4b54f0264be974d036fa08cd5632
2020-10-15 07:42:41 +00:00
Treehugger Robot
58a7a933ba Merge "Test conflict notification work when using cached address" am: 32456142c0 am: eea93bf6ed am: 70ba3b2c8b am: c46006da45
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1459889

Change-Id: I237e8e8c4b83d12be2dfce30919dc71b3c16656c
2020-10-14 15:14:05 +00:00
Anton Hansson
87b8363cb9 Remove Tethering @TestApi
Modules shouldn't have TestApis, as documented in go/android-api-types.
Additionally, nothing depends on these TestApis existing.

Bug: 170395679
Test: m checkapi
Change-Id: I6e2c8298e90b4b54f0264be974d036fa08cd5632
Merged-In: I6e2c8298e90b4b54f0264be974d036fa08cd5632
2020-10-14 16:03:57 +01:00
Treehugger Robot
c46006da45 Merge "Test conflict notification work when using cached address" am: 32456142c0 am: eea93bf6ed am: 70ba3b2c8b
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1459889

Change-Id: Ie80d4d5d535d70df493cad0a80166d779bc6ab77
2020-10-14 14:49:18 +00:00
Treehugger Robot
70ba3b2c8b Merge "Test conflict notification work when using cached address" am: 32456142c0 am: eea93bf6ed
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1459889

Change-Id: I3f7f1fe42ed92147e5809d48ae5f38745fd71689
2020-10-14 14:34:43 +00:00
Treehugger Robot
eea93bf6ed Merge "Test conflict notification work when using cached address" am: 32456142c0
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1459889

Change-Id: Ib9be992d5728346f063cea6ebc67b11a209e04c4
2020-10-14 13:34:06 +00:00
Treehugger Robot
32456142c0 Merge "Test conflict notification work when using cached address" 2020-10-14 13:18:58 +00:00
markchien
ccf07b1dd6 Test conflict notification work when using cached address
This test catch the regression introduced in r.android.com/1432958.

Bug: 1432958
Test: atest TetheringTest

Change-Id: Id0c1afb5563954ffee1f598a3a5de6a245d77a0e
2020-10-14 17:02:29 +08:00
Mark Chien
c8dded9d5f [automerger skipped] Allow tethering pick prefix from all of private address range am: 188bbe712d -s ours
am skip reason: Change-Id Ib6304eb8b4788e9196d0af48e72f00a6bda73a5f with SHA-1 d9acdccbd3 is in history

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12825260

Change-Id: Ic6adf974d9628e64a5ea41b616df1300d1d9fd0a
2020-10-13 16:29:03 +00:00
Mark Chien
2833425097 Merge "Allow tethering pick prefix from all of private address range" am: 8c9a2645d8 am: 4388f63021 am: e2a905116c am: 6f601a0374
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1436852

Change-Id: I849f7d336fd4bc7d39d8b268620bcb25dbd26667
2020-10-13 14:58:33 +00:00
Mark Chien
6f601a0374 Merge "Allow tethering pick prefix from all of private address range" am: 8c9a2645d8 am: 4388f63021 am: e2a905116c
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1436852

Change-Id: If37b6cdeb9d5573d1a6edc960bfc2a0a7404f73c
2020-10-13 14:30:17 +00:00
Mark Chien
e2a905116c Merge "Allow tethering pick prefix from all of private address range" am: 8c9a2645d8 am: 4388f63021
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1436852

Change-Id: Ie44f3b2ebfa51d2c915bd794b6ea0fade0098ecf
2020-10-13 14:01:47 +00:00
Mark Chien
188bbe712d Allow tethering pick prefix from all of private address range
Currently tethering only pick prefix from 192.168.0.0/16. There is no
aviable tethering address if the upstream address is 192.168.x.y/16.
This change allow tethering to pick prefix from any private address
rnages. Now it still pick from 192.168.0.0/16 only to avoid behavior
change. Will have follow up commit to change the configuration.

Bug: 166057846
Bug: 170265597
Test: atest TetheringTests
      atest CtsTetheringTest

Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1436852

Change-Id: I008d5e5902a0fb41ac564c73f265e1c942c8dcad
Merged-In: Ib6304eb8b4788e9196d0af48e72f00a6bda73a5f
(cherry picked from commit 0a6b8bfee818734c005d9f131013580f5a23ba21)
2020-10-13 13:48:54 +00:00