xref: /aosp_15_r20/external/cronet/net/dns/public/secure_dns_policy.h (revision 6777b5387eb2ff775bb5750e3f5d96f37fb7352b)
1 // Copyright 2021 The Chromium Authors
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4 
5 #ifndef NET_DNS_PUBLIC_SECURE_DNS_POLICY_H_
6 #define NET_DNS_PUBLIC_SECURE_DNS_POLICY_H_
7 
8 namespace net {
9 
10 // The SecureDnsPolicy indicates whether and how a specific request or socket
11 // can use Secure DNS.
12 enum class SecureDnsPolicy {
13   // Secure DNS is allowed for this request, if it is generally enabled.
14   kAllow,
15   // This request must not use Secure DNS, even when it is otherwise enabled.
16   kDisable,
17   // This request is part of the Secure DNS bootstrap process.
18   kBootstrap,
19 };
20 
21 const char* SecureDnsPolicyToDebugString(SecureDnsPolicy secure_dns_policy);
22 
23 }  // namespace net
24 
25 #endif  // NET_DNS_PUBLIC_SECURE_DNS_POLICY_H_
26