diff options
author | Chiachang Wang <chiachangwang@google.com> | 2019-04-18 00:58:02 -0700 |
---|---|---|
committer | android-build-merger <android-build-merger@google.com> | 2019-04-18 00:58:02 -0700 |
commit | 2bd61ae9a1bbd319169725db4ccf67360b485914 (patch) | |
tree | 59df7e230cb46f43faef398b0919ac6af8f2fa1f /src/android/net/util/NetworkStackUtils.java | |
parent | 274b7c5ca663b29b9cf1337456cf91975a868c12 (diff) | |
parent | 96eb8158a359dd82bac4f8c6808f072c65337f72 (diff) |
Merge "Move Setting constants for NetworkStack"
am: 587ee7240e
Change-Id: Ieedf7af48c408637c11c4ea7fe4cc93261ce613d
Diffstat (limited to 'src/android/net/util/NetworkStackUtils.java')
-rw-r--r-- | src/android/net/util/NetworkStackUtils.java | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/src/android/net/util/NetworkStackUtils.java b/src/android/net/util/NetworkStackUtils.java index 547f04d..fb03c54 100644 --- a/src/android/net/util/NetworkStackUtils.java +++ b/src/android/net/util/NetworkStackUtils.java @@ -34,6 +34,34 @@ public class NetworkStackUtils { // TODO: Refer to DeviceConfig definition. public static final String NAMESPACE_CONNECTIVITY = "connectivity"; + /** + * A list of captive portal detection specifications used in addition to the fallback URLs. + * Each spec has the format url@@/@@statusCodeRegex@@/@@contentRegex. Specs are separated + * by "@@,@@". + */ + public static final String CAPTIVE_PORTAL_FALLBACK_PROBE_SPECS = + "captive_portal_fallback_probe_specs"; + + /** + * A comma separated list of URLs used for captive portal detection in addition to the + * fallback HTTP url associated with the CAPTIVE_PORTAL_FALLBACK_URL settings. + */ + public static final String CAPTIVE_PORTAL_OTHER_FALLBACK_URLS = + "captive_portal_other_fallback_urls"; + + /** + * Which User-Agent string to use in the header of the captive portal detection probes. + * The User-Agent field is unset when this setting has no value (HttpUrlConnection default). + */ + public static final String CAPTIVE_PORTAL_USER_AGENT = "captive_portal_user_agent"; + + /** + * Whether to use HTTPS for network validation. This is enabled by default and the setting + * needs to be set to 0 to disable it. This setting is a misnomer because captive portals + * don't actually use HTTPS, but it's consistent with the other settings. + */ + public static final String CAPTIVE_PORTAL_USE_HTTPS = "captive_portal_use_https"; + static { System.loadLibrary("networkstackutilsjni"); } |