idnits 2.17.1 draft-dnsop-rfc5933-bis-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 date (July 7, 2020) is 1389 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: 'GOST3410' is mentioned on line 111, but not defined == Missing Reference: 'GOST3411' is mentioned on line 90, but not defined -- Looks like a reference, but probably isn't: '1' on line 343 -- Looks like a reference, but probably isn't: '2' on line 346 ** Downref: Normative reference to an Informational RFC: RFC 6986 ** Downref: Normative reference to an Informational RFC: RFC 7091 ** Downref: Normative reference to an Informational RFC: RFC 7836 Summary: 3 errors (**), 0 flaws (~~), 3 warnings (==), 3 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group D. Belyavskiy 3 Internet-Draft TCINET 4 Intended status: Standards Track V. Dolmatov, Ed. 5 Expires: January 8, 2021 JSC "NPK Kryptonite" 6 July 7, 2020 8 Use of GOST 2012 Signature Algorithms in DNSKEY and RRSIG Resource 9 Records for DNSSEC 10 draft-dnsop-rfc5933-bis-00 12 Abstract 14 This document describes how to produce digital signatures and hash 15 functions using the GOST R 34.10-2012 and GOST R 34.11-2012 16 algorithms for DNSKEY, RRSIG, and DS resource records, for use in the 17 Domain Name System Security Extensions (DNSSEC). 19 Status of This Memo 21 This Internet-Draft is submitted in full conformance with the 22 provisions of BCP 78 and BCP 79. 24 Internet-Drafts are working documents of the Internet Engineering 25 Task Force (IETF). Note that other groups may also distribute 26 working documents as Internet-Drafts. The list of current Internet- 27 Drafts is at https://datatracker.ietf.org/drafts/current/. 29 Internet-Drafts are draft documents valid for a maximum of six months 30 and may be updated, replaced, or obsoleted by other documents at any 31 time. It is inappropriate to use Internet-Drafts as reference 32 material or to cite them other than as "work in progress." 34 This Internet-Draft will expire on January 8, 2021. 36 Copyright Notice 38 Copyright (c) 2020 IETF Trust and the persons identified as the 39 document authors. All rights reserved. 41 This document is subject to BCP 78 and the IETF Trust's Legal 42 Provisions Relating to IETF Documents 43 (https://trustee.ietf.org/license-info) in effect on the date of 44 publication of this document. Please review these documents 45 carefully, as they describe your rights and restrictions with respect 46 to this document. Code Components extracted from this document must 47 include Simplified BSD License text as described in Section 4.e of 48 the Trust Legal Provisions and are provided without warranty as 49 described in the Simplified BSD License. 51 Table of Contents 53 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 54 1.1. Terminology . . . . . . . . . . . . . . . . . . . . . . . 3 55 2. DNSKEY Resource Records . . . . . . . . . . . . . . . . . . . 3 56 2.1. Using a Public Key with Existing Cryptographic Libraries 3 57 2.2. GOST DNSKEY RR Example . . . . . . . . . . . . . . . . . 4 58 3. RRSIG Resource Records . . . . . . . . . . . . . . . . . . . 4 59 3.1. RRSIG RR Example . . . . . . . . . . . . . . . . . . . . 4 60 4. DS Resource Records . . . . . . . . . . . . . . . . . . . . . 5 61 4.1. DS RR Example . . . . . . . . . . . . . . . . . . . . . . 5 62 5. Deployment Considerations . . . . . . . . . . . . . . . . . . 5 63 5.1. Key Sizes . . . . . . . . . . . . . . . . . . . . . . . . 5 64 5.2. Signature Sizes . . . . . . . . . . . . . . . . . . . . . 5 65 5.3. Digest Sizes . . . . . . . . . . . . . . . . . . . . . . 5 66 6. Implementation Considerations . . . . . . . . . . . . . . . . 6 67 6.1. Support for GOST Signatures . . . . . . . . . . . . . . . 6 68 7. Security Considerations . . . . . . . . . . . . . . . . . . . 6 69 8. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 6 70 9. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 6 71 10. References . . . . . . . . . . . . . . . . . . . . . . . . . 7 72 10.1. Normative References . . . . . . . . . . . . . . . . . . 7 73 10.2. Informative References . . . . . . . . . . . . . . . . . 8 74 10.3. URIs . . . . . . . . . . . . . . . . . . . . . . . . . . 8 75 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 8 77 1. Introduction 79 The Domain Name System (DNS) is the global hierarchical distributed 80 database for Internet Naming. The DNS has been extended to use 81 cryptographic keys and digital signatures for the verification of the 82 authenticity and integrity of its data. RFC 4033 [RFC4033], RFC 4034 83 [RFC4034], and RFC 4035 [RFC4035] describe these DNS Security 84 Extensions, called DNSSEC. 86 RFC 4034 describes how to store DNSKEY and RRSIG resource records, 87 and specifies a list of cryptographic algorithms to use. This 88 document extends that list with the signature and hash algorithms 89 GOST R 34.10-2012 ([GOST3410], [RFC7091]) and GOST R 34.11-2012 90 ([GOST3411], [RFC6986]), and specifies how to store DNSKEY data and 91 how to produce RRSIG resource records with these algorithms. 93 Familiarity with DNSSEC and with GOST signature and hash algorithms 94 is assumed in this document. 96 1.1. Terminology 98 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 99 "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and 100 "OPTIONAL" in this document are to be interpreted as described in BCP 101 14 [RFC2119] [RFC8174] when, and only when, they appear in all 102 capitals, as shown here. 104 2. DNSKEY Resource Records 106 The format of the DNSKEY RR can be found in RFC 4034 [RFC4034]. 108 GOST R 34.10-2012 public keys are stored with the algorithm number 109 TBA1. 111 According to [GOST3410] and [RFC7091], a public key is a point on the 112 elliptic curve Q = (x,y). The wire representation of a public key 113 MUST contain 64 octets, where the first 32 octets contain the little- 114 endian representation of x and the second 32 octets contain the 115 little-endian representation of y. 117 As GOST3410 and GOST3411 allows 2 variants of length of the output 118 hash and signature and many variants of parameters of the digital 119 signature, for the purpose of this document we use 256-bit variant of 120 the digital signature algorithm, corresponding 256-bit variant of the 121 digest algorithm. We select the parameters for the digital signature 122 algorithm to be id-tc26-gost-3410-2012-256-paramSetA in RFC 7836 123 [RFC7836]. 125 2.1. Using a Public Key with Existing Cryptographic Libraries 127 At the time of this writing, existing GOST-aware cryptographic 128 libraries are capable of reading GOST public keys via a generic X509 129 API if the key is encoded according to RFC 7091 [RFC7091], 130 Section 2.3.2. 132 To make this encoding from the wire format of a GOST public key with 133 the parameters used in this document, prepend the 64 octets of key 134 data with the following 32-byte sequence: 136 0x30 0x5e 0x30 0x17 0x06 0x08 0x2a 0x85 0x03 0x07 0x01 0x01 0x01 137 0x01 0x30 0x0b 0x06 0x09 0x2a 0x85 0x03 0x07 0x01 0x02 0x01 0x01 138 0x01 0x03 0x43 0x00 0x04 0x40 140 2.2. GOST DNSKEY RR Example 142 Given a private key with the following value (the value of the 143 Gost12Asn1 field is split here into two lines to simplify reading; in 144 the private key file, it must be in one line): 146 Private-key-format: v1.2 147 Algorithm: 23 (ECC-GOST12) 148 Gost12Asn1: MD4CAQAwFwYIKoUDBwEBAQEwCwYJKoUDBwECAQEBBCA0zvTDpCSjdRCERkd6 149 WDA2TF/ABQLp9MPZRl7hMXCVGg== 151 The following DNSKEY RR stores a DNS zone key for example: 153 example. 600 IN DNSKEY 256 3 23 XkZ6T+qQ9teOMsA/YK+kTzE 154 LhuMPTsYggdy2b+sfzJ6tH9eniziMX3gjMnUZIyrnSIchLjup8xpy+ 155 UU5l1Eyjw== ;{id = 13439 (zsk), size = 512b} 157 3. RRSIG Resource Records 159 The value of the signature field in the RRSIG RR follows RFC 7091 160 [RFC7091] and is calculated as follows. The values for the RDATA 161 fields that precede the signature data are specified in RFC 4034 162 [RFC4034]. 164 hash = GOSTR3411-2012(data) 166 where "data" is the wire format data of the resource record set that 167 is signed, as specified in RFC 4034 [RFC4034]. 169 The signature is calculated from the hash according to the GOST R 170 34.10-2012 standard, and its wire format is compatible with RFC 7091 171 [RFC7091]. 173 3.1. RRSIG RR Example 175 With the private key from this document, consisting of one MX record: 177 example. 600 IN MX 10 mail.example. 179 Setting the inception date to 2020-01-04 17:25:26 UTC and the 180 expiration date to 2020-02-01 17:25:26 UTC, the following signature 181 RR will be valid: 183 example. 600 IN RRSIG MX 23 1 600 20200201172526 ( 184 20200104172526 13439 example. Etrs 185 AEGsNRf12HKjwNTg8U2HZ5JOSo34UaTcsho 186 E1kwd5Ror4I7zltmWAgd4b9OBn80tsajtL0 187 Vuf45u8kEAgA== 189 ) 191 Note: The ECC-GOST12 signature algorithm uses random data, so the 192 actual computed signature value will differ between signature 193 calculations. 195 4. DS Resource Records 197 The GOST R 34.11-2012 digest algorithm is denoted in DS RRs by the 198 digest type TBA2. The wire format of a digest value is compatible 199 with RFC 6986 [RFC6986]. 201 4.1. DS RR Example 203 For Key Signing Key (KSK): 205 example. IN DNSKEY 257 3 23 hP3ISWPT8ehEEut8ozbqPcmbTAQK0jce7MHmK 206 0geOiRokFALGwsMrBf0H0AK2qrVJCWCJL+50v9UNZAS5mE70g== ;{id = 7574 207 (ksk), size = 512b} 209 The DS RR will be 211 example. IN DS 7574 23 5 212 990f40dc548a4dbcb4b80a0760f194ac0cc18484578834c1ac1f749f70c84103 214 5. Deployment Considerations 216 5.1. Key Sizes 218 The key size of GOST public keys conforming to this specification 219 MUST be 512 bits. 221 5.2. Signature Sizes 223 The size of a GOST signature conforming to this specification MUST be 224 512 bits. 226 5.3. Digest Sizes 228 The size of a GOST digest conforming to this specification MUST be 229 256 bits. 231 6. Implementation Considerations 233 6.1. Support for GOST Signatures 235 DNSSEC-aware implementations MAY be able to support RRSIG and DNSKEY 236 resource records created with the GOST algorithms as defined in this 237 document. 239 7. Security Considerations 241 Currently, the cryptographic resistance of the GOST R 34.10-2012 242 digital signature algorithm is estimated as 2**128 operations of 243 multiple elliptic curve point computations on prime modulus of order 244 2**256. 246 Currently, the cryptographic collision resistance of the GOST R 247 34.11-2012 hash algorithm is estimated as 2**128 operations of 248 computations of a step hash function. 250 8. IANA Considerations 252 This document updates the IANA registry "DNS Security Algorithm 253 Numbers" [1] The following entries have been added to the registry: 255 Zone Trans. 256 Value Algorithm Mnemonic Signing Sec. References Status 257 TBA1 GOST R 34.10-2012 ECC-GOST12 Y * RFC TBA OPTIONAL 259 This document updates the RFC IANA registry "Delegation Signer (DS) 260 Resource Record (RR) Type Digest Algorithms" [2] by adding an entry 261 for the GOST R 34.11-2012 algorithm: 263 Value Algorithm Status 264 TBA2 GOST R 34.11-2012 OPTIONAL 266 This paragraph shoud be removed before the publication of RFC: For 267 the purpose of example computations, the following values were used: 268 TBA1 = 23, TBA2 = 5. 270 9. Acknowledgments 272 This document is a minor extension to RFC 4034 [RFC4034]. Also, we 273 tried to follow the documents RFC 3110 [RFC3110], RFC 4509 [RFC4509], 274 and RFC 5933 [RFC5933] for consistency. The authors of and 275 contributors to these documents are gratefully acknowledged for their 276 hard work. 278 The following people provided additional feedback, text, and valuable 279 assistance: Alexander Venedyukhin, Valery Smyslov, TODO 281 10. References 283 10.1. Normative References 285 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 286 Requirement Levels", BCP 14, RFC 2119, 287 DOI 10.17487/RFC2119, March 1997, 288 . 290 [RFC3110] Eastlake 3rd, D., "RSA/SHA-1 SIGs and RSA KEYs in the 291 Domain Name System (DNS)", RFC 3110, DOI 10.17487/RFC3110, 292 May 2001, . 294 [RFC4033] Arends, R., Austein, R., Larson, M., Massey, D., and S. 295 Rose, "DNS Security Introduction and Requirements", 296 RFC 4033, DOI 10.17487/RFC4033, March 2005, 297 . 299 [RFC4034] Arends, R., Austein, R., Larson, M., Massey, D., and S. 300 Rose, "Resource Records for the DNS Security Extensions", 301 RFC 4034, DOI 10.17487/RFC4034, March 2005, 302 . 304 [RFC4035] Arends, R., Austein, R., Larson, M., Massey, D., and S. 305 Rose, "Protocol Modifications for the DNS Security 306 Extensions", RFC 4035, DOI 10.17487/RFC4035, March 2005, 307 . 309 [RFC6986] Dolmatov, V., Ed. and A. Degtyarev, "GOST R 34.11-2012: 310 Hash Function", RFC 6986, DOI 10.17487/RFC6986, August 311 2013, . 313 [RFC7091] Dolmatov, V., Ed. and A. Degtyarev, "GOST R 34.10-2012: 314 Digital Signature Algorithm", RFC 7091, 315 DOI 10.17487/RFC7091, December 2013, 316 . 318 [RFC7836] Smyshlyaev, S., Ed., Alekseev, E., Oshkin, I., Popov, V., 319 Leontiev, S., Podobaev, V., and D. Belyavsky, "Guidelines 320 on the Cryptographic Algorithms to Accompany the Usage of 321 Standards GOST R 34.10-2012 and GOST R 34.11-2012", 322 RFC 7836, DOI 10.17487/RFC7836, March 2016, 323 . 325 [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 326 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, 327 May 2017, . 329 10.2. Informative References 331 [RFC4509] Hardaker, W., "Use of SHA-256 in DNSSEC Delegation Signer 332 (DS) Resource Records (RRs)", RFC 4509, 333 DOI 10.17487/RFC4509, May 2006, 334 . 336 [RFC5933] Dolmatov, V., Ed., Chuprina, A., and I. Ustinov, "Use of 337 GOST Signature Algorithms in DNSKEY and RRSIG Resource 338 Records for DNSSEC", RFC 5933, DOI 10.17487/RFC5933, July 339 2010, . 341 10.3. URIs 343 [1] https://www.iana.org/assignments/dns-sec-alg-numbers/dns-sec-alg- 344 numbers.xhtml#dns-sec-alg-numbers-1 346 [2] https://www.iana.org/assignments/ds-rr-types/ds-rr- 347 types.xhtml#ds-rr-types-1 349 Authors' Addresses 351 Dmitry Belyavskiy 352 TCINET 353 8 marta st 354 Moscow 355 Russian Federation 357 Phone: +7 916 262 5593 358 Email: beldmit@gmail.com 360 Vasily Dolmatov (editor) 361 JSC "NPK Kryptonite" 362 Spartakovskaya sq., 14, bld 2, JSC "NPK Kryptonite" 363 Moscow 105082 364 Russian Federation 366 Email: vdolmatov@gmail.com