idnits 2.17.00 (12 Aug 2021) /tmp/idnits65375/draft-ietf-pkix-cmp-transport-protocols-04.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- ** Looks like you're using RFC 2026 boilerplate. This must be updated to follow RFC 3978/3979, as updated by RFC 4748. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- == There are 2 instances of lines with non-ascii characters in the document. == No 'Intended status' indicated for this document; assuming Proposed Standard == The page length should not exceed 58 lines per page, but there was 1 longer page, the longest (page 1) being 618 lines Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- ** The document seems to lack an Introduction section. ** 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 document seems to lack separate sections for Informative/Normative References. All references will be assumed normative when checking for downward references. ** There are 4 instances of too long lines in the document, the longest one being 3 characters in excess of 72. ** There are 13 instances of lines with control characters in the document. ** The abstract seems to contain references ([RFC2119], [CMP]), which it shouldn't. Please replace those with straight textual mentions of the documents in question. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the RFC 3978 Section 5.4 Copyright Line does not match the current year == The document seems to lack the recommended RFC 2119 boilerplate, even if it appears to use RFC 2119 keywords -- however, there's a paragraph with a matching beginning. Boilerplate error? (The document does seem to have the reference to RFC 2119 which the ID-Checklist requires). -- The document seems to lack a disclaimer for pre-RFC5378 work, but may have content which was first submitted before 10 November 2008. If you have contacted all the original authors and they are all willing to grant the BCP78 rights to the IETF Trust, then this is fine, and you can ignore this comment. If not, you may need to add the pre-RFC5378 disclaimer. (See the Legal Provisions document at https://trustee.ietf.org/license-info for more information.) -- Couldn't find a document date in the document -- date freshness check skipped. Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) == Unused Reference: 'HTTP' is defined on line 493, but no explicit reference was found in the text == Unused Reference: 'RFC821' is defined on line 499, but no explicit reference was found in the text ** Obsolete normative reference: RFC 2510 (Obsoleted by RFC 4210) == Outdated reference: draft-ietf-pkix-rfc2510bis has been published as RFC 4210 ** Obsolete normative reference: RFC 2616 (ref. 'HTTP') (Obsoleted by RFC 7230, RFC 7231, RFC 7232, RFC 7233, RFC 7234, RFC 7235) ** Obsolete normative reference: RFC 821 (Obsoleted by RFC 2821) ** Obsolete normative reference: RFC 2482 (Obsoleted by RFC 6082) ** Obsolete normative reference: RFC 3066 (Obsoleted by RFC 4646, RFC 4647) Summary: 12 errors (**), 0 flaws (~~), 8 warnings (==), 2 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 1 Internet Draft 2 PKIX Working Group Amit Kapoor (Certicom) 3 Expires in 6 months Ronald Tschal„r (Certicom) 5 November 24 2000 7 Transport Protocols for CMP 8 10 Status of this Memo 12 This document is an Internet-Draft and is in full conformance with 13 all provisions of Section 10 of RFC2026. 15 Internet-Drafts are working documents of the Internet Engineering 16 Task Force (IETF), its areas, and its working groups. Note that 17 other groups may also distribute working documents as 18 Internet-Drafts. 20 Internet-Drafts are draft documents valid for a maximum of six 21 months and may be updated, replaced, or obsoleted by other documents 22 at any time. It is inappropriate to use Internet-Drafts as 23 reference material or to cite them other than as "work in progress." 25 The list of current Internet-Drafts can be accessed at 26 http://www.ietf.org/ietf/1id-abstracts.txt 28 The list of Internet-Draft Shadow Directories can be accessed at 29 http://www.ietf.org/shadow.html. 31 This Internet-Draft will expire on May 24, 2001 33 Copyright Notice 35 Copyright (C) The Internet Society (2000). All Rights Reserved. 37 Abstract 39 This document describes how to layer Certificate Management 40 Protocols [CMP] over various transport protocols. 42 The key words "MUST", "MUST NOT", "REQUIRED", "SHOULD", "SHOULD 43 NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document (in 44 uppercase, as shown) are to be interpreted as described in 45 [RFC2119]. 47 1. Motivation 49 Section 5 of the [RFC2510] spec specifies how to exchange CMP 50 messages over various transports. However, implementors, during 51 various interoperability workshops, found the protocol lacking in 52 the following respects: 54 1. For CMP-over-TCP (section 5.2): 55 A. No clear definition on when the connection is to be 56 closed and by whom. 57 B. No version number specified to allow for extensions. 58 C. Error messages cannot be processed by applications. 60 2. For CMP-over-HTTP (section 5.4): 61 A. No support for polling 62 B. No specification of what to do in the case where there 63 is no CMP response message (e.g. after a pkiConf) 65 Realizing that this could not be achieved in a backward compatible 66 way, and acknowledging the changes being made to [RFC2510], the 67 decision was made to enhance the protocol now to avoid 68 interoperability conflicts later and to pull the transport section 69 out in a separate draft. This enhancement tries to keep as much of 70 the older protocol as possible, while ensuring that implementations 71 using the old protocol will not mistake a new message for a valid 72 message in the [RFC2510] format. 74 For CMP-over-HTTP a new content type is specified which carries a 75 TCP-message instead of a plain DER-encoded PKIMessage. 77 2. TCP-Based Management Protocol 79 While this section is called TCP-Based and the messages are called 80 TCP-message's, the same protocol can be used over any reliable, 81 connection oriented transport protocol (e.g. SNA, DECnet, etc.). 82 This protocol is suitable for cases where an end entity (or an RA) 83 initiates a transaction and can poll to pick up the results. 85 The client sends a TCP-message to the server, and the server 86 responds with another TCP-message. Note that a response MUST be 87 sent for every request, even if the encapsulated CMP message in the 88 request does not have a corresponding response. 90 The protocol basically assumes a listener process on an RA or CA 91 which can accept TCP-messages on a well-defined port (default port 92 number is 829). Typically a client initiates connection to the 93 server and submits a PKI message. The server replies with a PKI 94 message or with a reference number to be used later when polling 95 for the actual PKI message response. 97 If a polling-reference was supplied then the client will send a 98 polling request using this polling-reference after waiting for at 99 least the specified time. The server may again reply with a 100 polling-reference or with the actual PKI message response. 102 When the final PKI response message has been picked up by the 103 client then no new polling reference is supplied. 105 If a transaction is initiated by a PKI entity (RA or CA) then an 106 end entity must either supply a listener process or be supplied 107 with a polling reference (see below) in order to allow it to pick 108 up the PKI message from the PKI management component. 110 2.1 General Form 112 A TCP-message consists of: 114 length (32-bits) 115 version (8-bits) 116 flags (variable length) 117 message-type (8-bits), 118 value (defined below) 120 The length field contains the number of octets of the remainder of 121 the TCP-message (i.e., number of octets of plus 122 plus 2). All bit values in this protocol are specified to be in 123 network byte order. 125 The version field indicates the version of the TCP-message. It MUST 126 be incremented for each specification which changes the flags field 127 in a way that is not fully backwards compatible with the previous 128 version (e.g. when the length of the flags field is changed). 130 The flags field is for transporting TCP-message specific data. The 131 length of this field is version dependent and is fixed for a given 132 version. 134 The message-type field is used to indicate the type of TCP-message. 136 The value field contains message-type dependent data. 138 2.2 Version Negotiation 140 If a client knows the protocol version(s) supported by the 141 server (e.g. from a previous TCP-message exchange or via some 142 out-of-band means) then it SHOULD send a TCP-message with the highest 143 version supported both by it and the server. If a client does 144 not know what version(s) the server supports then it SHOULD send 145 a TCP-message using the highest version it supports. 147 If a server receives a TCP-message version that it supports, then it 148 MUST reply with a TCP-message of the same version. If the version 149 received is higher than what the server supports, it MUST send 150 back a VersionNotSupported errorMsgRep (defined below) containing 151 the highest version it supports. 153 2.3 TCP-message Version 10 155 The TCP-message version will be 10 for this document. The number 156 has deliberately been chosen to prevent [RFC2510] compliant 157 applications from treating it as a valid message type. Applications 158 receiving a version less than 10 SHOULD interpret the message as 159 being an [RFC2510] style message. 161 The length of the flags field for this version is 1 octet. The LSB 162 is used to indicate a connection close; all other bits in the flags 163 octet MUST be ignored by receivers, and MUST be set to zero by 164 senders. 166 By default connections are kept open after the receipt of a 167 response. Either party (client or server) MAY set the connection 168 close bit at any time. If the connection close bit is set on a 169 request, then the server MUST set the bit in the response and 170 close the connection after sending the response. If the bit is set 171 on a response from the server, the client MUST NOT send any further 172 requests on that connection. Applications MAY decide to close an 173 idle connection (one on which no response is outstanding) after 174 some time-out. Because of the problem where a client sends a 175 request and the server closes the connection while the request is 176 still in flight, clients SHOULD automatically retry a request for 177 which no part of the response could be read due to a connection 178 close or reset. 180 If the connection is kept open, it MUST only be used for subsequent 181 request/response transactions started by the client - the server 182 MUST NOT use it to send requests to the client. Different 183 transactions may be freely interwoven on the same connection. E.g. 184 a CR/CP need not immediately be followed by the Confirm, but may be 185 followed by any other request from a different transaction. 187 2.4 Detecting and Interoperating with RFC-2510 Conformant Implementations 189 Servers wishing to interoperate with clients conforming to 190 [RFC2510] can do so by treating any received message with a version 191 less than 10 as an [RFC2510] message and responding in that format. 192 Servers not wishing to support [RFC2510] messages MUST respond with 193 a [RFC2510] errorMsgRep. 195 Clients wishing to interoperate with [RFC2510] compliant servers 196 SHOULD treat a response with a version less than 10 as an [RFC2510] 197 style message. If this message is an errorMsgRep (message-type 06) 198 then the client MAY automatically retry the request using the 199 [RFC2510] format; if the message is not an errorMsgRep or the 200 implementation does not wish to support [RFC2510] then it MUST 201 abort the corresponding CMP transaction. 203 2.5 Message Types 205 message-types 0-127 are reserved and will be issued under IANA 206 auspices. message-types 128-255 are reserved for application use. 208 The message-type's currently defined are: 210 Message name Message-type 212 pkiReq '00'H 214 pollRep '01'H 216 pollReq '02'H 218 finRep '03'H 220 pkiRep '05'H 222 errorMsgRep '06'H 224 If server receives an unknown message-type then it MUST reply with 225 an InvalidMessageType errorMsgRep. If a client receives an unknown 226 message-type then it MUST abort the CMP transaction. 228 The different TCP-messages are discussed in the following sections: 230 2.5.1 pkiReq 232 The pkiReq is to be used to carry a PKIMessage from the client to the 233 server. The portion of this TCP-message will contain: 235 DER-encoded PKIMessage. 237 The type of PKIMessages that can be carried by this TCP-message are: 239 CRL Announcement 240 Certificate Confirmation 241 Poll Request 242 Subscription Request 243 CA Key Update Announcement 244 Certificate Announcement 245 Certification Request 246 Cross-Certification Request 247 Error Message 248 General Message 249 Initialization Request 250 Key Recovery Request 251 Key Update Request 252 Nested Message 253 PKCS-10 Request 254 POP Response 255 Revocation Request 257 2.5.2 pkiRep 259 This TCP-message is to be used to send back the response to the request. 260 The portion of the pkiRep will contain: 262 DER encoded PKI message 264 The type of PKIMessages that can be carried by this TCP-message are: 266 Confirmation 267 Poll Response 268 Subscription Response 269 Certification Response 270 Error Message 271 General Response 272 Initialization Response 273 Key Recovery Response 274 Key Update Response 275 POP Challenge 276 Revocation Response 278 2.5.3 pollReq 280 The pollReq will be the used by the client to check the status of a 281 pending TCP-message. The portion of the pollReq will 282 contain: 284 polling-reference (32 bits) 286 The MUST be the one returned via the pollRep 287 TCP-message. 289 2.5.4 pollRep 291 The pollRep will be the response sent by the server to the client 292 when there are no TCP-message response ready. The portion of 293 the pollRep will contain: 295 polling-reference (32 bits) 296 time-to-check-back (32 bits) 298 The is a unique 32-bit number sent by the server. 299 The is the time in seconds indicating the minimum 300 interval after which the client SHOULD check the status again. 302 The duration for which the server keeps the 303 unique is left to the implementation. 305 2.5.5 finRep 307 finRep is sent by the server whenever no other response applies 308 (such as after receiving a CMP pkiConf), and usually indicates 309 the end of the CMP transaction. The portion of the finRep 310 SHALL contain: 312 '00'H (8 bits) 314 2.5.6 errorMsgRep 316 This TCP-message is sent when a TCP-message level protocol error is 317 detected. Please note that PKIError messages MUST NOT be sent 318 using this. Examples of TCP-message level errors are: 320 1. Invalid protocol version 321 2. Invalid TCP message-type 322 3. Invalid polling reference number 324 The field of the TCP-message SHALL contain: 326 error-type (16-bits) 327 data-length (16-bits) 328 data ( octets) 329 UTF8 String (SHOULD include an [RFC3066] language tag, as 330 described in [RFC2482]) 332 The is of the form MMNN where M and N are hex digits 333 (0-F) and MM represents the major category and NN the minor. The 334 major categories defined by this specification are: 336 '01'H TCP-message version negotiation 337 '02'H client errors 338 '03'H server errors 340 The major categories '80'H-'FF'H are reserved for application use. 342 The and are additional information about the 343 error to be used by programs for further processing and recovery. 344 contains the length of the field in number of 345 octets. Error messages not needing additional information to be 346 conveyed MUST set the to 0. 348 The UTF8 text string is for user readable error messages. Note that 349 it does not contain a terminating null character at the end. 351 2.5.6.1 VersionNotSupported errorMsgRep 353 The VersionNotSupported errorMsgRep is defined as follows: 355 error-type: '0101'H 356 data-length: 1 357 data: 358 UTF8-text String: implementation defined 360 where is the highest version the server supports. 362 2.5.6.2 GeneralClientError errorMsgRep 364 The GeneralClientError errorMsgRep is defined as follows: 366 error-type: '0200'H 367 data-length: 0 368 data: 369 UTF8-text String: implementation defined 371 2.5.6.3 InvalidMessageType errorMsgRep 373 The InvalidMessageType errorMsgRep is defined as follows: 375 error-type: '0201'H 376 data-length: 1 377 data: 378 UTF8-text String: implementation defined 380 where is the message-type received by the 381 server. 383 2.5.6.4 InvalidPollID errorMsgRep 385 The InvalidPollID errorMsgRep is defined as follows: 387 error-type: '0202'H 388 data-length: 4 389 data: 390 UTF8-text String: implementation defined 392 where is the polling-reference received by 393 the server. 395 2.5.6.5 GeneralServerError errorMsgRep 397 The GeneralServerError errorMsgRep is defined as follows: 399 error-type: '0300'H 400 data-length: 0 401 data: 402 UTF8-text String: implementation defined 404 3. HTTP-Based Management Protocol 406 A client creates a TCP-message, as specified in section 2.0. The 407 message is then sent as the entity-body of an HTTP POST request. If 408 the HTTP request is successful then the server returns a similar 409 message in the body of the response. The response status code in 410 this case MUST be 200; other 2xx codes MUST NOT be used. The content 411 type of the request and response MUST be "application/pkixcmp-poll". 412 Applications MAY wish to also recognized and use the 413 "application/x-pkixcmp-poll" MIME type (specified in earlier 414 versions of this document) in order to support backward 415 compatibility wherever applicable. Content codings may be applied. 417 Note that a server may return any 1xx, 3xx, 4xx, or 5xx code if the 418 HTTP request needs further handling or is otherwise not acceptable. 420 Because in general CMP messages are not cacheable, requests and 421 responses should include a "Cache-Control: no-cache" (and, if either 422 side uses HTTP/1.0, a "Pragma: no-cache") to prevent the client from 423 getting cached responses. This is especially important for polling 424 requests and responses. 426 Connection management SHOULD be based on the HTTP provided mechanisms 427 (Connection and Proxy-Connection header fields) and not on the 428 connection flag carried in the TCP-message. 430 4. File based protocol 432 A file containing a PKI message MUST contain only the DER encoding of 433 one PKI message, i.e., there MUST be no extraneous header or trailer 434 information in the file. 436 Such files can be used to transport PKI messages using, e.g., FTP. 438 5. Mail based protocol 440 This subsection specifies a means for conveying ASN.1-encoded 441 messages for the protocol exchanges via Internet mail. 443 A simple MIME object is specified as follows. 445 Content-Type: application/pkixcmp 446 Content-Transfer-Encoding: base64 448 <> 450 This MIME object can be sent and received using common MIME 451 processing engines and provides a simple Internet mail transport for 452 PKIX-CMP messages. Implementations MAY wish to also recognize and 453 use the "application/x-pkixcmp" MIME type (specified in earlier 454 versions of this document) in order to support backward compatibility 455 wherever applicable. 457 6. Security Considerations 459 Three aspects need to be considered by server side implementors: 461 1. There is no security at the TCP and HTTP protocol level (unless 462 tunneled via SSL/TLS) and thus TCP-message should not be used 463 to change state of the transaction. Change of state should be 464 done on the signed PKIMessage being carried within the 465 TCP-message. 467 2. If the server is going to be sending messages with sensitive 468 information (not meant for public consumption) in the clear, it 469 is RECOMMENDED that the server send back the message directly 470 and not use the pollRep. 472 3. The polling request/response mechanism can be used for all kinds 473 of denial of service attacks. It is RECOMMENDED that the server 474 not change the polling-reference between polling requests. 476 7. Acknowledgments 478 The authors gratefully acknowledge the contributions of various 479 members of the IETF PKIX Working Group and the ICSA CA-talk mailing 480 list (a list solely devoted to discussing CMP interoperability 481 efforts). 483 8. References 485 [RFC2510] Adams, C., Farrell, S., "Internet X.509 Public Key 486 Infrastructure, Certificate Management Protocols", RFC 2510, 487 March 1999. 489 [CMP] Adams, C., Farrell, S., "Internet X.509 Public Key 490 Infrastructure, Certificate Management Protocols", 491 draft-ietf-pkix-rfc2510bis-01.txt, July 2000 493 [HTTP] Fielding, R.T., et. al, "Hypertext Transfer Protocol -- 494 HTTP/1.1", RFC 2616, June 1999. 496 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 497 Requirement Levels", RFC 2119, March 1997. 499 [RFC821] Postel, J., "Simple Mail Transfer Protocol", RFC 821, 500 August 1982. 502 [RFC2482] Whistler, K., Adams, G., "Language Tagging in Unicode 503 Plain Text", RFC 2482, January 1999. 505 [RFC3066] Alvestrand, H., "Tags for the Identification of 506 Languages", RFC 3066, January 2001. 508 Authors' Addresses 510 Amit Kapoor 511 Certicom 512 25801 Industrial Blvd 513 Hayward, CA 94545 514 US 516 E-Mail: amit@trustpoint.com 518 Ronald Tschal„r 519 Certicom 520 25801 Industrial Blvd 521 Hayward, CA 94545 522 US 524 E-Mail: ronald@trustpoint.com 526 Appendix A: Registration of MIME Type for Section 3 528 To: ietf-types@iana.org 529 Subject: Registration of MIME media type application/pkixcmp-poll 531 MIME media type name: application 533 MIME subtype name: pkixcmp-poll 535 Required parameters: none 537 Optional parameters: none 539 Encoding considerations: 540 Content may contain arbitrary octet values (the ASN.1 DER encoding of 541 a PKI message, as defined in the IETF PKIX Working Group 542 specifications). base64 encoding is required for MIME e-mail; no 543 encoding is necessary for HTTP. 545 Security considerations: 546 This MIME type may be used to transport Public-Key Infrastructure 547 (PKI) messages between PKI entities. These messages are defined by 548 the IETF PKIX Working Group and are used to establish and maintain an 549 Internet X.509 PKI. There is no requirement for specific security 550 mechanisms to be applied at this level if the PKI messages themselves 551 are protected as defined in the PKIX specifications. 553 Interoperability considerations: - 555 Published specification: this document 557 Applications which use this media type: 558 Applications using certificate management, operational, or ancillary 559 protocols (as defined by the IETF PKIX Working Group) to send PKI 560 messages via e-mail or HTTP. 562 Additional information: 564 Magic number (s): - 565 File extension (s): ".cmp" 566 Macintosh File Type Code (s): - 568 Person and email address to contact for further information: 569 Carlisle Adams, cadams@entrust.com 571 Intended usage: COMMON 573 Author/Change controller: Carlisle Adams 575 Full Copyright Statement 577 Copyright (C) The Internet Society (2000). All Rights Reserved. 579 This document and translations of it may be copied and furnished to 580 others, and derivative works that comment on or otherwise explain 581 it or assist in its implementation may be prepared, copied, 582 published and distributed, in whole or in part, without restriction 583 of any kind, provided that the above copyright notice and this 584 paragraph are included on all such copies and derivative works. 585 However, this document itself may not be modified in any way, such 586 as by removing the copyright notice or references to the Internet 587 Society or other Internet organizations, except as needed for the 588 purpose of developing Internet standards in which case the 589 procedures for copyrights defined in the Internet Standards process 590 must be followed, or as required to translate it into languages 591 other than English. 593 The limited permissions granted above are perpetual and will not be 594 revoked by the Internet Society or its successors or assigns. 596 This document and the information contained herein is provided on 597 an "AS IS" basis and THE INTERNET SOCIETY AND THE INTERNET 598 ENGINEERING TASK FORCE DISCLAIMS ALL WARRANTIES, EXPRESS OR 599 IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF 600 THE INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED 601 WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.