Commit graph android_packages_modules_Co.../Tethering
Message SHA1
Merge "[TNU05.1] Address aosp/1237036 leftover comments" am: 14fb7f6fac am: a91e5e5da6
Change-Id: I56a0ce98beed6797486e26a5148ee3685a3ae0ef

Paul Hu   authored and   Automerger Merge Worker   commited 2020-04-16 09:04:57 +00:00
eef15b96ac
Merge "[TNU05.1] Address aosp/1237036 leftover comments"
Paul Hu   authored and   Gerrit Code Review   commited 2020-04-16 08:25:24 +00:00
14fb7f6fac
[TNU05.1] Address aosp/1237036 leftover comments
Bug: 147818698
Test: atest TetheringTests
Change-Id: Ife738339aeae00d2063fea6918b50204daef24fc

paulhu   commited 2020-04-16 14:39:12 +08:00
1317e27e91
Merge "Add TetheringCoverageTests"
Paul Hu   authored and   Gerrit Code Review   commited 2020-04-16 06:00:07 +00:00
baf4513d45
Merge "Remove sendMessage inside EntitlementManager" am: b4624df935 am: 2acc78a6a9
Change-Id: Ia582129af14366051e81f3d5b77cb018f453a2ee

Mark Chien   authored and   Automerger Merge Worker   commited 2020-04-16 02:47:22 +00:00
d8a80a418d
Merge "Remove sendMessage inside EntitlementManager"
Mark Chien   authored and   Gerrit Code Review   commited 2020-04-16 02:07:55 +00:00
b4624df935
Merge "[TNU05] Add no upstream notification" am: b353c7eac3 am: 7cda806393
Change-Id: Ib65eeed784189e669cc5c22537671deb8d35a9e5

Paul Hu   authored and   Automerger Merge Worker   commited 2020-04-16 01:59:03 +00:00
7c789f41eb
Merge "[TNU05] Add no upstream notification"
Paul Hu   authored and   Gerrit Code Review   commited 2020-04-16 01:31:06 +00:00
b353c7eac3
DO NOT MERGE Remove references of telephony-stubs.
Since it's not used for now.

Test: TH
Bug: 153304048
Change-Id: I1812818c3d49463c3840a98212bbab58a110359a

Amit Mahajan   commited 2020-04-15 14:38:58 -07:00
69f3fa3729
Merge "Do not stop IpServer when recieve wifi ap disabling state." am: 197e35198d am: 7018843a2e
Change-Id: Ia0e60d2e72e2fe94ea14e30cb80a4c24e9b7b75c

Mark Chien   authored and   Automerger Merge Worker   commited 2020-04-15 17:28:27 +00:00
b90f7a5c5c
Remove sendMessage inside EntitlementManager
EntitlementManager and its callers(Tethering and UpstreamNetworkMonitor)
run in the same threads.

Bug: 141256482
Test: atest TetheringTests
Change-Id: I0a376d28b123eaab2e8d00a98a4719ce983d3bb2

markchien   authored and   Mark Chien   commited 2020-04-15 02:29:21 +00:00
a1a0be93f0
Add TetheringCoverageTests
Bug: 148636687
Test: atest TetheringCoverageTests
      atest TetheringTests
      atest TetheringIntegrationTests
      atest NetworkStackTests
      atest CtsTetheringTest
Change-Id: I1f2a50f16894b05e988476520ba25baba0b60d88
Merged-In: I1f2a50f16894b05e988476520ba25baba0b60d88

paulhu   authored and   Paul Hu   commited 2020-04-15 00:50:01 +00:00
64632657a2
[TNU05] Add no upstream notification
Reminder user of unavailable tethering status if there is no
internet access.

Bug: 147818698
Test: atest TetheringTests
Change-Id: Ic6557f9f7703337596100cd6a477fd7239217166

paulhu   commited 2020-04-15 01:25:37 +08:00
648fc2c8ea
Add TetheringCoverageTests
Bug: 148636687
Test: atest TetheringCoverageTests
      atest TetheringTests
      atest TetheringIntegrationTests
      atest NetworkStackTests
      atest CtsTetheringTest
Change-Id: I1f2a50f16894b05e988476520ba25baba0b60d88

paulhu   authored and   Paul Hu   commited 2020-04-14 14:14:33 +00:00
d1ebb1e348
Merge "Update tethering notification strings" into rvc-dev
Paul Hu   authored and   Android (Google) Code Review   commited 2020-04-14 14:07:19 +00:00
13113c4502
Update tethering notification strings
Update strings after converged with carrier.

