- Test was failing on S mainline builds. Fixing forward.
Bug: 210540375
Test: CtsDnsResolverTests.
Change-Id: Ia980965c8ee1b9ddae99f593628f8b7ecfeca394
This is no longer used outside of tests, and can be safely
removed.
Also this family of methods is fairly confusing, as while
it's well defined for some members, many later additions
had to be written so as to dissallow some combinations when
the workings of this family of methods didn't match the
semantics of some members, making them possibly dangerous
to use and at least exhibit difficult to understand semantics.
Test: FrameworksNetTests
m
Change-Id: Ia69c20afa16c2153839891f6e33331caa9da33ff
- Adds a CTS test to verify that DnsException
can be subclassed and its constructor re-used.
Test: Adds testDnsExceptionConstructor() CTS test.
Bug: 208479811
Change-Id: Ia1dffe8ad5252b61af5a6ef0f6630f075081a6d1
Making the DnsException constructor public is useful for apps
using DnsResolver to write their tests, and for internal packages
that may want to implement the DnsResolver.Callback interface.
Test: for regression; CTS tests in b/208479811
Bug: 208464882
Change-Id: I14641688f53721c96e6df9596a7506912ba3aec0
These CTS tests previously extended AndroidTestCase, which made useful
annotations like 'DevSdkIgnoreRule' not take effect.
Test: CtsNetTestCasesLatestSdk
Bug: 208479811
Change-Id: I79f7e48167bb3bfbd4f6cde33d7e3907c2af6f74
These files are needed for the data migration util system Api
interfaces. Thus, they need to be moved into frameworks folder.
This change also set the @IgnoreUpTo annotation to S, since
these tests are testing purely platform code on S- devices which
is not really necessary for MTS. Also the tests are still covered
by the unit tests, since they are always verifying HEAD.
Test: TH
Bug: 197717846
Change-Id: I93c19b4860864c724be9f9f889ee2173f4605198
NsdSettings has been removed from NsdService, so the test needs
to update accordingly.
Bug: 206702844
Test: atest FrameworksNetTests CtsNetTestCases
Change-Id: I23b6323b2d870746737370b9a3fc90e530e3d2ed
If exception s thrown while calling bindSocket(fd), the temporary
created ParcelFileDescriptor may not be closed as expected.
Ensure it's closed eventually.
Bug: 206042872
Test: atest FrameworksNetTests
Change-Id: Icde895978ab9281006ffd56335d1247462d9da28
This code is now dead and can't be resurrected. It can safely
be removed.
Test: FrameworksNetTests
Change-Id: I7bc2ce3d43a92e463b6aed73914c3f7a3a0c8103
An exception is thrown in finally{} before the last cleanup
step which is not executed, wreaking havoc on the device
networking state.
Test: CtsNetTestsCasesLatestSdk
Change-Id: I645466b1418c038aadd301847ad4be445206f5de
PermissionMonitor only saves netd network permissions by appId.
Then apply same permision to uids which are same appId. But
UIDS_ALLOWED_ON_RESTRICTED_NETWORKS can allow single uid has
restricted network permission. Thus, save the netd network
permissions by uid that can apply different permission to each
uid.
Bug: 192431153
Test: atest FrameworksNetTests
Change-Id: I942cbe0fa30758a7497c47a1b684ed70c4e3b09e
NetworkRequest is expecting transport type Ethernet or test. This
causes the test 'testApiCallbacks' to fail for devices that have a
non-test Ethernet network since that network is being chosen instead of
the expected test Ethernet network.
Remove network capability TRANSPORT_ETHERNET from CaptivePortalApiTest.
Bug: 204329523
Test: atest android.net.cts.CaptivePortalApiTest#testApiCallbacks
Signed-off-by: Davor Majdandzic <davor.majdandzic@aptiv.com>
Change-Id: Ie7b4d00c08f1497044e63462f1d899d1f3dea2df
see kernel/private/wembley/+/refs/heads/tm-4.19/include/uapi/linux/if_arp.h
which has #define ARPHRD_PUREIP 520 (and is a Mediatek based device)
or Qualcomm based Pixel 3 and older kernels (<=4.9) which #define ARPHRD_RAWIP 530
(unlike Pixel 4/5 which are 4.14/4.19 and use the upstream ARPHRD_RAWIP of 519)
We stop supporting 520/530 starting with 5.11+ since those as GKI 2.0 only kernels
cannot be using non-upstream-ed constants (btw. this is probably true for 5.10-S
as well, but let's play it safe). For pre-5.11 we're lucky because even now
(with 5.15 released) upstream has yet to define an ARPHRD_* for either one of
520 or 530, so there's no harm in 'squatting' on this unused space.
This approach also means there's absolutely no change in behaviour on
pre-launch-T devices, since they all are at most running 5.10 kernels.
We'll be able to get rid of this code in the far future once we stop shipping
mainline tethering updates to pre-5.10 Mediatek or pre-4.14 Qualcomm devices.
This will likely be many years.
Test: TreeHugger
Bug: 207057951
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: I767b5fc56bc826e088507aea8ae7a30aa8aa424a
The defaults can be used to enable/disable connectivity next targets
depending on the branch, while minimizing merge conflicts.
The "next" target may use unstable APIs. It need to be disabled in the
branch which only have the last stable SDK available.
Also correct TetheringTestsLatestSdkLib which should use stable API.
Test: TH
Change-Id: I00d91bbd513277c1cedf67d18ac9f56cc4037309
The TODO is used to track to remove dependencies from
ConnectivityService. Remove it since that was already done.
Test: remove comment only
Change-Id: Ida8c1124e110f64262a693dcddfbc7a9549510da
The header file is referenced by the part going to be mainlined in Netd.
Note that some platform visibility is required with this commit, since
users of bpf_shared.h is currently located in platform. The visibility
can be removed when all users are moved out of platform.
Bug: 202086915
Test: m; flash; boot
Test: cd system/netd && atest
Test: cd packages/modules/Connectivity && atest
Test: atest FrameworksNetTests
Change-Id: I5c16511b6a2d4eb80dfd93157cbc98d5030bd5ac