idnits 2.17.1 draft-bortzmeyer-dnsop-privacy-sol-00.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- ** The document seems to lack an IANA Considerations section. (See Section 2.2 of https://www.ietf.org/id-info/checklist for how to handle the case when there are no actions for IANA.) ** The abstract seems to contain references ([I-D.bortzmeyer-dnsop-dns-privacy]), which it shouldn't. Please replace those with straight textual mentions of the documents in question. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (December 17, 2013) is 3776 days in the past. Is this intentional? Checking references for intended status: Informational ---------------------------------------------------------------------------- == Unused Reference: 'RFC2119' is defined on line 277, but no explicit reference was found in the text == Unused Reference: 'RFC6973' is defined on line 280, but no explicit reference was found in the text == Unused Reference: 'RFC4033' is defined on line 295, but no explicit reference was found in the text == Unused Reference: 'RFC5936' is defined on line 302, but no explicit reference was found in the text == Unused Reference: 'I-D.koch-perpass-dns-confidentiality' is defined on line 308, but no explicit reference was found in the text == Unused Reference: 'I-D.vandergaast-edns-client-subnet' is defined on line 313, but no explicit reference was found in the text == Outdated reference: A later version (-02) exists of draft-bortzmeyer-dnsop-dns-privacy-00 -- Obsolete informational reference (is this intentional?): RFC 5246 (Obsoleted by RFC 8446) -- Obsolete informational reference (is this intentional?): RFC 6347 (Obsoleted by RFC 9147) == Outdated reference: A later version (-03) exists of draft-wijngaards-dnsop-confidentialdns-00 Summary: 2 errors (**), 0 flaws (~~), 9 warnings (==), 3 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group S. Bortzmeyer 3 Internet-Draft AFNIC 4 Intended status: Informational December 17, 2013 5 Expires: June 20, 2014 7 Possible solutions to DNS privacy issues 8 draft-bortzmeyer-dnsop-privacy-sol-00 10 Abstract 12 This document describes some possible solutions to the DNS privacy 13 issues described in [I-D.bortzmeyer-dnsop-dns-privacy]. 15 Discussions of the document should currently take place on the dnsop 16 mailing list [dnsop]. 18 Status of This Memo 20 This Internet-Draft is submitted in full conformance with the 21 provisions of BCP 78 and BCP 79. 23 Internet-Drafts are working documents of the Internet Engineering 24 Task Force (IETF). Note that other groups may also distribute 25 working documents as Internet-Drafts. The list of current Internet- 26 Drafts is at http://datatracker.ietf.org/drafts/current/. 28 Internet-Drafts are draft documents valid for a maximum of six months 29 and may be updated, replaced, or obsoleted by other documents at any 30 time. It is inappropriate to use Internet-Drafts as reference 31 material or to cite them other than as "work in progress." 33 This Internet-Draft will expire on June 20, 2014. 35 Copyright Notice 37 Copyright (c) 2013 IETF Trust and the persons identified as the 38 document authors. All rights reserved. 40 This document is subject to BCP 78 and the IETF Trust's Legal 41 Provisions Relating to IETF Documents 42 (http://trustee.ietf.org/license-info) in effect on the date of 43 publication of this document. Please review these documents 44 carefully, as they describe your rights and restrictions with respect 45 to this document. Code Components extracted from this document must 46 include Simplified BSD License text as described in Section 4.e of 47 the Trust Legal Provisions and are provided without warranty as 48 described in the Simplified BSD License. 50 Table of Contents 52 1. Introduction and background . . . . . . . . . . . . . . . . . 2 53 2. Possible technical solutions . . . . . . . . . . . . . . . . 2 54 2.1. On the wire . . . . . . . . . . . . . . . . . . . . . . . 3 55 2.1.1. Reducing the attack surface . . . . . . . . . . . . . 3 56 2.1.2. Encrypting the DNS traffic . . . . . . . . . . . . . 3 57 2.2. In the servers . . . . . . . . . . . . . . . . . . . . . 4 58 2.2.1. In the resolvers . . . . . . . . . . . . . . . . . . 4 59 2.2.2. In the authoritative name servers . . . . . . . . . . 5 60 2.2.3. Rogue servers . . . . . . . . . . . . . . . . . . . . 6 61 3. Security considerations . . . . . . . . . . . . . . . . . . . 6 62 4. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 6 63 5. References . . . . . . . . . . . . . . . . . . . . . . . . . 6 64 5.1. Normative References . . . . . . . . . . . . . . . . . . 6 65 5.2. Informative References . . . . . . . . . . . . . . . . . 7 66 Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 8 68 1. Introduction and background 70 The problem statement is exposed in 71 [I-D.bortzmeyer-dnsop-dns-privacy]. The terminology here is also 72 defined in this companion document. 74 2. Possible technical solutions 76 We mention here only the solutions that could be deployed in the 77 current Internet. Disruptive solutions, like replacing the DNS with 78 a completely new resolution protocol, are interesting but are kept 79 for a future work. Remember that the focus of this document is on 80 describing the threats, not in detailing solutions. This section is 81 therefore non-normative and is NOT a technical specification of 82 solutions. For the same reason, there are not yet actual 83 recommendations in this document. 85 Raising seriously the bar against the eavesdropper will require 86 SEVERAL actions. Not one is decisive by itself but, together, they 87 can have an effect. The most important suggested here are: 89 qname minimization, 91 encryption of DNS traffic, 93 padding (sending random queries from time to time). 95 We detail some of these actions later, classified by the kind of 96 observer (on the wire, in a server, etc). Some actions will help 97 against several kinds of observers. For instance, padding, sending 98 gratuitous queries from time to time (queries where you're not 99 interested in the replies, just to disturb the analysis), is useful 100 against all sorts of observers. It is a costly technique, because it 101 increases the traffic on the network but it seriously blurs the 102 picture for the observer. 104 2.1. On the wire 106 2.1.1. Reducing the attack surface 108 See Section 2.2.1 since the solution described there apply against 109 on-the-wire eavesdropping as well as against observation by the 110 resolver. 112 2.1.2. Encrypting the DNS traffic 114 To really defeat an eavesdropper, there is only one solution: 115 encryption. But, from the end user point of view, even if you check 116 that your communication between your stub resolver and the resolver 117 is encrypted, you have no way to ensure that the communication 118 between the resolver and the autoritative name servers will be. 119 There are two different cases, communication between the stub 120 resolver and the resolver (no caching but only two parties so 121 solutions which rely on an agreement may work) and communication 122 between the resolver and the authoritative servers (less data because 123 of caching, but many parties involved, so any solution has to scale 124 well). Encrypting the "last mile", between the user's stub resolver 125 and the resolver may be sufficient since the biggest danger for 126 privacy is between the stub resolver and the resolver, because there 127 is no caching involved there. 129 The only encryption mechanism available for DNS which is today an 130 IETF standard is IPsec in ESP mode. Its deployment in the wide 131 Internet is very limited, for reasons which are out of scope here. 132 Still, it may be a solution for "the last mile" and, indeed, many VPN 133 solutions use it this way, encrypting the whole traffic, including 134 DNS to the safe resolver. In the IETF standards, a possible 135 alternative could be DTLS [RFC6347]. It enjoyed very little actual 136 deployment and its interaction with the DNS has never been 137 considered, studied or of course implemented. There are also non 138 standard encryption techniques like DNScrypt [dnscrypt] for the stub 139 resolver <-> resolver communication or DNScurve [dnscurve] for the 140 resolver <-> authoritative server communication. It seems today that 141 the possibility of massive encryption of DNS traffic is very remote. 143 A last "pervasive encryption" solution for the DNS could be the 144 promising [I-D.wijngaards-dnsop-confidentialdns]. 146 Another solution would be to use more TCP for the queries, together 147 with TLS [RFC5246]. DNS can run over TCP and it provides a good way 148 to leverage the software and experience of the TLS world. There have 149 been discussions to use more TCP for the DNS, in light of reflection 150 attacks (based on the spoofing of the source IP address, which is 151 much more difficult with TCP). For instance, a stub resolver could 152 open a TCP connection with the resolver at startup and keep it open 153 to send queries and receive responses. The server would of course be 154 free to tear down these connections at will (when it is under stress, 155 for instance) and the client could reestablish them when necessary. 156 Remember that TLS sessions can survive TCP connections so there is no 157 need to restart the TLS negociation each time. This DNS-over-TLS- 158 over-TCP is already implemented in the Unbound resolver. It is safe 159 only if pipelining multiple questions over the same channel. Name 160 compression should also be disabled, or CRIME-style [crime] attacks 161 can apply. 163 Encryption alone does not guarantee perfect privacy, because of the 164 available metadata. For instance, the size of questions and 165 responses, even encrypted, provide hints about what queries have been 166 sent. (DNScrypt uses random-length padding, and a 64 bytes block 167 size, to limit this risk, but this raises other issues, for instance 168 during amplification attacks. Other security protocols use similar 169 techniques, for instance ESPv3.) Observing the periodicity of 170 encrypted questions/responses also discloses the TTL, which is yet 171 another hint about the queries. Non-cached responses are disclosing 172 the RTT between the resolver and authoritative servers. This is a 173 very useful indication to guess where authoritative servers are 174 located. Web pages are made of many resources, leading to multiple 175 requests, whose number and timing fingerprint which web site is being 176 browsed. So, observing encrypted traffic is not enough to recover 177 any plaintext queries, but is enough to answer the question "is one 178 of my employees browsing Facebook?". Finally, attackers can perform 179 a denial-of-service attack on possible targets, check if this makes a 180 difference on the encrypted traffic they observe, and infer what a 181 query was. 183 2.2. In the servers 185 2.2.1. In the resolvers 187 It does not seem there is a possible solution against a leaky 188 resolver. A resolver has to see the entire DNS traffic in clear. 190 The best approach to limit the problem is to have local resolvers 191 whose caching will limit the leak. Local networks should have a 192 local caching resolver (even if it forwards the unanswered questions 193 to a forwarder) and individual laptops can have their very own 194 resolver, too. 196 One mechanism to potentially mitigate on the wire attacks between 197 stub resolvers and caching resolvers is to determine if the network 198 location of the caching resolver can be moved closer to the end 199 user's computer (reducing the attack surface). As noted earlier in 200 [I-D.bortzmeyer-dnsop-dns-privacy], if an end user's computer is 201 configured with a caching resolver on the edge of the local network, 202 an attacker would need to gain access to that local network in order 203 to successfully execute an on the wire attack against the stub 204 resolver. On the other hand, if the end user's computer is 205 configured to use a public DNS service as the caching resolver, the 206 attacker needs to simply get in the network path between the end user 207 and the public DNS server and so there is a much greater opportunity 208 for a successful attack. Configuring a caching resolver closer to 209 the end user can also reduce the possibility of on the wire attacks. 211 2.2.2. In the authoritative name servers 213 A possible solution would be to minimize the amount of data sent from 214 the resolver. When a resolver receives the query "What is the AAAA 215 record for www.example.com?", it sends to the root (assuming a cold 216 resolver, whose cache is empty) the very same question. Sending 217 "What are the NS records for .com?" would be sufficient (since it 218 will be the answer from the root anyway). To do so would be 219 compatible with the current DNS system and therefore could be 220 deployable, since it is an unilateral change to the resolvers. 222 To do so, the resolver needs to know the zone cut [RFC2181]. There 223 is not a zone cut at every label boundary. If we take the name 224 www.foo.bar.example, it is possible that there is a zone cut between 225 "foo" and "bar" but not between "bar" and "example". So, assuming 226 the resolver already knows the name servers of .example, when it 227 receives the query "What is the AAAA record of www.foo.bar.example", 228 it does not always know if the request should be sent to the name 229 servers of bar.example or to those of example. [RFC2181] suggests an 230 algorithm to find the zone cut, so resolvers may try it. 232 Note that DNSSEC-validating resolvers already have access to this 233 information, since they have to find the zone cut (the DNSKEY record 234 set is just below, the DS record set just above). 236 It can be noted that minimizing the amount of data sent also 237 partially addresses the case of a wire sniffer. 239 One should note that the behaviour suggested here (minimizing the 240 amount of data sent in qnames) is NOT forbidden by the [RFC1034] 241 (section 5.3.3) or [RFC1035] (section 7.2). Sending the full qname 242 to the authoritative name server is a tradition, not a protocol 243 requirment. 245 Another note is that the answer to the NS query, unlike the referral 246 sent when the question is a full qname, is in the Answer section, not 247 in the Authoritative section. It has probably no practical 248 consequences. 250 2.2.3. Rogue servers 252 Traditional security measures (do not let malware change the system 253 configuration) are of course a must. A protection against rogue 254 servers announced by DHCP could be to have a local resolver, and to 255 always use it, ignoring DHCP. 257 3. Security considerations 259 Hey, man, the entire document is about security! 261 4. Acknowledgments 263 Thanks to Olaf Kolkman and Francis Dupont for the interesting 264 discussions, specially about qname minimization. Thanks to Mohsen 265 Souissi for proofreading. 267 5. References 269 5.1. Normative References 271 [RFC1034] Mockapetris, P., "Domain names - concepts and facilities", 272 STD 13, RFC 1034, November 1987. 274 [RFC1035] Mockapetris, P., "Domain names - implementation and 275 specification", STD 13, RFC 1035, November 1987. 277 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 278 Requirement Levels", BCP 14, RFC 2119, March 1997. 280 [RFC6973] Cooper, A., Tschofenig, H., Aboba, B., Peterson, J., 281 Morris, J., Hansen, M., and R. Smith, "Privacy 282 Considerations for Internet Protocols", RFC 6973, July 283 2013. 285 [I-D.bortzmeyer-dnsop-dns-privacy] 286 Bortzmeyer, S., "DNS privacy problem statement", draft- 287 bortzmeyer-dnsop-dns-privacy-00 (work in progress), 288 November 2013. 290 5.2. Informative References 292 [RFC2181] Elz, R. and R. Bush, "Clarifications to the DNS 293 Specification", RFC 2181, July 1997. 295 [RFC4033] Arends, R., Austein, R., Larson, M., Massey, D., and S. 296 Rose, "DNS Security Introduction and Requirements", RFC 297 4033, March 2005. 299 [RFC5246] Dierks, T. and E. Rescorla, "The Transport Layer Security 300 (TLS) Protocol Version 1.2", RFC 5246, August 2008. 302 [RFC5936] Lewis, E. and A. Hoenes, "DNS Zone Transfer Protocol 303 (AXFR)", RFC 5936, June 2010. 305 [RFC6347] Rescorla, E. and N. Modadugu, "Datagram Transport Layer 306 Security Version 1.2", RFC 6347, January 2012. 308 [I-D.koch-perpass-dns-confidentiality] 309 Koch, P., "Confidentiality Aspects of DNS Data, 310 Publication, and Resolution", draft-koch-perpass-dns- 311 confidentiality-00 (work in progress), November 2013. 313 [I-D.vandergaast-edns-client-subnet] 314 Contavalli, C., Gaast, W., Leach, S., and E. Lewis, 315 "Client Subnet in DNS Requests", draft-vandergaast-edns- 316 client-subnet-02 (work in progress), July 2013. 318 [I-D.wijngaards-dnsop-confidentialdns] 319 Wijngaards, W., "Confidential DNS", draft-wijngaards- 320 dnsop-confidentialdns-00 (work in progress), November 321 2013. 323 [dnsop] IETF, , "The dnsop mailing list", October 2013. 325 [dagon-malware] 326 Dagon, D., "Corrupted DNS Resolution Paths: The Rise of a 327 Malicious Resolution Authority", 2007. 329 [dns-footprint] 330 Stoner, E., "DNS footprint of malware", October 2010. 332 [darkreading-dns] 333 Lemos, R., "Got Malware? Three Signs Revealed In DNS 334 Traffic", May 2013. 336 [dnschanger] 337 Wikipedia, , "DNSchanger", November 2011. 339 [dnscrypt] 340 Denis, F., "DNSCrypt", . 342 [dnscurve] 343 Bernstein, D., "DNScurve", . 345 [prism] NSA, , "PRISM", 2007. 347 [crime] Rizzo, J. and T. Dong, "The CRIME attack against TLS", 348 2012. 350 [ditl] , "A Day in the Life of the Internet (DITL)", 2002. 352 [data-protection-directive] 353 , "European directive 95/46/EC on the protection of 354 individuals with regard to the processing of personal data 355 and on the free movement of such data", November 1995. 357 [passive-dns] 358 Weimer, F., "Passive DNS Replication", April 2005. 360 [tor-leak] 361 , "DNS leaks in Tor", 2013. 363 Author's Address 365 Stephane Bortzmeyer 366 AFNIC 367 Immeuble International 368 Saint-Quentin-en-Yvelines 78181 369 France 371 Phone: +33 1 39 30 83 46 372 Email: bortzmeyer+ietf@nic.fr 373 URI: http://www.afnic.fr/