Bug: 145629001
Bug: 147818698
Test: atests TetheringTests
Change-Id: I8ad34e8c93ba1547aa397a8e9c0ecc15286a2b0b
Merged-In: I8ad34e8c93ba1547aa397a8e9c0ecc15286a2b0b
(cherry picked from commit d4a1bd7b73991c4197b49a3ff36e7683273ae736, aosp/1284584)

Paul Hu   commited 2020-04-14 11:18:09 +00:00
8fae1ba057
Do not stop IpServer when recieve wifi ap disabling state.
This is used to fix the race when quickly OFF/ON wifi tethering.
When IpServer is started/stopped, there is callback update tethering
interface status. Before this change, IpServer is stopped when wifi
ap is disabling. Then the next startTethering may fail in wifi because
wifi is in disabling state.
Error pattern: WifiService: Tethering is already active.
No unitest for this CL but it fixed the CtsTetheringTest flakty rate
than around 30% to 0 for more than 100 runs.

Bug: 153925821
Test: atest CtsTetheringTest --iteration 100
Change-Id: I8b65f621abe20799a3a0d410ba1f06368746ee49

markchien   authored and   Mark Chien   commited 2020-04-14 10:42:32 +00:00
bdf1003c3b
Don't crash when receiving an RTM_DELNEIGH or NUD_FAILED.
These events don't have MAC addresses, so the code attempts to
create an Ipv6ForwardingRule with a null MAC address. This
crashes when attempting to get the raw MAC address bytes to send
to netd in the TetherOffloadRuleParcel.

This was not caught by unit tests because the test exercise this
code path in a way that is not correct (by sending RTM_DELNEIGH
and NUD_FAILED events with MAC addresses). Fix the unit tests to
properly pass in null MAC addresses for these events.

Bug: 153697068
Test: fixed existing tests to be more realistic
Merged-In: I26d89a81f1c448d9b4809652b079a5f5eace3924
Change-Id: I26d89a81f1c448d9b4809652b079a5f5eace3924

Lorenzo Colitti   commited 2020-04-14 09:55:17 +00:00
6f532ba30f
Merge "Don't crash when receiving an RTM_DELNEIGH or NUD_FAILED."
Lorenzo Colitti   authored and   Gerrit Code Review   commited 2020-04-14 08:22:30 +00:00
941a53ce91
Merge "Update tethering notification strings"
Paul Hu   authored and   Gerrit Code Review   commited 2020-04-14 07:15:16 +00:00
6f6527e2d7
Change tethering file structure to respect its package name
Bug: 145099347
Test: atest TetheringTests
      atest CtsTetheringTest
Change-Id: I7401c550fbafd17a5ed2d925b5d0e17e358af467
Merged-In: I7401c550fbafd17a5ed2d925b5d0e17e358af467

markchien   commited 2020-04-14 14:33:45 +08:00
7dc2dcc37a
Don't crash when receiving an RTM_DELNEIGH or NUD_FAILED.
These events don't have MAC addresses, so the code attempts to
create an Ipv6ForwardingRule with a null MAC address. This
crashes when attempting to get the raw MAC address bytes to send
to netd in the TetherOffloadRuleParcel.

This was not caught by unit tests because the test exercise this
code path in a way that is not correct (by sending RTM_DELNEIGH
and NUD_FAILED events with MAC addresses). Fix the unit tests to
properly pass in null MAC addresses for these events.

Bug: 153697068
Test: fixed existing tests to be more realistic
Change-Id: I26d89a81f1c448d9b4809652b079a5f5eace3924

Lorenzo Colitti   commited 2020-04-14 15:02:17 +09:00
330a9b9fa7
Change tethering file structure to respect its package name
Bug: 145099347
Test: atest TetheringTests
      atest CtsTetheringTest
Change-Id: I7401c550fbafd17a5ed2d925b5d0e17e358af467

markchien   authored and   Mark Chien   commited 2020-04-14 02:09:51 +00:00
d995566700
Tethering: Add an exported flag in manifest
With b/150232615, we will need an explicit value set for the exported
flag when intent filters are present, as the default behavior is
changing for S+. This change adds the value reflecting the previous
default to the manifest.

Bug: 150232615
Test: TH
Change-Id: I25b55378df393cd4fb8932b7ae64f97eb9f1aa8e
Merged-In: I25b55378df393cd4fb8932b7ae64f97eb9f1aa8e
(cherry picked from commit dc03d15189)

