Test: Test passing with 1 or more connected wifis
No wifi won't pass but it's already a requirement
Bug: 34630278
Change-Id: I43bf18943fbd00dc29417b18604e29f9111ec0b2
Merged-in: I43bf18943fbd00dc29417b18604e29f9111ec0b2
Merged-in: Ie90ca72ea3606dea4259984d42762dd742d59970
Previously, CTS tests could block forever on attempting to read a packet
from a UDP socket.
This patch modifies the receive methods of the NativeUdpSocket wrapper,
allowing it to gracefully fail if UDP packets are not received.
This patch also updates the IKE over UDP encap socket test to use the
NativeUdpSocket wrapper, preventing the tests from hanging in the same
fashion.
Bug: 70938121
Test: Ran updated tests on walleye + marlin
Change-Id: I390e4585e85647eb8555e706d44b76f95dec931f
This patch switches IpSecManager checkTransform() tests to use generic
sockets, allowing for exercising of Java sockets as well as native/OS
sockets.
Bug: 76152303
Test: This; ran on Walleye
Change-Id: I515227e7aa04c424aefbbe46209ddce81421b2f1
This patch adds functionality to unify java and native sockets. This is
part one of two of a change to allow functionality for testing full
coverage of all APIs.
Bug: 76152303
Test: Ran tests on Walleye
Change-Id: I9bd57d6267f82d8c1ac293a0147dc2c115dd4181
This change updates the getSocket calls to getFileDescriptor, persuant
to new API.
Bug: 72473753
Test: CTS tests run on walleye
Change-Id: I65479cb35c88aee1f65c8597c3382cd30fa8d4a9
This change adds all combinations of GCM algorithms, ensuring proper
support, config flags, and data accounting. Algorithm for calculating
size of packets has also been made more generic to allow for calculation
based on different encryption algorithms.
Bug: 73261868
Test: This
Change-Id: Ib77ac237fee75415223f0291cecc0b60ce76b77f
This patch adds tests for cases where only auth or crypt are enabled.
These cases are supported, and this patch adds test coverage.
Bug: 75049573
Test: this, run on walleye
Change-Id: I656d9c4a86c13ce4928d6bd68a9e0d48cf805191
This change adds tests to ensure that SPI expiration timers are set to a
high value, greater than 1 hour (3600s).
Bug: 72316671
Test: Ran this, and MultiNetworkSysCtlTest.
Change-Id: Ib4776322bd5df772a3700b6e7ed1b5e7ed6b4637
This change sets LOCAL_SDK_VERSION for all packages where
this is possible without breaking the build, and
LOCAL_PRIVATE_PLATFORM_APIS := true otherwise.
Setting one of these two will be made required soon, and this
is a change in preparation for that. Not setting LOCAL_SDK_VERSION
makes the app implicitly depend on the bootclasspath, which is
often not required. This change effectively makes depending on
private apis opt-in rather than opt-out.
Test: make relevant packages
Bug: 73535841
Change-Id: I687153389dd4bfab1c83df5d9af83d89bed76fd4
Merged-In: I5afdfc8e1e523768db9065dd3571cb31bc1dfac5
Update IpSec tests to remove the transform parameter from
calls to removeTransportModeTransform(). It is infeasible
and thus removed.
Bug: 72079356
Test: cts - IpSecManagerTest
Change-Id: Iaa0b35b24bf044503da9af9966508ac5e88846e1
This patch augments testCreateTransform() to
selectively apply the ipSecTransform in one/both
directions and then verifies that the link succeeds or
fails correctly. In addition, this converts the test
to use the Java sockets API for DatagramSocket instead
of using the FD-based API. One of the combos does not
fail as expected, so b/72048263 is tracking further
work needed.
Bug: 72047396
Bug: 71717213
Test: cts - IpSecManagerTest
Change-Id: Ied961f442b29f1e66ded37c7ffe7afdd4a5c49da
API changes in IpSecManager and IpSecTransform are
reflected in these test updates: no functional change
to the test; just style updates along with improvement
in the clarity of using a single transform for both
directions.
Bug: 71717213
Test: CTS - IpSecManagerTest
Change-Id: Ia6933d010620516672687080898f8c4fd83223bc
The qtaguid module is required for devices running kernel earlier then
4.9, but is no longer avaliable after that. Add a check before running
the kernel qtaguid native test so it doesn't fail on new devices.
Bug: 30950746
Test: run cts -m CtsNativeNetTestCases
Change-Id: I32bc77a4c51d8b64ac1a5411c75c56a51b84ea77
testConnectivityChanged_manifestRequestOnlyPreN_shouldReceiveIntent()
starts up a helper activity that listens to network connection/disconnection
notification. In many cases the test fails because the activity is just
able to start up and initialize itself before the first toggle event
arrives and in many cases it just misses by a matter of 100ms.
Added a short sleep after we start the activity and before we start
toggling WiFi to let the activity a chance to receive the first
notification.
Bug: 70988664
Change-Id: Ie122770fc8447a936d079fae7bdce61b10cf6dc2
This ensures the function IpSecManager.applyTransportModeTransform()
works as expected when used with Java sockets.
Bug: 70160694
Test: Ran CTS test (./run_cts.sh)
Change-Id: Ia4b636c0f48a0eeffb8813d271e59aeb86bd44bc
Investigation shows that 4.4 kernels take longer for loopback TCP
packets to be ack'd, and results in extra ack packets to be generated in
cases where both the server and client sockets send data packets at the
same time. This was verified via TCPdump, where an extra ack packet was
generated per run of the bidirectional transmissions in checkTcp().
This change verifies that the data + ack packets have been sent and
counted before initiating the reverse transmission. Further, changes
have been made to improve the reliability of this code via counting
expected packets (rather than sleeps).
Bug: 62994731
Test: CTS tests run (and passing) on walleye, marlin and angler
Change-Id: I7c707ec3b11235a5a9cba10275aee40e2eb37169
Notification listeners are not allowed on low ram devices.
Skip testDozeModeMetered_enabledButWhitelistedOnNotificationAction
and testDozeModeNonMetered_enabledButWhitelistedOnNotificationAction
on low ram devices since these tests depend on being able to
register notification listeners.
Bug: 70242457
Bug: 70545780
Test: testDozeModeMetered_enabledButWhitelistedOnNotificationAction
and testDozeModeNonMetered_enabledButWhitelistedOnNotificationAction
Change-Id: I8ce6f330760042ca790cd6fb10e62ebe86498a06
This change ensures that all forms of transport-mode packets are
correctly accounted for, and not double-counted. This includes both
per-UID counters, as well as interface counters.
Bug: 62994731
Test: CTS tests updated, passing
Change-Id: I83be0724ac21d9db7d91ce72733d13fb6736e66e
IPsec API is renaming reserveSecurityParameterIndex to
allocateSecurityParameterIndex. Update tests to reflect this.
Bug: 69128142
Test: TreeHugger should be enough
Change-Id: I0bfaa3584920096ffde7f9eeee9fccd0ec842821
I saw a bunch fly by. Here are a few fixes.
ssize_t is %zd. Types from stdint.h use PRI* macros from inttypes.h.
Finally, use C99 initializers rather than the old GNU extension.
Test: make checkbuild
Change-Id: I343dfb99984ab826c7641e311e041e859eb61d93
Update the key lengths for SHA1 and MD5 authentication
to pass the new tighter range checks.
Bug: 70324823
Test: this
Change-Id: I8f533f043d16b0571bac628d21878e31027fe853
Added CTS test to check the transform (for IPv4 & IPv6) with
various authentication & encryptions types
Bug: 34812052
Test: Ran CTS on angler using aosp/run_cts.sh
Change-Id: I51b4d13847ed0f8ad8d5f19132fdb35b1bd2950c