idnits 2.17.1 draft-ietf-dane-openpgpkey-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 : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year == The document doesn't use any RFC 2119 keywords, yet seems to have RFC 2119 boilerplate text. -- The document date (April 10, 2014) is 3668 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) == Missing Reference: 'TBD' is mentioned on line 255, but not defined == Unused Reference: 'RFC2181' is defined on line 301, but no explicit reference was found in the text -- No information found for draft-dane-openpgpkey-usage - is the name correct? -- Obsolete informational reference (is this intentional?): RFC 2822 (Obsoleted by RFC 5322) Summary: 0 errors (**), 0 flaws (~~), 4 warnings (==), 3 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group P. Wouters, Ed. 3 Internet-Draft Red Hat 4 Intended status: Standards Track April 10, 2014 5 Expires: October 12, 2014 7 Using DANE to Associate OpenPGP public keys with email addresses 8 draft-ietf-dane-openpgpkey-00 10 Abstract 12 OpenPGP is a message format for email (and file) encryption, that 13 lacks a standarized lookup mechanism to obtain OpenPGP public keys. 14 This document specifies a standarized method for securely publishing 15 and locating OpenPGP public keys in DNS using a new OPENPGPKEY DNS 16 Resource Record. 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 October 12, 2014. 35 Copyright Notice 37 Copyright (c) 2014 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 . . . . . . . . . . . . . . . . . . . . . . . . 2 53 1.1. Terminology . . . . . . . . . . . . . . . . . . . . . . . 3 54 2. The OPENPGPKEY Resource Record . . . . . . . . . . . . . . . 3 55 2.1. The OPENPGPKEY RDATA component . . . . . . . . . . . . . 3 56 2.2. The OPENPGPKEY RDATA wire format . . . . . . . . . . . . 3 57 2.3. The OPENPGPKEY RDATA presentation format . . . . . . . . 3 58 3. Location of the OpenPGPKEY record . . . . . . . . . . . . . . 4 59 4. OpenPGP Key size and DNS . . . . . . . . . . . . . . . . . . 4 60 5. Security Considerations . . . . . . . . . . . . . . . . . . . 5 61 5.1. Email address information leak . . . . . . . . . . . . . 5 62 5.2. Forward security of OpenPGP versus DNSSEC . . . . . . . . 5 63 6. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 6 64 6.1. OPENPGPKEY RRtype . . . . . . . . . . . . . . . . . . . . 6 65 7. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 6 66 8. References . . . . . . . . . . . . . . . . . . . . . . . . . 6 67 8.1. Normative References . . . . . . . . . . . . . . . . . . 6 68 8.2. Informative References . . . . . . . . . . . . . . . . . 7 69 Appendix A. Generating OPENPGPKEY records . . . . . . . . . . . 7 70 Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 8 72 1. Introduction 74 To encrypt a message to a target recipient using OpenPGP [RFC4880], 75 possession of the recipient's OpenPGP public key is required. To 76 obtain that public key, two problems need to be solved by the 77 sender's email client, MUA or MTA. Where does one find the 78 recipient's public key and how does one trust that the found key 79 actually belongs to the intended recipient. 81 Obtaining a public key is not a straightforward process as there are 82 no trusted standarized locations for publishing OpenPGP public keys 83 indexed by email address. Instead, OpenPGP clients rely on "well- 84 known key servers" that are accessed using the web based HKP protocol 85 or manually by users using a variety of differently formatted front- 86 end web pages. 88 Currently deployed key servers have no method of validating any 89 uploaded OpenPGP public key. The key servers simply store and 90 publish. Anyone can add public keys with any identities and anyone 91 can add signatures to any other public key using forged malicious 92 identities. Furthermore, once uploaded, public keys cannot be 93 deleted. People who did not pre-sign a key revocation can never 94 remove their public key from these key servers once they lost their 95 private key. 97 The lack of association of email address and public key lookup is 98 also preventing email clients, MTAs and MUAs from encrypting a 99 received message to the target receipient forcing the software to 100 send the message unencryped. Currently deployed MTA's only support 101 encrypting the transport of the email, not the email contents itself. 103 This document describes a mechanism to associate a user's OpenPGP 104 public key with their email address, using a new DNS RRtype. 106 The proposed new DNS Resource Record type is secured using DNSSEC. 107 This trust model is not meant to replace the "web of trust" model. 108 However, it can be used to encrypt a message that would otherwise 109 have to be sent out unencrypted, where it could be monitored by a 110 third party in transit or located in plaintext on a storage or email 111 server. 113 1.1. Terminology 115 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 116 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 117 document are to be interpreted as described in RFC 2119 [RFC2119]. 119 This document also makes use of standard DNSSEC and DANE terminology. 120 See DNSSEC [RFC4033], [RFC4034], [RFC4035], and DANE [RFC6698] for 121 these terms. 123 2. The OPENPGPKEY Resource Record 125 The OPENPGPKEY DNS resource record (RR) is used to associate an end 126 entity OpenPGP public key with an email address, thus forming a 127 "OpenPGP public key association". 129 The type value allocated for the OPENPGPKEY RR type is [TBD]. The 130 OPENPGPKEY RR is class independent. The OPENPGPKEY RR has no special 131 TTL requirements. 133 2.1. The OPENPGPKEY RDATA component 135 The RDATA (or RHS) of an OPENPGPKEY Resource Record contains a single 136 value consisting of a [RFC4880] formatted OpenPGP public keyring. 138 2.2. The OPENPGPKEY RDATA wire format 140 The RDATA Wire Format is the binary OpenPGP public keyring as 141 specified in [RFC4880] without any ascii armor or base64 encoding. 143 2.3. The OPENPGPKEY RDATA presentation format 144 The RDATA Presentation Format, as visible in textual zone files, 145 consists of the [RFC4880] formatted OpenPGP public keyring encoded in 146 Base64 [RFC4648] 148 3. Location of the OpenPGPKEY record 150 Email addresses are mapped into DNS using the following method: 152 1. The user name (the "left-hand side" of the email address, called 153 the "local-part" in the mail message format definition [RFC2822] 154 and the "local part" in the specification for internationalized 155 email [RFC6530]), is hashed using the SHA2-224 [RFC5754] 156 algorithm to become the left-most label in the prepared domain 157 name. This does not include the at symbol ("@") that separates 158 the left and right sides of the email address. 160 2. The DNS does not allow the use of all characters that are 161 supported in "local-part" of email addresses as defined in 162 [RFC2822] and [RFC6530] . The SHA2-224 hashing of the user name 163 ensures that none of these characters would need to be placed 164 directly in the DNS. 166 3. The string "_openpgpkey" becomes the second left-most label in 167 the prepared domain name. 169 4. The domain name (the "right-hand side" of the email address, 170 called the "domain" in RFC 2822) is appended to the result of 171 step 2 to complete the prepared domain name. 173 For example, to request an OPENPGPKEY resource record for a user 174 whose email address is "hugh@example.com", an OPENPGPKEY query would 175 be placed for the following QNAME: "8d5730bd8d76d417bf974c03f59eedb7a 176 f98cb5c3dc73ea8ebbd54b7._openpgpkey.example.com" The corresponding RR 177 in the example.com zone might look like (key shortened for 178 formatting): 180 8d[..]b7._openpgpkey.example.com. IN OPENPGPKEY 182 4. OpenPGP Key size and DNS 184 Although the reliability of the transport of large DNS Resoruce 185 Records has improved in the last years, it is still recommended to 186 keep the DNS records as small as possible without sacrificing the 187 security properties of the public key. The algorithm type and key 188 size of OpenPGP keys should not be modified to accomodate this 189 section. 191 OpenPGP supports various attributes that do not contribute to the 192 security of a key, such as an embedded image file. It is recommended 193 that these properties are not exported to OpenPGP public keyrings 194 that are used to create OPENPGPKEY Resource Records. Some OpenPGP 195 software, for example GnuPG, have support for a "minimal key export" 196 that is well suited to use as OPENPGPKEY RDATA. See Appendix A 198 5. Security Considerations 200 OPENPGPKEY usage considerations are published in [OPENPGPKEY-USAGE] 202 5.1. Email address information leak 204 Email addresses are not secret. Using them causes its publication. 205 The hashing of the user name in this document is not a security 206 feature. Publishing OPENPGPKEY records however, will create a list 207 of hashes of valid email addresses, which could simplify obtaining a 208 list of valid email addresses for a particular domain. It is 209 desirable to not ease the harvesting of email addresses where 210 possible. 212 The domain name part of the email address is not used as part of the 213 hash so that hashes can be used in multiple zones deployed using 214 DNAME [RFC6672]. This does makes it slightly easier and cheaper to 215 brute-force the SHA2-224 hashes into common and short user names, as 216 single rainbow tables can be re-used accross domains. This can be 217 somewhat countered by using NSEC3. 219 DNS zones that are signed with DNSSEC using NSEC for denial of 220 existence are susceptible to zone-walking, a mechanism that allows 221 someone to enumerate all the OPENPGPKEY hashes in a zone. This can 222 be used in combination with previously hashed common or short user 223 names (in rainbow tables) to deduce valid email addresses. DNSSEC- 224 signed zones using NSEC3 for denial of existence instead of NSEC are 225 significantly harder to brute-force after performing a zone-walk. 227 5.2. Forward security of OpenPGP versus DNSSEC 229 DNSSEC key sizes are chosen based on the fact that these keys can be 230 rolled with next to no requirement for security in the future. If 231 one doubts the strength or security of the DNSSEC key for whatever 232 reason, one simply rolls to a new DNSSEC key with a stronger 233 algorithm or larger key size. On the other hand, OpenPGP key sizes 234 are chosen based on how many years (or decades) their encryption 235 should remain unbreakable by adversaries that own large scale 236 computational resources. 238 This effectively means that anyone who can obtain a DNSSEC private 239 key of a domain name via coercion, theft or brute force calculations, 240 can replace any OPENPGPKEY record in that zone and all of the 241 delegated child zones, irrespective of the key size of the OpenPGP 242 keypair. Any future messages encrypted with the malicious OpenPGP 243 key could then be read. 245 Therefor, an OpenPGP key obtained via an OPENPGPKEY record can only 246 be trusted as much as the DNS domain can be trusted, and are no 247 substitute for in-person key verification of the "Web of Trust". See 248 [OPENPGPKEY-USAGE] for more in-depth information on safe usage of 249 OPENPGPKEY based OpenPGP keys. 251 6. IANA Considerations 253 6.1. OPENPGPKEY RRtype 255 This document uses a new DNS RR type, OPENPGPKEY, whose value [TBD] 256 has been allocated by IANA from the Resource Record (RR) TYPEs 257 subregistry of the Domain Name System (DNS) Parameters registry. 259 7. Acknowledgements 261 This document is based on RFC-4255 and draft-ietf-dane-smime whose 262 authors are Paul Hoffman, Jacob Schlyter and W. Griffin. Olafur 263 Gudmundsson provided feedback and suggested various improvements. 264 Willem Toorop contributed the gpg and hexdump command options. 266 8. References 268 8.1. Normative References 270 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 271 Requirement Levels", BCP 14, RFC 2119, March 1997. 273 [RFC4033] Arends, R., Austein, R., Larson, M., Massey, D., and S. 274 Rose, "DNS Security Introduction and Requirements", RFC 275 4033, March 2005. 277 [RFC4034] Arends, R., Austein, R., Larson, M., Massey, D., and S. 278 Rose, "Resource Records for the DNS Security Extensions", 279 RFC 4034, March 2005. 281 [RFC4035] Arends, R., Austein, R., Larson, M., Massey, D., and S. 282 Rose, "Protocol Modifications for the DNS Security 283 Extensions", RFC 4035, March 2005. 285 [RFC4648] Josefsson, S., "The Base16, Base32, and Base64 Data 286 Encodings", RFC 4648, October 2006. 288 [RFC4880] Callas, J., Donnerhacke, L., Finney, H., Shaw, D., and R. 289 Thayer, "OpenPGP Message Format", RFC 4880, November 2007. 291 [RFC5754] Turner, S., "Using SHA2 Algorithms with Cryptographic 292 Message Syntax", RFC 5754, January 2010. 294 8.2. Informative References 296 [OPENPGPKEY-USAGE] 297 Wouters, P., "Usage considerations with the DNS OPENPGPKEY 298 record", draft-dane-openpgpkey-usage (work in progress), 299 January 2014. 301 [RFC2181] Elz, R. and R. Bush, "Clarifications to the DNS 302 Specification", RFC 2181, July 1997. 304 [RFC2822] Resnick, P., "Internet Message Format", RFC 2822, April 305 2001. 307 [RFC3597] Gustafsson, A., "Handling of Unknown DNS Resource Record 308 (RR) Types", RFC 3597, September 2003. 310 [RFC6530] Klensin, J. and Y. Ko, "Overview and Framework for 311 Internationalized Email", RFC 6530, February 2012. 313 [RFC6672] Rose, S. and W. Wijngaards, "DNAME Redirection in the 314 DNS", RFC 6672, June 2012. 316 [RFC6698] Hoffman, P. and J. Schlyter, "The DNS-Based Authentication 317 of Named Entities (DANE) Transport Layer Security (TLS) 318 Protocol: TLSA", RFC 6698, August 2012. 320 Appendix A. Generating OPENPGPKEY records 322 The commonly available GnuPG software can be used to generate the 323 RRdata portion of an OPENPGPKEY record: 325 gpg --export --export-options export-minimal \ 326 hugh@example.com | base64 328 The --armor or -a option of the gpg command should NOT be used, as it 329 adds additional markers around the armored key. 331 When DNS software reading or signing the zone file does not yet 332 support the OPENPGPKEY RRtype, the Generic Record Syntax of [RFC3597] 333 can be used to generate the RDATA. One needs to calculate the number 334 of octets and the actual data in hexadecimal: 336 gpg --export --export-options export-minimal \ 337 hugh@example.com | wc -c 339 gpg --export --export-options export-minimal \ 340 hugh@example.com | hexdump -e \ 341 '"\t" /1 "%.2x"' -e '/32 "\n"' 343 These values can then be used to generate a generic record (line 344 break has been added for formatting): 346 ._openpgpkey.example.com. IN TYPE65280 \# \ 347 349 The openpgpkey command in the hash-slinger software can be used to 350 generate complete OPENPGPKEY records 352 ~> openpgpkey --output rfc hugh@example.com 353 8d[...]b7._openpgpkey.example.com. IN OPENPGPKEY mQCNAzIG[...] 355 ~> openpgpkey --output generic hugh@example.com 356 8d[...]b7._openpgpkey.example.com. IN TYPE65280 \# 2313 99008d03[...] 358 Author's Address 360 Paul Wouters (editor) 361 Red Hat 363 Email: pwouters@redhat.com