Ashwini Oruganti   authored and   markchien   commited 2020-04-14 00:08:24 +08:00
910a0b44dd
Tethering: Add an exported flag in manifest
With b/150232615, we will need an explicit value set for the exported
flag when intent filters are present, as the default behavior is
changing for S+. This change adds the value reflecting the previous
default to the manifest.

Bug: 150232615
Test: TH
Change-Id: I25b55378df393cd4fb8932b7ae64f97eb9f1aa8e
Merged-In: I25b55378df393cd4fb8932b7ae64f97eb9f1aa8e
(cherry picked from commit 9226d6c835cd57d10a7562f18143dbaae8601b43)

Ashwini Oruganti   authored and   Mark Chien   commited 2020-04-13 15:15:28 +00:00
af37b0a723
Update tethering notification strings
Update strings after converged with carrier.

Bug: 145629001
Bug: 147818698
Test: atests TetheringTests
Change-Id: I8ad34e8c93ba1547aa397a8e9c0ecc15286a2b0b

paulhu   authored and   Paul Hu   commited 2020-04-13 13:36:52 +00:00
735047bf6e
Assign specific client address to dhcp server
Bug: 141256482
Test: manual
      atest TetheringTests

Merged-In: Ief76c98c843ba5420224cbf0f34464f366c891b7
Change-Id: Ief76c98c843ba5420224cbf0f34464f366c891b7

Treehugger Robot   authored and   Mark Chien   commited 2020-04-10 10:03:20 +00:00
5da1070d8f
Use the lastest frozen netd_aidl_interface in framework
Bug: 140541991
Test: build
Merged-In: I984969e09f8d5196945a7412c51bd8880223ad9e
Change-Id: I984969e09f8d5196945a7412c51bd8880223ad9e

Luke Huang   commited 2020-04-09 16:20:44 +00:00
d20078112b
Address aosp/1274403 leftover comment
Bug: 152828142
Test: atest EntitlementManagerTest

Change-Id: I81f2d268c9f26bc4488b06032477a73d071f73f8
Merged-In: I81f2d268c9f26bc4488b06032477a73d071f73f8
(cherry picked from commit 9fe0a868e909a4cd1c1c63bf981441f1b9128890)

Paul Hu   commited 2020-04-09 02:13:32 +00:00
fab349c0a9
Fix TetheringIntegrationTests failure
Bug: 150644681
Test: atest TetheringIntegrationTests
Change-Id: I5a537eca9b1aab3694a11a2dab147a31f289314c
Merged-In: I5a537eca9b1aab3694a11a2dab147a31f289314c
(cherry picked from commit f626b8a5388746d163600a5eccb60e22cb1071bf)

Automerger Merge Worker   authored and   Paul Hu   commited 2020-04-08 08:17:20 +00:00
b33911c19c
Merge "Address aosp/1274403 leftover comment"
Paul Hu   authored and   Gerrit Code Review   commited 2020-04-08 07:36:35 +00:00
9f33a5a7d9
Merge "Fix TetheringIntegrationTests failure"
Paul Hu   authored and   Gerrit Code Review   commited 2020-04-08 06:12:29 +00:00
77f43e56ef
Address aosp/1274403 leftover comment
Bug: 152828142
Test: atest EntitlementManagerTest

Change-Id: I81f2d268c9f26bc4488b06032477a73d071f73f8

paulhu   commited 2020-04-08 11:45:08 +08:00
eaa2b0e30a
Fix TetheringIntegrationTests failure
Bug: 150644681
Test: atest TetheringIntegrationTests
Change-Id: I5a537eca9b1aab3694a11a2dab147a31f289314c

paulhu   commited 2020-04-08 09:57:57 +08:00
d584d2fa36
Add TetheringServiceTest unitest
Bug: 145490751
Test: atest TetheringTests

Change-Id: Ia9e3232467c7db0e566cced84f3c72bbcd6512d6
Merged-In: I68cd403302848c041444e6d47652435d67f59273
(cherry picked from commit 790a4dd7d3aa813f15fe95c5bf3cef6dd734ce32)

Mark Chien   commited 2020-04-08 01:02:39 +00:00
47c8b0f87e
Merge "Add TetheringServiceTest unitest"
Mark Chien   authored and   Gerrit Code Review   commited 2020-04-07 15:39:38 +00:00
7e0920903b
Use the lastest frozen netd_aidl_interface in framework
Bug: 140541991
Test: build
Change-Id: I984969e09f8d5196945a7412c51bd8880223ad9e

