Merge "Add a global setting to disable DNS over TLS" am: 4a906c167b am: 3017ebec8c

am: b84582fc96

Change-Id: Ia64a8318ad2f57aa3dc58a13d20274b877649fef
This commit is contained in:
Ben Schwartz
2017-10-20 15:33:17 +00:00
committed by android-build-merger
4 changed files with 16 additions and 1 deletions

View File

@@ -9220,6 +9220,13 @@ public final class Settings {
*/
public static final String DEFAULT_DNS_SERVER = "default_dns_server";
/**
* Whether to disable DNS over TLS (boolean)
*
* @hide
*/
public static final String DNS_TLS_DISABLED = "dns_tls_disabled";
/** {@hide} */
public static final String
BLUETOOTH_HEADSET_PRIORITY_PREFIX = "bluetooth_headset_priority_";

View File

@@ -182,6 +182,7 @@ public class SettingsBackupTest {
Settings.Global.DNS_RESOLVER_MIN_SAMPLES,
Settings.Global.DNS_RESOLVER_SAMPLE_VALIDITY_SECONDS,
Settings.Global.DNS_RESOLVER_SUCCESS_THRESHOLD_PERCENT,
Settings.Global.DNS_TLS_DISABLED,
Settings.Global.DOCK_SOUNDS_ENABLED_WHEN_ACCESSIBILITY,
Settings.Global.DOWNLOAD_MAX_BYTES_OVER_MOBILE,
Settings.Global.DOWNLOAD_RECOMMENDED_MAX_BYTES_OVER_MOBILE,

View File

@@ -524,6 +524,12 @@
<!-- [CHAR LIMIT=NONE] Label for displaying Bluetooth Audio Codec Parameters while streaming -->
<string name="bluetooth_select_a2dp_codec_streaming_label">Streaming: <xliff:g id="streaming_parameter">%1$s</xliff:g></string>
<!-- Title of the developer option for DNS over TLS. -->
<string name="dns_tls">DNS over TLS</string>
<!-- Summary to explain the developer option for DNS over TLS. This allows the user to
request that the system attempt TLS with all DNS servers, or none. -->
<string name="dns_tls_summary">If enabled, attempt DNS over TLS on port 853.</string>
<!-- setting Checkbox summary whether to show options for wireless display certification -->
<string name="wifi_display_certification_summary">Show options for wireless display certification</string>
<!-- Setting Checkbox summary whether to enable Wifi verbose Logging [CHAR LIMIT=80] -->

View File

@@ -1980,7 +1980,8 @@ public class NetworkManagementService extends INetworkManagementService.Stub
final String[] domainStrs = domains == null ? new String[0] : domains.split(" ");
final int[] params = { sampleValidity, successThreshold, minSamples, maxSamples };
final boolean useTls = false;
final boolean useTls = Settings.Global.getInt(resolver,
Settings.Global.DNS_TLS_DISABLED, 0) == 0;
final String tlsHostname = "";
final String[] tlsFingerprints = new String[0];
try {