Add configurable captive portal probes

The probes allow testing for a configurable status code and location
header (regexes). They are disabled by default, so this CL is a
no-op unless the probe configurations are pushed.

Bug: b/79499239
Test: tests in CL pass, manual: captive portal login works
Change-Id: I785723aaed06054b9aa8ebff77803f23d7836db9
This commit is contained in:
Remi NGUYEN VAN
2018-05-22 10:01:53 +09:00
parent cabd8329f3
commit c2491572d5

View File

@@ -237,6 +237,14 @@ public class ConnectivityManager {
*/
public static final String EXTRA_CAPTIVE_PORTAL_URL = "android.net.extra.CAPTIVE_PORTAL_URL";
/**
* Key for passing a {@link android.net.captiveportal.CaptivePortalProbeSpec} to the captive
* portal login activity.
* {@hide}
*/
public static final String EXTRA_CAPTIVE_PORTAL_PROBE_SPEC =
"android.net.extra.CAPTIVE_PORTAL_PROBE_SPEC";
/**
* Key for passing a user agent string to the captive portal login activity.
* {@hide}