Luke Huang   commited 2020-04-07 08:35:42 +00:00
6ca4ec97d2
Merge "Add IPv6TetheringCoordinator unit test" into rvc-dev
Mark Chien   authored and   Android (Google) Code Review   commited 2020-04-07 07:50:40 +00:00
8caf921dc8
Merge "Fix EntitlementManager issues" into rvc-dev
Paul Hu   authored and   Android (Google) Code Review   commited 2020-04-07 04:37:30 +00:00
aaf92e5165
Add IPv6TetheringCoordinator unit test
Bug: 148636687
Test: atest IPv6TetheringCoordinatorTest

Change-Id: I1ba30bb524cbc0cc2782ce1702f9889c0d8a7576
Merged-In: I939323ce09adb9c66b1e2b83d58b0f892aa8f011
(cherry picked from commit 368c56dd7133d292c5f3ab5942016bb4dd1fbc88)

Mark Chien   commited 2020-04-07 04:33:24 +00:00
5e9e0337c5
Merge "Add a test for static IPv4 address tethering configuration." into rvc-dev
Lorenzo Colitti   authored and   Android (Google) Code Review   commited 2020-04-07 04:30:58 +00:00
6343b0c968
Merge "Use CompletableFuture instead of a latch." into rvc-dev
Lorenzo Colitti   authored and   Android (Google) Code Review   commited 2020-04-07 04:30:33 +00:00
303e9bdddf
Merge "Rename IDhcpLeaseCallbacks to IDhcpEventCallbacks for more generic." into rvc-dev
Xiao Ma   authored and   Android (Google) Code Review   commited 2020-04-07 02:50:41 +00:00
210adac5fa
Add a test for static IPv4 address tethering configuration.
Bug: 150644681
Test: test-only change
Merged-In: I8f4a99da2351fdb5467f561a9732b14a8ebf674b
Change-Id: I8f4a99da2351fdb5467f561a9732b14a8ebf674b

Lorenzo Colitti   commited 2020-04-07 02:21:00 +00:00
7f6ab40294
Use CompletableFuture instead of a latch.
Addresses review comments on aosp/1260100.

Bug: 150644681
Test: test-only change
Merged-In: Ia73ba8a121a3744a5e36795d2d2bff2f099c1394
Change-Id: Ia73ba8a121a3744a5e36795d2d2bff2f099c1394

Lorenzo Colitti   commited 2020-04-07 02:20:35 +00:00
46b44053da
Rename IDhcpLeaseCallbacks to IDhcpEventCallbacks for more generic.
Bug: 130741856
Test: atest TetheringTests
Merged-In: I66614fbf67fba1e7dab0b8a2d41bc30a726e4f38
Change-Id: I66614fbf67fba1e7dab0b8a2d41bc30a726e4f38

Xiao Ma   commited 2020-04-07 01:26:50 +00:00
06c8ba0cd7
Fix EntitlementManager issues
1. Add TETHERING_ETHERNET to vaild downstream type. So starting
   ethernet tethering will do entitlement check as well.
2. Ignore request with invalid downstream type on
   handleRequestLatestTetheringEntitlementValue()

Bug: 152828758
Bug: 152828142
Test: atests TetheringTests CtsTetheringTest

Change-Id: Id0cb59cc4681f5ffbde7be54de05a05e46f0ffb8
Merged-In: Id0cb59cc4681f5ffbde7be54de05a05e46f0ffb8
(cherry picked from commit c502e050fd9543e8bde45014dd66ea1be91c90ef)

Paul Hu   commited 2020-04-07 01:23:49 +00:00
bd8d7a8208
Migrate to TetherOffloadRuleParcel in IpServer
The netd tethering offload IPCs are changing from taking a list
of primitives to taking a TetherOffloadRuleParcel. Modify their
only caller.

Bug: 140541991
Test: atest IpServerTest
Merged-In: I83718c80ef9d31199c87021b4dd5821717fd5ba5
Change-Id: I83718c80ef9d31199c87021b4dd5821717fd5ba5

Lorenzo Colitti   commited 2020-04-06 15:45:58 +00:00
e6107d2466
Merge "Add IPv6TetheringCoordinator unit test"
Mark Chien   authored and   Gerrit Code Review   commited 2020-04-06 15:25:37 +00:00
7b4fb08444
Merge "Rename IDhcpLeaseCallbacks to IDhcpEventCallbacks for more generic."
Xiao Ma   authored and   Gerrit Code Review   commited 2020-04-06 10:43:28 +00:00
a73e5c5c18