idnits 2.17.1 draft-kohler-dcp-04.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- ** Cannot find the required boilerplate sections (Copyright, IPR, etc.) in this document. Expected boilerplate is as follows today (2024-04-25) according to https://trustee.ietf.org/license-info : IETF Trust Legal Provisions of 28-dec-2009, Section 6.a: This Internet-Draft is submitted in full conformance with the provisions of BCP 78 and BCP 79. IETF Trust Legal Provisions of 28-dec-2009, Section 6.b(i), paragraph 2: Copyright (c) 2024 IETF Trust and the persons identified as the document authors. All rights reserved. IETF Trust Legal Provisions of 28-dec-2009, Section 6.b(i), paragraph 3: This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (https://trustee.ietf.org/license-info) in effect on the date of publication of this document. Please review these documents carefully, as they describe your rights and restrictions with respect to this document. Code Components extracted from this document must include Simplified BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Simplified BSD License. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- ** The document seems to lack a 1id_guidelines paragraph about Internet-Drafts being working documents. == No 'Intended status' indicated for this document; assuming Proposed Standard Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- ** The document seems to lack separate sections for Informative/Normative References. All references will be assumed normative when checking for downward references. ** There are 18 instances of too long lines in the document, the longest one being 6 characters in excess of 72. ** The document seems to lack a both a reference to RFC 2119 and the recommended RFC 2119 boilerplate, even if it appears to use RFC 2119 keywords. RFC 2119 keyword, line 310: '... host MUST NOT respond to a DCCP-Re...' RFC 2119 keyword, line 315: '...ctions as a unit. However, DCCP SHOULD...' RFC 2119 keyword, line 370: '...like the server to use. The client MAY...' RFC 2119 keyword, line 372: '...st, say---which the server MAY ignore....' RFC 2119 keyword, line 379: '...mation and which MUST be returned by t...' (88 more instances...) Miscellaneous warnings: ---------------------------------------------------------------------------- -- 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.) -- The document date (19 June 2002) is 7981 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: 'RFC3124' is mentioned on line 219, but not defined == Missing Reference: 'Nonce 0' is mentioned on line 2316, but not defined == Missing Reference: 'Nonce 1' is mentioned on line 2316, but not defined == Unused Reference: 'RFC 1889' is defined on line 2609, but no explicit reference was found in the text ** Obsolete normative reference: RFC 793 (Obsoleted by RFC 9293) ** Obsolete normative reference: RFC 1889 (Obsoleted by RFC 3550) ** Obsolete normative reference: RFC 2460 (Obsoleted by RFC 8200) ** Obsolete normative reference: RFC 2960 (Obsoleted by RFC 4960) -- Possible downref: Non-RFC (?) normative reference: ref. 'SB00' == Outdated reference: A later version (-04) exists of draft-ietf-tsvwg-tcp-nonce-00 ** Downref: Normative reference to an Historic draft: draft-ietf-tsvwg-tcp-nonce (ref. 'WES01') Summary: 10 errors (**), 0 flaws (~~), 6 warnings (==), 3 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 1 Internet Engineering Task Force 2 INTERNET-DRAFT Eddie Kohler 3 draft-kohler-dcp-04.txt Mark Handley 4 Sally Floyd 5 ICIR 6 Jitendra Padhye 7 Microsoft Research 8 19 June 2002 9 Expires: December 2002 11 Datagram Congestion Control Protocol (DCCP) 13 Status of this Document 15 This document is an Internet-Draft and is in full conformance with 16 all provisions of Section 10 of [RFC 2026]. Internet-Drafts are 17 working documents of the Internet Engineering Task Force (IETF), its 18 areas, and its working groups. Note that other groups may also 19 distribute working documents as Internet-Drafts. 21 Internet-Drafts are draft documents valid for a maximum of six 22 months and may be updated, replaced, or obsoleted by other documents 23 at any time. It is inappropriate to use Internet-Drafts as reference 24 material or to cite them other than as "work in progress." 26 The list of current Internet-Drafts can be accessed at 27 http://www.ietf.org/ietf/1id-abstracts.txt 29 The list of Internet-Draft Shadow Directories can be accessed at 30 http://www.ietf.org/shadow.html. 32 Abstract 34 This document specifies the Datagram Congestion Control 35 Protocol (DCCP), which implements a congestion-controlled, 36 unreliable flow of datagrams suitable for use by applications 37 such as streaming media. 39 Table of Contents 41 1. Introduction. . . . . . . . . . . . . . . . . . . . . . 4 42 2. Design Rationale. . . . . . . . . . . . . . . . . . . . 5 43 3. Concepts and Terminology. . . . . . . . . . . . . . . . 6 44 3.1. Anatomy of a DCCP Connection . . . . . . . . . . . . 6 45 3.2. Congestion Control . . . . . . . . . . . . . . . . . 7 46 3.3. Connection Initiation and Termination. . . . . . . . 7 47 3.4. Features . . . . . . . . . . . . . . . . . . . . . . 8 48 4. DCCP Packets. . . . . . . . . . . . . . . . . . . . . . 8 49 4.1. Examples of DCCP Congestion Control. . . . . . . . . 10 50 4.1.1. DCCP with TCP-like Congestion Control . . . . . . 10 51 4.1.2. DCCP with TFRC Congestion Control . . . . . . . . 12 52 4.2. DCCP Generic Packet Header . . . . . . . . . . . . . 13 53 4.3. Sequence Number Validity . . . . . . . . . . . . . . 15 54 4.4. DCCP State Diagram . . . . . . . . . . . . . . . . . 16 55 4.5. DCCP-Request Packet Format . . . . . . . . . . . . . 17 56 4.6. DCCP-Response Packet Format. . . . . . . . . . . . . 18 57 4.7. DCCP-Data, DCCP-Ack, and DCCP-DataAck Packet 58 Formats . . . . . . . . . . . . . . . . . . . . . . . . . 19 59 4.8. DCCP-CloseReq and DCCP-Close Packet Format . . . . . 20 60 4.9. DCCP-Reset Packet Format . . . . . . . . . . . . . . 21 61 4.10. DCCP-Move Packet Format . . . . . . . . . . . . . . 21 62 5. Options and Features. . . . . . . . . . . . . . . . . . 23 63 5.1. Padding Option . . . . . . . . . . . . . . . . . . . 24 64 5.2. Ignored Option . . . . . . . . . . . . . . . . . . . 24 65 5.3. Feature Negotiation. . . . . . . . . . . . . . . . . 25 66 5.3.1. Feature Numbers . . . . . . . . . . . . . . . . . 25 67 5.3.2. Change Option . . . . . . . . . . . . . . . . . . 26 68 5.3.3. Prefer Option . . . . . . . . . . . . . . . . . . 26 69 5.3.4. Confirm Option. . . . . . . . . . . . . . . . . . 26 70 5.3.5. Example Negotiations. . . . . . . . . . . . . . . 26 71 5.3.6. Unknown Features. . . . . . . . . . . . . . . . . 27 72 5.3.7. State Diagram . . . . . . . . . . . . . . . . . . 27 73 5.4. Connection Nonce Options . . . . . . . . . . . . . . 31 74 5.4.1. Connection Nonce Feature. . . . . . . . . . . . . 31 75 5.4.2. Connection Proof Option . . . . . . . . . . . . . 32 76 5.4.3. Identify Yourself Option. . . . . . . . . . . . . 32 77 5.5. Data Discarded Option. . . . . . . . . . . . . . . . 32 78 5.6. Init Cookie Option . . . . . . . . . . . . . . . . . 33 79 5.7. Timestamp Option . . . . . . . . . . . . . . . . . . 33 80 5.8. Timestamp Echo Option. . . . . . . . . . . . . . . . 34 81 5.9. Loss Window Feature. . . . . . . . . . . . . . . . . 34 82 6. Congestion Control IDs. . . . . . . . . . . . . . . . . 34 83 6.1. Unspecified Sender-Based Congestion Control. . . . . 35 84 6.2. TCP-like Congestion Control. . . . . . . . . . . . . 36 85 6.3. TFRC Congestion Control. . . . . . . . . . . . . . . 36 86 6.4. CCID-Specific Options and Features . . . . . . . . . 36 87 7. Acknowledgements. . . . . . . . . . . . . . . . . . . . 37 88 7.1. Acks of Acks and Unidirectional Connections. . . . . 37 89 7.2. Ack Piggybacking . . . . . . . . . . . . . . . . . . 39 90 7.3. Ack Ratio Feature. . . . . . . . . . . . . . . . . . 39 91 7.4. Use Ack Vector Feature . . . . . . . . . . . . . . . 40 92 7.5. Ack Vector Options . . . . . . . . . . . . . . . . . 40 93 7.5.1. Ack Vector Consistency. . . . . . . . . . . . . . 42 94 7.5.2. Ack Vector Coverage . . . . . . . . . . . . . . . 43 95 7.6. Slow Receiver Option . . . . . . . . . . . . . . . . 43 96 7.7. Receive Buffer Drops Option. . . . . . . . . . . . . 44 97 7.8. Buffer Closed Drops Option . . . . . . . . . . . . . 45 98 7.9. Ack Vector Implementation Notes. . . . . . . . . . . 46 99 7.9.1. New Packets . . . . . . . . . . . . . . . . . . . 47 100 7.9.2. Sending Acknowledgements. . . . . . . . . . . . . 48 101 7.9.3. Clearing State. . . . . . . . . . . . . . . . . . 49 102 7.9.4. Processing Acknowledgements . . . . . . . . . . . 50 103 8. Explicit Congestion Notification. . . . . . . . . . . . 51 104 8.1. ECN Capable Feature. . . . . . . . . . . . . . . . . 51 105 8.2. ECN Nonces . . . . . . . . . . . . . . . . . . . . . 52 106 9. Multihoming and Mobility. . . . . . . . . . . . . . . . 53 107 9.1. Mobility Capable Feature . . . . . . . . . . . . . . 53 108 9.2. Security . . . . . . . . . . . . . . . . . . . . . . 54 109 9.3. Congestion Control State . . . . . . . . . . . . . . 54 110 9.4. Loss During Transition . . . . . . . . . . . . . . . 54 111 10. Path MTU Discovery . . . . . . . . . . . . . . . . . . 55 112 11. Abstract API . . . . . . . . . . . . . . . . . . . . . 56 113 12. Multiplexing Issues. . . . . . . . . . . . . . . . . . 56 114 13. DCCP and RTP . . . . . . . . . . . . . . . . . . . . . 57 115 14. Security Considerations. . . . . . . . . . . . . . . . 57 116 15. IANA Considerations. . . . . . . . . . . . . . . . . . 57 117 16. Thanks . . . . . . . . . . . . . . . . . . . . . . . . 58 118 17. References . . . . . . . . . . . . . . . . . . . . . . 58 119 18. Authors' Addresses . . . . . . . . . . . . . . . . . . 59 121 1. Introduction 123 This document specifies the Datagram Congestion Control Protocol 124 (DCCP). DCCP provides the following features: 126 o An unreliable flow of datagrams, with acknowledgements. 128 o A reliable handshake for connection setup and teardown. 130 o Reliable negotiation of options, including negotiation of a 131 suitable congestion control mechanism. 133 o Mechanisms allowing a server to avoid holding any state for 134 unacknowledged connection attempts or already-finished 135 connections. 137 o An optional mechanism that allows the sender to know, with high 138 reliability, which packets reached the receiver. 140 o Congestion control incorporating Explicit Congestion Notification 141 (ECN) and the ECN Nonce, as per [RFC 3168] and [WES01]. 143 o Path MTU discovery, as per [RFC 1191]. 145 DCCP is intended for applications that require the flow-based 146 semantics of TCP, but which do not want TCP's in-order delivery and 147 reliability semantics, or which would like different congestion 148 control dynamics than TCP. Similarly, DCCP is intended for 149 applications that do not require the features of SCTP [RFC 2960] 150 such as sequenced delivery within multiple streams. 152 The sort of applications which could make use of DCCP are those 153 which have timing constraints on the delivery of data, such that 154 reliable in-order delivery, when combined with congestion control, 155 is likely to result in some information arriving at the receiver 156 after it is no longer of use. Such applications might include 157 streaming media and Internet telephony. 159 To date most such applications have used either TCP, with the 160 problems described above, or used UDP and implemented their own 161 congestion control mechanisms (or no congestion control at all). The 162 purpose of DCCP is to provide a standard way to implement congestion 163 control and congestion control negotiation for such applications. 164 One of the motivations for DCCP is to enable the use of ECN, along 165 with conformant end-to-end congestion control, for applications that 166 otherwise would be using UDP. In addition, DCCP implements reliable 167 connection setup, teardown, and feature negotiation. 169 A DCCP connection contains acknowledgement traffic as well as data 170 traffic. Acknowledgements inform a sender whether its packets 171 arrived, and whether they were ECN marked. Acks are transmitted as 172 reliably as the congestion control mechanism in use requires, 173 possibly up to completely reliably. 175 Previous drafts of this specification called the protocol DCP, or 176 Datagram Control Protocol. The name was changed to make the acronym 177 sound less like "TCP". 179 2. Design Rationale 181 One of the motivations behind the design of DCCP is to make DCCP as 182 low-overhead as possible, in terms both of the size of the packet 183 header and in terms of the state and CPU overhead required at the 184 end hosts. In particular, DCCP is designed to minimize the state 185 maintained by the data sender. DCCP is intended to be used by 186 applications that currently now use UDP without end-to-end 187 congestion control. The desire is for many applications to have 188 little reason not to use DCCP instead of UDP, once DCCP is deployed. 190 This desire for minimal overhead results in the design decision to 191 add only the minimal necessary functionality to DCCP, and to leave 192 other functionality such as FEC or semi-reliability to the 193 application, to be layered on top of DCCP as desired. The desire 194 for minimal overhead is also one of the reasons to propose DCCP 195 instead of just proposing an unreliable version of SCTP for 196 applications currently using UDP. 198 Mechanisms for multi-homing and mobility are the one area of 199 additional functionality that can not necessarily be layered cleanly 200 and effectively on top of DCCP. Thus, the one outstanding design 201 decision with DCCP concerns whether to incorporate mechanisms for 202 multi-homing and mobility into DCCP itself. 204 A second motivation behind the design of DCCP is to allow 205 applications to choose an alternative to the current TCP-style 206 congestion control that halves the congestion window in response to 207 a congestion indication. Thus, DCCP is designed to allow 208 applications to choose between several forms of congestion control. 209 The first, TCP-like congestion control, halves the congestion window 210 in response to a packet drop or mark, as in TCP. A second 211 alternative, TFRC (TCP-Friendly Rate Control), is a form of 212 equation-based congestion control that minimized abrupt changes in 213 the sending rate, while maintaining longer-term fairness with TCP. 215 In proposing a new transport protocol, it is necessary to justify 216 the design decision not to require the use of the Congestion 217 Manager, as well as the design decision to add a new transport 218 protocol to the current family of UDP, TCP, and SCTP. The 219 Congestion Manager [RFC3124] allows multiple concurrent streams 220 between the same sender and receiver to share congestion control. 221 However, the current Congestion Manager can only be used by 222 applications that have their own end-to-end feedback about packet 223 losses, and this is not the case for many of the applications 224 currently using UDP. In addition, the current Congestion Manager 225 does not lend itself to the use of forms of TFRC where the state 226 about past packet drops or marks is maintained at the receiver 227 rather than at the sender. In addition, while we would like for 228 DCCP to be able to make use of CM where desired by the application, 229 we do not see any benefit in making the deployment of DCCP 230 contingent on the deployment of CM itself. 232 3. Concepts and Terminology 234 3.1. Anatomy of a DCCP Connection 236 Each DCCP connection runs between two endpoints, which we often name 237 DCCP A and DCCP B. Data may pass over the connection in either or 238 both directions. The DCCP connection between DCCP A and DCCP B 239 consists of four sets of packets, as follows: 241 (1) Data packets from DCCP A to DCCP B. 243 (2) Acknowledgements from DCCP B to DCCP A. 245 (3) Data packets from DCCP B to DCCP A. 247 (4) Acknowledgements from DCCP A to DCCP B. 249 We use the following terms to refer to subsets and endpoints of a 250 DCCP connection. 252 Subflows 253 A subflow consists of either data or acknowledgement packets, 254 sent in one direction (from DCCP A to DCCP B, say). Each of the 255 four sets of packets above is a subflow. (Subflows may overlap 256 to some extent, since acknowledgements may be piggybacked on 257 data packets.) 259 Sequences 260 A sequence consists of all packets sent in one direction, 261 regardless of whether they are data or acknowledgements. The 262 sets 1+4 and 2+3, from above, are each sequences. Each packet on 263 a sequence has a different sequence number. 265 Half-connections 266 A half-connection consists of the data packets sent in one 267 direction, plus the corresponding acknowledgements. The sets 1+2 268 and 3+4, from above, are each half-connections. Half-connections 269 are named after the direction of data flow, so the A-to-B half- 270 connection contains the data packets from A to B and the 271 acknowledgements from B to A. 273 HC-Sender and HC-Receiver 274 In the context of a single half-connection, the HC-Sender is the 275 endpoint sending data, while the HC-Receiver is the endpoint 276 sending acknowledgements. For example, in the A-to-B half- 277 connection, DCCP A is the HC-Sender and DCCP B is the HC- 278 Receiver. 280 3.2. Congestion Control 282 Each half-connection is managed by a congestion control mechanism. 283 The endpoints negotiate these mechanisms at connection setup; the 284 mechanisms for the two half-connections need not be the same, but 285 they must both be TCP-compatible. 287 Conformant congestion control mechanisms correspond to single-byte 288 congestion control identifiers, or CCIDs. The CCID for a half- 289 connection describes how the HC-Sender limits data packet rates in a 290 TCP-friendly manner; how it maintains necessary parameters, such as 291 congestion windows; how the HC-Receiver sends congestion feedback 292 via acknowledgements; and how it manages the acknowledgement rate. 293 Section 6 introduces the currently allocated CCIDs, which are 294 defined in separate profile documents. 296 3.3. Connection Initiation and Termination 298 Every DCCP connection is actively initiated by one DCCP, which 299 connects to a DCCP socket in the passive listening state. We refer 300 to the active endpoint as "the client" and the passive endpoint as 301 "the server". Most of the DCCP specification is indifferent to 302 whether a DCCP is client or server. However, only the server may 303 generate a DCCP-CloseReq packet. (A DCCP-CloseReq packet forces the 304 receiving DCCP to close the connection and maintain connection state 305 for a reasonable time, allowing old packets to clear the network.) 306 This means that the client cannot force the server to maintain 307 connection state after the connection is closed. 309 DCCP does not support TCP-style simultaneous open. In particular, a 310 host MUST NOT respond to a DCCP-Request packet with a DCCP-Response 311 packet unless the destination port specified in the DCCP-Request 312 corresponds to a local socket opened for listening. 314 DCCP also does not support half-open connections. That is, DCCP 315 shuts down both half-connections as a unit. However, DCCP SHOULD 316 allow applications to declare that they are no longer interested in 317 receiving data. This would allow DCCP implementations to streamline 318 state for certain half-connections. See Section 7.8, the Buffer 319 Closed Drops option, for more information. 321 3.4. Features 323 DCCP uses a generic mechanism to negotiate connection properties, 324 such as the CCIDs active on the two half-connections. These 325 properties are called features. (We reserve the term "option" for a 326 collection of bytes in some DCCP header.) A feature name, such as 327 "CCID", generally corresponds to two features, one per half- 328 connection. For instance, there are two CCIDs per connection. The 329 endpoint in charge of a particular feature is called its feature 330 location. 332 The Change, Prefer, and Confirm options negotiate feature values. 333 (These options were formerly called Ask, Choose, and Answer, 334 respectively.) Change is sent to a feature location, asking it to 335 change its value for the feature. The feature location may respond 336 with Prefer, which asks the other endpoint to Change again with 337 different values, or it may change the feature value and acknowledge 338 the request with Confirm. Retransmissions make feature negotiation 339 reliable. Section 5.3 describes these options further. 341 4. DCCP Packets 343 DCCP has nine different packet types: 345 o DCCP-Request 347 o DCCP-Response 349 o DCCP-Data 351 o DCCP-Ack 353 o DCCP-DataAck 355 o DCCP-CloseReq 357 o DCCP-Close 359 o DCCP-Reset 360 o DCCP-Move 362 Only the first eight types commonly occur. The DCCP-Move packet is 363 used to support multihoming and mobility. 365 The progress of a typical DCCP connection is as follows. 367 (1) The client sends the server a DCCP-Request packet specifying the 368 client and server ports, the service that is being requested, 369 and any features that are being negotiated, including the CCID 370 that the client would like the server to use. The client MAY 371 optionally piggyback some data on the DCCP-Request packet---an 372 application-level request, say---which the server MAY ignore. 374 (2) The server sends the client a DCCP-Response packet indicating 375 that it is willing to communicate with the client. The response 376 indicates any features and options that the server agrees to, 377 whether an application request in the DCCP-request was actually 378 passed to the application, and optionally an Init Cookie that 379 wraps up all this information and which MUST be returned by the 380 client for the connection to complete. 382 (3) The client sends the server a DCCP-Ack packet that acknowledges 383 the DCCP-Response packet. This acknowledges the server's initial 384 sequence number and returns the Init Cookie if there was one in 385 the DCCP-Response. It may also continue feature negotiation. 387 (4) Next comes zero or more DCCP-Ack exchanges as required to 388 finalize feature negotiation. The client may piggyback an 389 application-level request on its final ack, producing a DCCP- 390 DataAck packet. 392 (5) The server and client then exchange DCCP-Data packets, DCCP-Ack 393 packets acknowledging that data, and, optionally, DCCP-DataAck 394 packets containing piggybacked data and acknowledgements. If the 395 client has no data to send, then the server will send DCCP-Data 396 and DCCP-DataAck packets, while the client will send DCCP-Acks 397 exclusively. 399 (6) The server sends a DCCP-CloseReq packet requesting a close. 401 (7) The client sends a DCCP-Close packet acknowledging the close. 403 (8) The server sends a DCCP-Reset packet and clears its connection 404 state. 406 (9) The client receives the DCCP-Reset packet and holds state for a 407 reasonable interval of time to allow any remaining packets to 408 clear the network. 410 An alternative connection closedown sequence is initiated by the 411 client: 413 (6) The client sends a DCCP-Close packet closing the connection. 415 (7) The server sends a DCCP-Reset packet and clears its connection 416 state. 418 (8) The client receives the DCCP-Reset packet and holds state for a 419 reasonable interval of time to allow any remaining packets to 420 clear the network. 422 This arrangement of setup and teardown handshakes permits the server 423 to decline to hold any state until the handshake with the client has 424 completed, and ensures that the client must hold the TimeWait state 425 at connection closedown. 427 4.1. Examples of DCCP Congestion Control 429 Before giving the detailed specifications of DCCP, we first give two 430 more detailed examples on DCCP congestion control in operation. 432 4.1.1. DCCP with TCP-like Congestion Control 434 The first example is of a connection where both half-connections use 435 TCP-like Congestion Control, specified by CCID 2 [CCID 2 PROFILE]. 436 In this example, the client sends an application-level request to 437 the server, and the server responds with a stream of data packets. 438 This example is of a connection using ECN. 440 (1) The client sends the DCCP-Request, which includes a Change 441 option asking the server to use CCID 2 for the server's data 442 packets, and a Prefer option informing the server that the 443 client would like to use CCID 2 for the its data packets. 445 (2) The server sends a DCCP-Response, including a Confirm option 446 indicating that the server agrees to use CCID 2 for its data 447 packets, and a Change option indicating that the server agrees 448 to the client's suggestion of CCID 2 for the client's data 449 packets. 451 (3) The client responds with a DCCP-DataAck acknowledging the 452 server's initial sequence number, and including a Confirm option 453 finalizing the negotiation of the client-to-server CCID, and an 454 application-level request for data. We will not discuss the 455 client-to-server half-connection further in this example. 457 (4) The server sends DCCP-Data packets, where the number of packets 458 sent is governed by a congestion window cwnd, as in TCP. The 459 details of the congestion window are defined in the profile for 460 CCID 2, which is a separate document [CCID 2 PROFILE]. The 461 server also sends Ack Ratio feature options specifying the 462 number of server data packets to be covered by an Ack packet 463 from the client. 465 Some of these data packets are DCCP-DataAcks acknowledging 466 packets from the client. 468 (5) The client sends a DCCP-Ack packet acknowledging the data 469 packets for every Ack Ratio data packets transmitted by the 470 server. Each DCCP-Ack packet uses a sequence number and 471 contains an Ack Vector, as defined in Section 7 on 472 Acknowledgements. These packets also include Confirm options 473 answering any Ack Ratio requests from the server. 475 (6) The server continues sending DCCP-Data packets as controlled by 476 the congestion window. Upon receiving DCCP-Ack packets, the 477 server examines the Ack Vector to learn about marked or dropped 478 data packets, and adjusts its congestion window accordingly, as 479 described in [CCID 2 PROFILE]. Because this is unreliable 480 transfer, the server does not retransmit dropped packets. 482 (7) Because DCCP-Ack packets use sequence numbers, the server has 483 direct information about the fraction of loss or marked DCCP-Ack 484 packets. The server responds to lost or marked DCCP-Ack packets 485 by modifying the Ack Ratio sent to the client, as described in 486 [CCID 2 PROFILE]. Under certain conditions, the server must 487 acknowledge some of the client's acknowledgements; see Section 488 7.1 for more information. 490 (8) The server estimates round-trip times and calculates a TimeOut 491 (TO) value much as the RTO (Retransmit Timeout) is calculated in 492 TCP. Again, the specification for this is in [CCID 2 PROFILE]. 493 The TO is used to determine when a new DCCP-Data packet can be 494 transmitted when the server has been limited by the congestion 495 window and no feedback has been received from the client. 497 (9) Each DCCP-Data, DCCP-DataAck, and DCCP-Ack packet is sent as 498 ECN-Capable, with either the ECT(0) or the ECT(1) codepoint set, 499 as described in [WES01]. The client echoes the accumulated ECN 500 Nonce for the server's packets along with its Ack Vector 501 options. 503 (10) 504 The DCCP-CloseReq, DCCP-Close, and DCCP-Reset packets to close 505 the connection are as in the example above. 507 4.1.2. DCCP with TFRC Congestion Control 509 This example is of a connection where both half-connections use TFRC 510 Congestion Control, specified by CCID 3 The specification for CCID 3 511 is in a separate profile [CCID 3 PROFILE]; the purpose of this 512 example is to illustrate the range of uses for DCCP. 514 (1) The DCCP-Request and DCCP-Response packets specifying the use of 515 CCID 3 and the initial DCCP-DataAck packet are similar to those 516 in the TCP-like example above. 518 (2) The server sends DCCP-Data packets, where the number of packets 519 sent is governed by an allowed transmit rate, as in TFRC. The 520 details of the allowed transmit rate are defined in the profile 521 for CCID 3, which is a separate document [CCID 3 PROFILE]. Each 522 DCCP-Data packet has a sequence number and a window counter 523 option. 525 Some of these data packets are DCCP-DataAck packets 526 acknowledging packets from the client, but for simplicity we 527 will not discuss the half-connection of data from the client to 528 the server in this example. 530 (3) The receiver sends DCCP-Ack packets at least once per round-trip 531 time acknowledging the data packets, unless the server is 532 sending at a rate of less than one packet per RTT, as specified 533 by CITE CCID3 . These acknowledgements may be piggybacked on 534 data packets, producing DCCP-DataAck packets. Each DCCP-Ack 535 packet uses a sequence number and identifies the most recent 536 packet received from the server. Each DCCP-Ack packet includes 537 feedback about the loss event rate calculated by the client, as 538 specified by [CCID 3 PROFILE]. 540 (4) The server continues sending DCCP-Data packets as controlled by 541 the allowed transmit rate. Upon receiving DCCP-Ack packets, the 542 server updates its allowed transmit rate as specified by [CCID 3 543 PROFILE]. 545 (5) The server estimates round-trip times and calculates a TimeOut 546 (TO) value much as the RTO (Retransmit Timeout) is calculated in 547 TCP. Again, the specification for this is in [CCID 3 PROFILE]. 549 (6) The use of ECN follows TCP-like Congestion Control, above, and 550 is described further in [CCID 3 PROFILE]. 552 (7) The DCCP-CloseReq, DCCP-Close, and DCCP-Reset packets to close 553 the connection are as in the examples above. 555 4.2. DCCP Generic Packet Header 557 All DCCP packets begin with a generic DCCP packet header: 559 0 1 2 3 560 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 561 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 562 | Source Port | Dest Port | 563 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 564 | Type | Res | Sequence Number | 565 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 566 | Data Offset | # NDP | Cslen | Checksum | 567 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 569 Source and Destination Ports: 16 bits each 570 These fields identify the connection. Packets sent on the other 571 sequence switch the source and destination port values. 573 Type: 4 bits 574 The type field specifies the type of the DCCP message. The 575 following values are defined: 577 0 DCCP-Request packet. 579 1 DCCP-Response packet. 581 2 DCCP-Data packet. 583 3 DCCP-Ack packet. 585 4 DCCP-DataAck packet. 587 5 DCCP-CloseReq packet. 589 6 DCCP-Close packet. 591 7 DCCP-Reset packet. 593 8 DCCP-Move packet. 595 Reserved (Res): 4 bits 596 This field is reserved for future expansion. The version of DCCP 597 specified here MUST set the field to all zeroes on generated 598 packets, and ignore its value on received packets. 600 Sequence Number: 24 bits 601 The sequence number field is initialized by a DCCP-Request or 602 DCCP-Response packet, and increases by one (modulo 16777216) 603 with every packet sent. The receiver uses this information to 604 determine whether packet losses have occurred. Even packets 605 containing no data update the sequence number. Sequence numbers 606 also provide some protection against old and malicious packets. 607 Section 4.3 discusses sequence number validity. 609 Data Offset: 8 bits 610 The offset from the start of the DCCP header to the beginning of 611 the packet's payload, measured in 32-bit words. 613 Number of Non-Data Packets (# NDP): 4 bits 614 DCCP sets this field to the number of non-data packets it has 615 sent so far on its sequence, modulo 16. A non-data packet is 616 simply any packet not containing user data; DCCP-Ack packets are 617 the canonical example. When sending a non-data packet, DCCP 618 increments the # NDP counter before storing its value in the 619 packet header. 621 This field can help the receiving DCCP decide whether a lost 622 packet contained any user data. (An application may want to know 623 when it has lost data. DCCP could report every packet loss as a 624 potential data loss, but that would cause false loss reports 625 when non-data packets were lost.) For example, say that packet 626 10 had # NDP set to 5; packet 11 was lost; and packet 12 had # 627 NDP set to 5. Then the receiving DCCP could deduce that packet 628 11 contained data, since # NDP did not change. Likewise, if # 629 NDP had gone up to 6 (and packets 10 and 12 contained user 630 data), then packet 11 must not have contained any data. 632 Checksum Length (Cslen): 4 bits 633 The checksum length field specifies what parts of the packet are 634 covered by the checksum field. The checksum always covers at 635 least the DCCP header, DCCP options, and a pseudoheader taken 636 from the network-layer header (see below). If the checksum 637 length field is zero, that is all the checksum covers. If the 638 field is 15, the checksum covers the packet's payload as well, 639 possibly with 8 bits of zero padding on the right to pad the 640 payload to an even number of bytes. Values between 1 and 14, 641 inclusive, indicate that the checksum additionally covers the 642 indicated number of initial 32-bit words of the packet's 643 payload, padded on the right with zeros as necessary. Any value 644 other than 15 specifies that corruption is acceptable in some or 645 all of the DCCP packet's payload, and that partially corrupted 646 data packets may be received and counted for congestion control 647 purposes. The meaning of values other than 0 and 15 should be 648 considered experimental. 650 Checksum: 16 bits 651 DCCP uses the TCP/IP checksum algorithm. The checksum field 652 equals the 16 bit one's complement of the one's complement sum 653 of all 16 bit words in the DCCP header, DCCP options, a 654 pseudoheader taken from the network-layer header, and, depending 655 on the value of the checksum length field, some or all of the 656 payload. When calculating the checksum, the checksum field 657 itself is treated as 0. If a packet contains an odd number of 658 header and text octets to be checksummed, the last octet is 659 padded on the right with zeros to form a 16 bit word for 660 checksum purposes. The pad is not transmitted as part of the 661 packet. 663 The pseudoheader is calculated as for TCP. For IPv4, it is 96 664 bits long, and consists of the IPv4 source and destination 665 addresses, the IP protocol number for DCCP (padded on the left 666 with 8 zero bits), and the DCCP length (the length of the DCCP 667 header with options, plus the length of any data); see Section 668 3.1 of [RFC 793]. For IPv6, it is 320 bits long, and consists of 669 the IPv6 source and destination addresses, the DCCP length as a 670 32-bit quantity, and the IP protocol number for DCCP (padded on 671 the left with 24 zero bits); see Section 8.1 of [RFC 2460]. 673 4.3. Sequence Number Validity 675 DCCP should ignore packets with invalid sequence numbers, which may 676 arise if the network delivers a very old packet or an attacker 677 attempts to hijack a connection. TCP solves this problem with its 678 window. In DCCP, however, the definition of "unreasonable sequence 679 number" is complicated because sequence numbers change with each 680 packet sent. Thus, a loss event that dropped many consecutive 681 packets could cause two DCCPs to get out of sync relative to any 682 window. 684 DCCP uses Loss Window and Connection Nonce mechanisms to determine 685 whether a given packet's sequence number is valid. Each HC-Sender 686 gives the corresponding HC-Receiver a *loss window width* W; see 687 Section 5.9. This reflects how many packets the sender expects to be 688 in flight. Only the sender can anticipate this number. One good 689 guideline is to set it to about 3 or 4 times the maximum number of 690 packets the sender expects to send in any round-trip time. Too-small 691 values increase the risk of the endpoints getting out sync after 692 bursts of loss; too-large values increase the risk of connection 693 hijacking. W defaults to 1000. The Connection Nonces are used to get 694 back into sync when more than W consecutive packets are lost. 696 The HC-Receiver sets up a loss window of W consecutive sequence 697 numbers containing GSN, the Greatest Sequence Number it has received 698 on any valid packet from the sender. ("Consecutive" and "greatest" 699 are measured in circular sequence space. The receiver may center the 700 loss window on GSN, or arrange it asymmetrically.) Sequence numbers 701 outside this loss window are invalid. Packets with invalid sequence 702 numbers are themselves invalid, *unless* their sequence numbers are 703 greater than GSN and their acknowledgement numbers are correct 704 (within a loss window of the last packets sent from the receiver), 705 *or* they include correct Connection Proof (Section 5.4.2). 707 The receiving DCCP SHOULD ignore invalid packets---that is, it 708 should not pass any enclosed data to the application, update its 709 congestion control state, or close the connection. However, the 710 receiving DCCP MAY send a DCCP-Ack packet to the sender, as allowed 711 by the congestion control mechanism in use. This packet should 712 contain the last received valid sequence number and an Identify 713 Yourself option (Section 5.4.3). The other DCCP will send a 714 Connection Proof option to resync. (Such Identify Yourself packets 715 MUST be rate limited.) 717 We note that resyncing mechanisms may need further research. 719 4.4. DCCP State Diagram 721 In this section we present a DCCP state diagram showing how a DCCP 722 connection should progress, and the proper responses for packets or 723 timeout events in various connection states. The state diagram is 724 illustrative; the text should be considered definitive. 726 +-----------------------------------+ 727 | Figures omitted from text version | 728 +-----------------------------------+ 730 All receive events on the diagram represent receipt of valid 731 packets. For example, receiving a Reset with a bad Acknowledgement 732 Number should not cause DCCP to transition to the Time-Wait state. 733 Furthermore, packets without explicit transitions in the state 734 diagram should be treated as invald. DCCP implementations MAY send 735 Resets (or Acks, as described above) in response to invalid packets. 736 Any such responses MUST be rate-limited. 738 The Open state does not signify that a DCCP connection is ready for 739 data transfer. In particular, incomplete feature negotiations might 740 prevent data transfer. Feature negotiation takes place in parallel 741 with the state transitions on this diagram. 743 Only the server may take the transition from the OPEN state to the 744 SERVER-CLOSE state. (The server is the DCCP endpoint that began in 745 the LISTEN state.) Similarly, only the client must transition to 746 CLIENT-CLOSE after receiving a CloseReq packet. 748 4.5. DCCP-Request Packet Format 750 A DCCP connection is initiated by sending a DCCP-Request packet. The 751 format of a DCCP request packet is: 753 0 1 2 3 754 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 755 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 756 / Generic DCCP Header / 757 / (12 octets) / 758 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 759 | Service Name | 760 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 761 | Options | [padding] | 762 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 763 | data | 764 | ... | 765 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 767 The Service Name field, in combination with the Destination Port, 768 identifies the service to which the sender is trying to connect. 769 Service Names are 32-bit numbers allocated by the IETF; they are 770 meant to correspond to application services and protocols. The host 771 operating system MAY force every DCCP socket, both actively and 772 passively opened, to specify a Service Name. The connection will 773 succeed only if the Destination Port on the receiver has the same 774 Service Name as that given in the packet. If they differ, the 775 receiver will respond with a DCCP-Reset packet. 777 The DCCP-Request packet initializes the client-to-server sequence 778 number. As in TCP, this sequence number should be chosen randomly 779 to help prevent connection hijacking. 781 Options 782 DCCP-Request packets will usually include a "Change(Connection 783 Nonce)" option, to inform the server of the client's connection 784 nonce; see Section 5.4. 786 4.6. DCCP-Response Packet Format 788 In the second phase of the three-way handshake, the server sends a 789 DCCP-Response message to the client. The response initializes the 790 server-to-client sequence number. As in TCP, this sequence number 791 should be chosen randomly to help prevent connection hijacking. 793 In this phase, a server will often specify the options it would like 794 to use, either from among those the client requested, or in addition 795 to those. Among these options is the congestion control mechanism 796 the server expects to use. 798 0 1 2 3 799 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 800 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 801 / Generic DCCP Header / 802 / (12 octets) / 803 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 804 | Reserved | Acknowledgement Number | 805 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 806 | Options | [padding] | 807 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 808 | data | 809 | ... | 810 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 812 Acknowledgement Number: 24 bits 813 The acknowledgement number field acknowledges the largest valid 814 sequence number received so far on this connection. (The usual 815 care must be taken in case of wrapped sequence numbers.) In the 816 case of a DCCP-Response packet, the acknowledgement number field 817 will equal the sequence number from the DCCP-Request. 818 Acknowledgement numbers make no attempt to provide precise 819 information about which packets have arrived; options such as 820 the Ack Vector do this. 822 Reserved: 8 bits 823 The version of DCCP specified here MUST set this field to all 824 zeroes on generated packets, and ignore its value on received 825 packets. 827 Options 828 The Data Discarded and Init Cookie options are particularly 829 designed for DCCP-Response packets (Sections 5.5 and 5.6). In 830 addition, DCCP-Response, or early DCCP-Data or DCCP-Ack packets, 831 will often include "Confirm(Connection Nonce)" and 832 "Change(Connection Nonce)" packets, to further negotiate 833 connection nonces (Section 5.4). 835 4.7. DCCP-Data, DCCP-Ack, and DCCP-DataAck Packet Formats 837 The payload data in a DCCP connection is sent in DCCP-Data and DCCP- 838 DataAck packets. DCCP-Data packets look like this: 840 0 1 2 3 841 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 842 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 843 / Generic DCCP Header / 844 / (12 octets) / 845 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 846 | Options | [padding] | 847 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 848 | data | 849 | ... | 850 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 852 DCCP-Ack packets dispense with the data, but contain an 853 acknowledgement number: 855 0 1 2 3 856 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 857 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 858 / Generic DCCP Header / 859 / (12 octets) / 860 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 861 | Reserved | Acknowledgement Number | 862 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 863 | Options | [padding] | 864 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 866 DCCP-DataAck packets contain both data and an acknowledgement 867 number. That is, acknowledgement information is piggybacked on a 868 data packet. 870 0 1 2 3 871 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 872 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 873 / Generic DCCP Header / 874 / (12 octets) / 875 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 876 | Reserved | Acknowledgement Number | 877 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 878 | Options | [padding] | 879 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 880 | data | 881 | ... | 882 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 884 DCCP-Ack and DCCP-DataAck packets may include additional 885 acknowledgement options, such as Ack Vector, as required by the 886 congestion control mechanism in use. 888 DCCP A sends DCCP-Data and DCCP-DataAck packets to DCCP B due to 889 application events on host A. These packets are congestion- 890 controlled by the CCID for the A-to-B half-connection. In contrast, 891 DCCP-Ack packets sent by DCCP A are controlled by the CCID for the 892 B-to-A half-connection. Generally, DCCP A will piggyback 893 acknowledgement information on data packets when acceptable, 894 creating DCCP-DataAck packets. DCCP-Ack packets are used when there 895 is no data to send from DCCP A to DCCP B, or when the link from A to 896 B is completely congested (so sending data would be inappropriate). 898 Section 7, below, describes acknowledgements in DCCP. 900 A DCCP-Data or DCCP-DataAck packet may contain no data if the 901 application sends a zero-length datagram. 903 4.8. DCCP-CloseReq and DCCP-Close Packet Format 905 The DCCP-CloseReq and DCCP-Close packets have the same format. 906 However, only the server can send a DCCP-CloseReq packet. Either 907 client or server may send a DCCP-Close packet. 909 0 1 2 3 910 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 911 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 912 / Generic DCCP Header / 913 / (12 octets) / 914 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 915 | Reserved | Acknowledgement Number | 916 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 917 | Options | [padding] | 918 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 920 4.9. DCCP-Reset Packet Format 922 DCCP-Reset packets unconditionally shut down a connection. Every 923 connection shutdown sequence ends with a DCCP-Reset, but resets may 924 be sent for other reasons, including bad port numbers, bad option 925 behavior, incorrect ECN Nonce Echoes, and so forth. The reason for a 926 reset is represented in the reset itself by a four-byte number, the 927 Reason field. 929 0 1 2 3 930 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 931 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 932 / Generic DCCP Header / 933 / (12 octets) / 934 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 935 | Reserved | Acknowledgement Number | 936 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 937 | Reason | 938 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 939 | Options | [padding] | 940 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 942 Reason: 32 bits 943 The Reason field represents the reason that the sender reset the 944 DCCP connection. Particular values for this field will be 945 described in later versions of this document. 947 4.10. DCCP-Move Packet Format 949 The DCCP-Move packet type is part of DCCP's support for multihoming 950 and mobility, which is described further in Section 9. DCCP A sends 951 a DCCP-Move packet to DCCP B after changing its IP address and/or 952 port number. The DCCP-Move packet requests that DCCP B start sending 953 its data to the new address and port number. The old address and 954 port are stored explicitly in the DCCP-Move packet header; the new 955 address and port come from the network header and generic DCCP 956 header. The type of address contained in the packet is indicated 957 explicitly by an Old Address Family field. The Sequence Number and 958 Acknowledgement Number fields, and the Connection Proof option, 959 provide some protection against hijacked connections. See Section 9 960 for more on security and DCCP's mobility support. 962 0 1 2 3 963 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 964 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 965 / Generic DCCP Header / 966 / (12 octets) / 967 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 968 | Reserved | Acknowledgement Number | 969 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 970 | Old Address Family | Old Port | 971 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 972 / Old Address / 973 / | [padding] / 974 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 975 | Options | [padding] | 976 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 977 | data | 978 | ... | 979 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 981 Old Address Family: 16 bits 982 The Old Address Family field indicates the address family 983 formerly used for this connection, and takes values from the 984 Address Family Numbers registry administered by IANA. Particular 985 values include 1 for IPv4 and 2 for IPv6. The endpoint MUST 986 discard DCCP-Move packets with unrecognized Old Address Family 987 values. 989 Old Port: 16 bits 990 The former port number used by DCCP A's endpoint. 992 Old Address: at least 32 bits 993 The former address used by DCCP A's endpoint, padded on the 994 right to a multiple of 32 bits. The form and size of the address 995 are determined by the Old Address Family field. For instance, if 996 Old Address Family is 1, then Old Address contains an IPv4 997 address and takes 32 bits; if it is 2, then Old Address contains 998 an IPv6 address and takes 128 bits. 1000 Options 1001 A DCCP-Move packet MUST contain a valid Connection Proof option 1002 (see Section 5.4.2). This means that mobile-aware DCCP endpoints 1003 MUST inform each other of their Connection Nonces (Section 5.4) 1004 during connection setup. 1006 DCCP B should reset the connection if the DCCP-Move packet has valid 1007 sequence and acknowledgement numbers, but incorrect Connection 1008 Proof. Also, it should reset if neither the Old Address/Old Port 1009 combination nor the network address/Source Port combination refers 1010 to a currently active DCCP connection. 1012 DCCP B MUST respond to the DCCP-Move packet with a DCCP-Ack or DCCP- 1013 DataAck packet acknowledging the move. If this acknowledgement is 1014 lost, DCCP A might resend the DCCP-Move packet (using a new sequence 1015 number). DCCP B MUST NOT reset these packets, even though the Old 1016 Address/Old Port combination no longer refers to a valid DCCP 1017 connection. It SHOULD instead send another acknowledgement, as 1018 allowed by the congestion control mechanism in use. 1020 We note that DCCP mobility, as provided by DCCP-Move, may not be 1021 useful in the context of IPv6, with its mandatory support for Mobile 1022 IP. 1024 5. Options and Features 1026 All DCCP packets may contain options which can be used to extend 1027 DCCP's functionality. Options occupy space at the end of the DCCP 1028 header and are a multiple of 8 bits in length. All options are 1029 included in the checksum. An option may begin on any byte boundary. 1031 The first octet of an option is the option type. Options with types 1032 0 through 31 are single-byte options. Other options are followed by 1033 an octet indicating the option's length. This length includes the 1034 two octets of option-type and option-length as well as the option- 1035 data octets. 1037 The following options are currently defined: 1039 Option Section 1040 Type Length Meaning Reference 1041 ---- ------ ------- --------- 1042 0 1 Padding 5.1 1043 1 1 Data Discarded 5.5 1044 2 1 Slow Receiver 7.6 1045 3 1 Identify Yourself 5.4.3 1046 32 4 Ignored 5.2 1047 33 variable Change 5.3 1048 34 variable Prefer 5.3 1049 35 variable Confirm 5.3 1050 36 variable Init Cookie 5.6 1051 37 variable Ack Vector [Nonce 0] 7.5 1052 38 variable Ack Vector [Nonce 1] 7.5 1053 39 3 Receive Buffer Drops 7.7 1054 40 6 Timestamp 5.7 1055 41 10 Timestamp Echo 5.8 1056 42 variable Connection Proof 5.4.2 1057 43 3 Buffer Closed Drops 7.8 1058 128-255 variable CCID-Specific Options 6.4 1060 5.1. Padding Option 1062 The padding option, with type 0, is a single byte option used to pad 1063 between or after options. It either ensures the payload begins on a 1064 32-bit boundary (as required), or ensures alignment of following 1065 options (not mandatory). 1067 5.2. Ignored Option 1069 The Ignored option, with type 32, signals that a DCCP did not 1070 understand some option. This can happen, for example, when a 1071 conventional DCCP converses with an extended DCCP. Each Ignored 1072 option has two octets of payload, the first containing the offending 1073 option type and the second containing the first octet of the 1074 offending option's payload. (If the offending option had no payload, 1075 this octet is 0.) 1077 +--------+--------+--------+--------+ 1078 |00100000|00000100|Opt Type|Opt Data| 1079 +--------+--------+--------+--------+ 1080 Type=32 Length=4 1082 5.3. Feature Negotiation 1084 DCCP contains a mechanism for reliably negotiating features, most 1085 notably the congestion control mechanism in use on each half- 1086 connection. The motivation was to implement reliable feature 1087 negotiation once, so that different options need not reinvent that 1088 particular wheel. 1090 Three options, Change, Prefer, and Confirm, implement feature 1091 negotiation. Change is sent to a feature's location, asking it to 1092 change the feature's value. The feature location may respond with 1093 Prefer, which asks the other endpoint to Change again with different 1094 values, or it may change the feature value and acknowledge the 1095 request with Confirm. (The options were formerly called Ask, Choose, 1096 and Answer.) 1098 Features MUST NOT change values apart from feature negotiation, and 1099 enforced retransmissions make feature negotiation reliable. This 1100 ensures that both endpoints eventually agree on every feature's 1101 value. 1103 Some features are non-negotiable, meaning that the feature location 1104 MUST set its value to whatever the other endpoint requests. For non- 1105 negotiable features, the feature location MUST respond to Change 1106 options with Confirm; Prefer is not useful. These features use the 1107 feature framework simply to achieve reliability. 1109 5.3.1. Feature Numbers 1111 The first data octet of every Change, Prefer, or Confirm option is a 1112 feature number, defining the type of feature being negotiated. The 1113 remainder of the data gives one or more values for the feature, and 1114 is interpreted according to the feature. The current set of feature 1115 numbers is as follows: 1117 Section 1118 Number Meaning Neg.? Reference 1119 ------ ------- ----- --------- 1120 1 Congestion Control (CC) Y 6 1121 2 ECN Capable Y 8.1 1122 3 Ack Ratio N 7.3 1123 4 Use Ack Vector Y 7.4 1124 5 Mobility Capable Y 9.1 1125 6 Loss Window N 5.9 1126 7 Connection Nonce N 5.4.1 1127 128-255 CCID-Specific Features ? 6.4 1129 The "Neg.?" column is "Y" for normal features and "N" for non- 1130 negotiable features. 1132 5.3.2. Change Option 1134 DCCP B sends a Change option to DCCP A to ask it to change the value 1135 of some feature. (DCCP A is the feature location.) DCCP A MUST 1136 respond to the Change option with either Prefer or Confirm. DCCP B 1137 MUST retransmit the Change option until it receives some relevant 1138 response. DCCP B will always generate a Change option in response to 1139 a Prefer option; it may also generate a Change option due to some 1140 application event. 1142 5.3.3. Prefer Option 1144 DCCP A sends a Prefer option to DCCP B to ask it to confirm the 1145 value of some feature. (Again, DCCP A is the feature location.) DCCP 1146 B MUST respond to the Prefer option with a Change. DCCP A MUST 1147 retransmit the Prefer option until it receives a relevant Change 1148 response. DCCP A may generate a Prefer option in response to some 1149 Change option, or in response to some application event. Prefer 1150 options are not useful for non-negotiable features. 1152 5.3.4. Confirm Option 1154 DCCP A sends a Confirm option to DCCP B to inform it of the current 1155 value of some feature. (Again, DCCP A is the feature location.) DCCP 1156 A MUST generate Confirm options only in response to Change options. 1157 DCCP A need not ever retransmit a Confirm option: DCCP B will 1158 retransmit the relevant Change as necessary. 1160 5.3.5. Example Negotiations 1162 This section demonstrates several negotiations of the congestion 1163 control feature for the A-to-B half-connection. (This feature is 1164 located at DCCP A.) In this sequence of packets, DCCP A is happy 1165 with DCCP B's suggestion of CC mechanism 2: 1167 B > A Change(CC, 2) 1168 A > B Confirm(CC, 2) 1170 Here, A and B jointly settle on CC mechanism 5: 1172 B > A Change(CC, 3, 4) 1173 A > B Prefer(CC, 1, 2, 5) 1174 B > A Change(CC, 5) 1175 A > B Confirm(CC, 5) 1177 In this sequence, A refuses to use CC mechanism 5. If B requires CC 1178 mechanism 5, its only recourse is to abort the connection: 1180 B > A Change(CC, 3, 4, 5) 1181 A > B Prefer(CC, 1, 2) 1182 B > A Change(CC, 5) 1183 A > B Prefer(CC, 1, 2) 1185 Here, A elicts agreement from B that it is satisfied with congestion 1186 control mechanism 2: 1188 A > B Prefer(CC, 1, 2) 1189 B > A Change(CC, 2) 1190 A > B Confirm(CC, 2) 1192 5.3.6. Unknown Features 1194 If a DCCP receives a Change or Prefer option referring to a feature 1195 number it does not understand, it MUST respond with a corresponding 1196 Ignored option. This informs the remote DCCP that the local DCCP 1197 does not implement the feature. No other action need be taken. 1198 (Ignored may also indicate that the DCCP endpoint could not respond 1199 to a CCID-specific feature request because the CCID was in flux; see 1200 Section 6.4.) 1202 5.3.7. State Diagram 1204 These state diagrams present the legal transitions in a DCCP feature 1205 negotiation. They define DCCP's states and transitions with respect 1206 to the negotiation of a single feature it understands. There are two 1207 diagrams, corresponding to the two endpoints: the feature location, 1208 or DCCP A, and what we call the "feature requester", DCCP B. 1210 Transitions between states are triggered by receiving a packet 1211 ("RECV") or by an application event ("APP"). Received packets are 1212 further distinguished by any options relevant to the feature being 1213 negotiated. "RECV -" means the packet contained no relevant option. 1214 "RECV Chg" denotes a Change option, "RECV Pr" a Prefer option, and 1215 "RECV Con" a Confirm option. The data contained in an option is 1216 given in parentheses when necessary. The "SEND" action indicates 1217 which option the DCCP will send next. Finally, the "SET-VALUE" 1218 action causes the DCCP to change its value for the relevant feature. 1220 "SEND" does not force DCCP to immediately generate a packet; rather, 1221 it says which feature option must be sent on the next packet 1222 generated. A DCCP MAY choose to generate a packet in response to 1223 some "SEND" action. However, it MUST NOT generate a packet if doing 1224 so would violate the congestion control mechanism in use. 1226 The requester, DCCP B, has four states: Known, Unknown, Failed, and 1227 Changing. Similarly, the feature location, DCCP A, has four states: 1228 Known, Unknown, Failed, and Confirming. In both cases, Known denotes 1229 a state where the DCCP knows the feature's current value, and 1230 believes that the other DCCP agrees. Changing and Confirming denote 1231 states where the DCCPs are in the process of negotiating a new value 1232 for the feature. The Unknown state can occur only at connection 1233 setup time. It denotes a state where the DCCP does not know any 1234 value for the feature, and has not yet entered a negotiation to 1235 determine its value. Finally, the Failed state represents a state 1236 where the other DCCP does not implement the feature under 1237 negotiation. 1239 A DCCP may start in either the Unknown or Known state, depending on 1240 the feature in question. In particular, some features have a well- 1241 known value for new connections, in which case the DCCPs begin the 1242 connection in the Known states. 1244 REQUESTER STATE DIAGRAM (DCCP B) 1246 +-----------+ 1247 | Unknown | 1248 +-----------+ 1249 +----------+ | +-----------+ 1250 | |RECV - |RECV -/Pr | APP | |RECV Pr/Con 1251 V |SEND - |SEND Chg V |SEND Chg 1252 +-----------+ | | +------------+ | 1253 | |----+ +------------>| |-----+ 1254 | Known |------------------------------>| Changing | 1255 | | RECV Pr | APP | |-----+ 1256 +-----------+ SEND Chg +------------+ |RECV - 1257 ^ | | ^ |SEND -/Chg 1258 | | | | | 1259 +------------------------------------------+ | +---------+ 1260 RECV Con(O) | +----------+ 1261 SEND - +--------->| Failed | 1262 SET-VALUE O RECV Ign +----------+ 1263 SEND - 1265 FEATURE LOCATION STATE DIAGRAM (DCCP A) 1266 (O represents any feature value acceptable to DCCP A; X is not acceptable.) 1268 RECV Chg(O) 1269 SEND Con(O) RECV - | APP 1270 SET-VALUE O +-----------+ SEND Pr(O) 1271 +--------------------| Unknown |------------+ 1272 | +-----------+ | 1273 | +-------+ | | +-----------+ 1274 | | |RECV - |RECV Chg(X) | | |RECV Chg(X) 1275 V V |SEND - |SEND Pr(O) V V |SEND Pr(O) 1276 +-----------+ | | +------------+ | (need not be 1277 | |----+ +------------>| |-----+ the same O) 1278 | Known |------------------------------>| Confirming | 1279 | |----+ RECV Chg | APP | |-----+ 1280 +-----------+ | SEND Pr(O) +------------+ |RECV - 1281 ^ ^ | | | ^ |SEND -/Pr(O) 1282 | | |RECV Chg(O) | | | | 1283 | | |SEND Con(O) | | +---------+ 1284 | | |SET-VALUE O | | 1285 | +-------+ | | +----------+ 1286 +---------------------------------------------+ +-------->| Failed | 1287 RECV Chg(O) RECV Ign +----------+ 1288 SEND Con(O) SEND - 1289 SET-VALUE O 1291 This specification allows several choices of action in certain 1292 states. The implementation will generally use feature-specific 1293 information to decide how to respond. For example, DCCP A in the 1294 Known state may respond to a Change option with either Confirm or 1295 Prefer. If DCCP A is willing to set the feature to the value 1296 specified by Change, it will generally send Confirm; but if it would 1297 like to negotiate further, it will send Prefer. 1299 DCCP B must retransmit Change options, and DCCP A must retransmit 1300 Prefer options, until receiving a relevant response. However, they 1301 need not retransmit the option on every packet, as shown by the 1302 "RECV - / SEND -" transitions in the Changing and Confirming states. 1304 These state diagrams guarantee safety, but not liveness. Namely, no 1305 unexpected or erroneous options will be sent, but option negotiation 1306 might not terminate. For example, the following infinite negotiation 1307 is legal according to this specification. 1309 A > B Prefer(1) 1310 B > A Change(2) 1311 A > B Prefer(1) 1312 B > A Change(2)... 1314 Implementations may choose to enforce a maximum length on any 1315 negotiation -- for example, by resetting the connection when any 1316 negotiation lasts more than some maximum time. 1318 In the Changing and Confirming states, the value of the 1319 corresponding feature is in flux. DCCP MAY change its behavior in 1320 these states---for example, by refusing to send data until 1321 reentering a Known state. 1323 5.4. Connection Nonce Options 1325 Connection nonces are opaque cookies that serve as identities for 1326 DCCP endpoints. They may be negotiated at connection setup time, or 1327 at any point thereafter. Once set up, they facilitate reconnection 1328 after an endpoint moves (Section 9) or a long burst of loss that 1329 gets the endpoints out of sync (Section 4.3). 1331 The Connection Nonce feature is used to inform one endpoint of the 1332 other endpoint's connection nonce. The Connection Proof option 1333 contains the xor of the two endpoints' nonces, and thus acts as 1334 proof that the sending endpoint knows both nonces. The Identify 1335 Yourself option requests that a DCCP send a Connection Proof option 1336 on its next packet. 1338 5.4.1. Connection Nonce Feature 1340 Connection Nonce has feature number 7. The Connection Nonce feature 1341 located at DCCP B is the value of DCCP A's connection nonce. Each 1342 endpoint must keep track of both its nonce and, via the Connection 1343 Nonce feature, the other endpoint's nonce. 1345 The Connection Nonce feature takes arbitrary values of at least 4 1346 bytes long. A Change or Confirm Connection Nonce option therefore 1347 takes at least 6 bytes. 1349 Connection Nonce defaults to a random 8-byte string. To prevent 1350 spoofing, this string MUST NOT have any predictable value. For 1351 example, it MUST NOT be set deterministically to zero, and it MUST 1352 change on every connection. 1354 This feature is non-negotiable. 1356 5.4.2. Connection Proof Option 1358 This option is permitted in any DCCP packet, although it is useful 1359 only after the endpoints have informed each other of their 1360 connection nonces. The value of the option is the exclusive-or of 1361 the two connection nonces. (If one nonce is longer than the other, 1362 then the shorter one is padded on the right with zero bytes before 1363 the exclusive-or.) The endpoint receiving Connection Proof compares 1364 the option value with the xor of the connection nonces, and thus 1365 determines whether or not the packet is really part of the 1366 connection. Packets with invalid Connection Proof MUST be ignored, 1367 except that the receiving DCCP MAY send an Identify Yourself option. 1368 (DCCP implementations SHOULD limit the rate of such response 1369 packets.) 1371 +--------+--------+--------+--------+--------+-------- 1372 |00101010|????????| Connection Proof Value ... 1373 +--------+--------+--------+--------+--------+-------- 1374 Type=42 Length 1376 5.4.3. Identify Yourself Option 1378 This option is permitted in any DCCP packet, although it is useful 1379 only after the endpoints have informed each other of their 1380 connection nonces. The option informs the receiving DCCP that one 1381 of its packets was ignored, and that succeeding packets will be 1382 ignored until the endpoint sends a correct Connection Proof option. 1383 The receiving DCCP SHOULD include a Connection Proof option on the 1384 next packet it sends. 1386 +--------+ 1387 |00000011| 1388 +--------+ 1389 Type=3 1391 5.5. Data Discarded Option 1393 This option is permitted in a DCCP-Response packet only. It 1394 indicates that the payload of the DCCP-Request packet was discarded 1395 by the server, and therefore should be resent in a following DCCP- 1396 Data or DCCP-DataAck packet. This option can be set by the server 1397 to avoid having to keep state for the connection until the handshake 1398 is complete. Doing so causes an additional round-trip time before 1399 the server can begin servicing the request. The tradeoff is under 1400 the control of local policy at the server. 1402 +--------+ 1403 |00000010| 1404 +--------+ 1405 Type=2 1407 5.6. Init Cookie Option 1409 This option is permitted in DCCP-Response, DCCP-Data, and DCCP- 1410 DataAck messages. The option MAY be returned by the server in a 1411 DCCP-Response mechanism. If so, then the client MUST echo the same 1412 Init Cookie option in its ensuing DCCP-Data or DCCP-DataAck 1413 message. 1415 The purpose of this option is to allow a DCCP server to avoid having 1416 to hold any state until the three-way connection setup handshake has 1417 completed. The server wraps up the service name, server port, and 1418 any options it cares about from both the DCCP-Request and DCCP- 1419 Response in a opaque cookie. Typically the cookie will be encrypted 1420 using a secret known only to the server and include a cryptographic 1421 checksum or magic value so that correct decryption can be verified. 1422 When the server receives the cookie back in the response, it can 1423 decrypt the cookie and instantiate all the state it avoided keeping. 1425 The precise implementation of the Init Cookie does not need to be 1426 specified here as it is only relayed by the client, and does not 1427 need to be understood by the client. 1429 +--------+--------+--------+--------+--------+-------- 1430 |00100100|????????| Init Cookie Value ... 1431 +--------+--------+--------+--------+--------+-------- 1432 Type=36 Length 1434 5.7. Timestamp Option 1436 This option is permitted in any DCCP packet. The length of the 1437 option is 6 bytes. 1439 +--------+--------+--------+--------+--------+--------+ 1440 |00101000|00000110| Timestamp Value | 1441 +--------+--------+--------+--------+--------+--------+ 1442 Type=40 Length=6 1444 The four bytes of option data carry the timestamp of this packet, in 1445 some undetermined form. A DCCP receiving a Timestamp option SHOULD 1446 respond with a Timestamp Echo option on the next packet it sends. 1448 5.8. Timestamp Echo Option 1450 This option is permitted in any DCCP packet, as long as at least one 1451 packet carrying the Timestamp option has been received. The length 1452 of the option is 10 bytes. 1454 +--------+--------+------- ... -------+------- ... -------+ 1455 |00101001|00001010| TS Echo | Elapsed | 1456 +--------+--------+------- ... -------+------- ... -------+ 1457 Type=41 Len=10 (4 bytes) (4 bytes) 1459 The first four bytes of option data, TS Echo, carry a Timestamp 1460 Value taken from a preceding received Timestamp option. Usually, 1461 this will be the last packet that was received. The final four bytes 1462 indicate the amount of time elapsed since receiving the packet whose 1463 timestamp is being echoed. This time MUST be in microseconds. We are 1464 currently investigating ways to relax the last requirement. 1466 5.9. Loss Window Feature 1468 Loss Window has feature number 6. The Loss Window feature located at 1469 DCCP B is the width of the window DCCP B uses to determine whether 1470 packets from DCCP A are valid. Packets outside this window will be 1471 dropped by DCCP B as old duplicates or spoofing attempts; see 1472 Section 4.3 for more information. DCCP A sends a "Change(Loss 1473 Window, W)" option to DCCP B to set DCCP B's Loss Window to W. 1475 The Loss Window feature takes 3-byte integer values, like DCCP 1476 sequence numbers. Change and Confirm options for Loss Window are 1477 therefore 6 bytes long. 1479 Loss Window defaults to 1000 for new connections. The Loss Window 1480 value is the total width of the loss window. The receiver may 1481 position the loss window asymmetrically around the last sequence 1482 number seen -- for example, by allocating 1/4 of the loss window 1483 width for older sequence numbers and 3/4 of it for newer sequence 1484 numbers. 1486 This feature is non-negotiable. 1488 6. Congestion Control IDs 1490 Each congestion control mechanism supported by DCCP is assigned a 1491 congestion control identifier, or CCID: a number from 0 to 255. 1492 During connection setup, and optionally thereafter, the endpoints 1493 negotiate their congestion control mechanisms by negotiating the 1494 values for their Congestion Control features. Congestion Control has 1495 feature number 1. The feature located at DCCP A is the CCID in use 1496 for the A-to-B half-connection. DCCP B sends an "Change(CC, K)" 1497 option to DCCP A to ask A to use CCID K for its data packets. 1499 The data octets of Congestion Control feature negotiation options 1500 form a list of acceptable CCIDs, sorted in descending order of 1501 priority. For example, the option "Change(CC 1, 2, 3)" asks the 1502 sender to use CCID 1, although CCIDs 2 and 3 are also acceptable. 1503 (This corresponds to the octets "33, 6, 1, 1, 2, 3": Change option 1504 (33), option length (6), feature ID (1), CCIDs (1, 2, 3).) 1505 Similarly, "Confirm(CC 1, 2, 3)" tells the receiver that the sender 1506 is using CCID 1, but that CCIDs 2 or 3 might also be acceptable. 1508 The CCIDs defined by this document are: 1510 CCID Meaning 1511 ---- ------- 1512 0 Reserved 1513 1 Unspecified Sender-Based Congestion Control 1514 2 TCP-like Congestion Control 1515 3 TFRC Congestion Control 1517 A new connection starts with CCID 2 for both DCCPs. If this is 1518 unacceptable for either DCCP, that DCCP will start in the Unknown 1519 state. A DCCP SHOULD NOT send data when its Congestion Control 1520 feature is in the Unknown state. 1522 6.1. Unspecified Sender-Based Congestion Control 1524 CCID 1 denotes an unspecified sender-based congestion control 1525 mechanism. Separate features negotiate the corresponding congestion 1526 acknowledgement options---for example, Ack Vector. This provides a 1527 limited, controlled form of interoperability for new IETF-approved 1528 CCIDs. 1530 Implementors MUST NOT use CCID 1 in production environments as a 1531 proxy for congestion control mechanisms that have not entered the 1532 IETF standards process. We intend for the IETF to approve all 1533 production uses of CCID 1. Nevertheless, middle boxes MAY choose to 1534 treat the use of CCID 1 as experimental or unacceptable. 1536 For example, say that CCID 98, a new sender-based congestion control 1537 mechanism using Ack Vector for acknowledgements, has entered the 1538 IETF standards process. Now, DCCP A, which understands and would 1539 like to use CCID 98, is trying to communicate with DCCP B, which 1540 doesn't yet know about CCID 98. DCCP A can simply negotiate use of 1541 CCID 1 and, separately, negotiate Use Ack Vector. DCCP B will 1542 provide the feedback DCCP A requires for CCID 98, namely Ack Vector, 1543 without needing to understand the congestion control mechanism in 1544 use. 1546 6.2. TCP-like Congestion Control 1548 CCID 2 denotes Additive Increase, Multiplicative Decrease (AIMD) 1549 congestion control with behavior modelled directly on TCP, including 1550 congestion window, slow start, timeouts, and so forth. CCID 2 is 1551 further described in [CCID 2 PROFILE]. 1553 6.3. TFRC Congestion Control 1555 CCID 3 denotes TCP-Friendly Rate Control, an equation-based rate- 1556 controlled congestion control mechanism. CCID 3 is further described 1557 in [CCID 3 PROFILE]. 1559 6.4. CCID-Specific Options and Features 1561 Option and feature numbers 128 through 255 are available for CCID- 1562 specific use. CCIDs may often need new option types---for 1563 communicating acknowledgement or rate information, for example. 1564 CCID-specific option types let them create options at will without 1565 polluting the global options space. Option 128 might have different 1566 meanings on a half-connection using CCID 4 and a half-connection 1567 using CCID 8. CCID-specific options and features will never conflict 1568 with global options introduced by later versions of this 1569 specification. 1571 Any packet may contain information meant for either half-connection, 1572 so CCID-specific option and feature numbers explicitly signal the 1573 half-connection to which they apply. Option numbers 128 through 191 1574 are for options sent from the HC-Sender to the HC-Receiver; option 1575 numbers 192 through 255 are for options sent from the HC-Receiver to 1576 the HC-Sender. Similarly, feature numbers 128 through 191 are for 1577 features located at the HC-Sender; feature numbers 192 through 255 1578 are for features located at the HC-Receiver. (Change options for a 1579 feature are sent *to* the feature location; Prefer and Confirm 1580 options are sent *from* the feature location. Thus, Change(128) 1581 options are sent by the HC-Receiver by definition, while Change(192) 1582 options are sent by the HC-Sender.) 1584 For example, consider a DCCP connection where the A-to-B half- 1585 connection uses CCID 4 and the B-to-A half-connection uses CCID 5. 1586 Here is how a sampling of CCID-specific options and features are 1587 assigned to half-connections: 1589 Relevant Relevant 1590 Packet Option Half-conn. CCID 1591 ------ ------ ---------- ---- 1592 A > B 128 A-to-B 4 1593 A > B 192 B-to-A 5 1594 A > B Change(128, ...) B-to-A 5 1595 A > B Prefer(128, ...) A-to-B 4 1596 A > B Confirm(128, ...) A-to-B 4 1597 A > B Change(192, ...) A-to-B 4 1598 A > B Prefer(192, ...) B-to-A 5 1599 A > B Confirm(192, ...) B-to-A 5 1601 CCID-specific options and features have no clear meaning when the 1602 relevant CCID is in flux. A DCCP SHOULD respond to CCID-specific 1603 options and features with Ignored options during those times. 1605 7. Acknowledgements 1607 Congestion control requires receivers to transmit information about 1608 packet losses and ECN marks to senders. DCCP receivers MUST report 1609 all congestion they see, as defined by the relevant CCID profile. 1610 Each CCID says when acknowledgements should be sent, what options 1611 they must use, how they should be congestion controlled, and so on. 1613 Most acknowledgements use DCCP options. For example, on a half- 1614 connection with CCID 2 (TCP-like), the receiver reports 1615 acknowledgement information using the Ack Vector option. This 1616 section describes common acknowledgement options and shows how acks 1617 using those options will commonly work. Full descriptions of the 1618 acknowledgement mechanisms used for each CCID are laid out in the 1619 CCID profile specifications. 1621 Acknowledgement options, such as Ack Vector, are only allowed on 1622 DCCP-Ack, DCCP-DataAck, DCCP-Close, and DCCP-CloseReq packets. 1624 7.1. Acks of Acks and Unidirectional Connections 1626 DCCP was designed to work well for both bidirectional and 1627 unidirectional flows of data, and for connections that transition 1628 between these states. However, acknowledgements required for a 1629 unidirectional connection are very different from those required for 1630 a bidirectional connection. In particular, unidirectional 1631 connections need to worry about acks of acks. 1633 The ack-of-acks problem arises because some acknowledgement 1634 mechanisms are reliable. For example, an HC-Receiver using CCID 2, 1635 TCP-like Congestion Control, sends Ack Vectors containing completely 1636 reliable acknowledgement information. The HC-Sender should 1637 occasionally inform the HC-Receiver that it has received an ack. If 1638 it did not, the HC-Receiver might resend complete Ack Vector 1639 information, going back to the start of the connection, with every 1640 DCCP-Ack packet! However, note that acks-of-acks need not be 1641 reliable themselves: when an ack-of-acks is lost, the HC-Receiver 1642 will simply maintain old acknowledgement-related state for a little 1643 longer. Therefore, there is no need for acks of acks of acks. 1645 When communication is bidirectional, any required acks of acks are 1646 automatically contained in normal acknowledgements for data packets. 1647 On a unidirectional connection, however, the receiver DCCP sends no 1648 data, so the sender would not normally send acknowledgements. 1649 Therefore, the CCID in force on that half-connection must explicitly 1650 say whether, when, and how the HC-Sender should generate acks of 1651 acks. 1653 For example, consider a bidirectional connection where both half- 1654 connections use the same CCID (either 2 or 3), and where DCCP B goes 1655 *quiescent*. This means that the connection becomes unidirectional: 1656 DCCP B stops sending data, and sends only sends DCCP-Ack packets to 1657 DCCP A. For CCID 2, TCP-like Congestion Control, DCCP B uses Ack 1658 Vector to reliably communicate which packets it has received. As 1659 described above, DCCP A must occasionally acknowledge a pure 1660 acknowledgement from DCCP B, so that DCCP B can free old Ack Vector 1661 state. For instance, DCCP A might send a DCCP-DataAck packet every 1662 now and then, instead of DCCP-Data. In contrast, for CCID 3, TFRC 1663 Congestion Control, DCCP B's acknowledgements need not be reliable, 1664 since they contain cumulative loss rates; TFRC works even if every 1665 DCCP-Ack is lost. Therefore, DCCP A need never acknowledge an 1666 acknowledgement. 1668 When communication is unidirectional, a single CCID---in the 1669 example, the A-to-B CCID---controls both DCCPs' acknowledgements, in 1670 terms of their content, their frequency, and so forth. For 1671 bidirectional connections, the A-to-B CCID governs DCCP B's 1672 acknowledgements (including its acks of DCCP A's acks), while the B- 1673 to-A CCID governs DCCP A's acknowledgements. 1675 DCCP A switches its ack pattern from bidirectional to unidirectional 1676 when it notices that DCCP B has gone quiescent. It switches from 1677 unidirectional to bidirectional when it must acknowledge even a 1678 single DCCP-Data or DCCP-DataAck packet from DCCP B. (This includes 1679 the case where a single DCCP-Data or DCCP-DataAck packet was lost in 1680 transit, which is detectable using the # NDP field in the DCCP 1681 packet header.) 1682 Each CCID defines how to detect quiescence on that CCID, and how 1683 that CCID handles acks-of-acks on unidirectional connections. The B- 1684 to-A CCID defines when DCCP B has gone quiescent. Usually, this 1685 happens when a period has passed without B sending any data packets. 1686 For CCID 2, this period is roughly two round-trip times. The A-to-B 1687 CCID defines how DCCP A handles acks-of-acks once DCCP B has gone 1688 quiescent. 1690 7.2. Ack Piggybacking 1692 Acknowledgements of A-to-B data MAY be piggybacked on data sent by 1693 DCCP B, as long as that does not delay the acknowledgement longer 1694 than the A-to-B CCID would find acceptable. However, data 1695 acknowledgements often require more than 4 bytes to express. A large 1696 set of acknowledgements prepended to a large data packet might 1697 exceed the path's MTU. In this case, DCCP B SHOULD send separate 1698 DCCP-Data and DCCP-Ack packets, or wait for a smaller datagram (but 1699 not too long). 1701 Piggybacking is particularly common at DCCP A when the B-to-A half- 1702 connection is quiescent---that is, when DCCP A is just acknowledging 1703 DCCP B's acknowledgements, as described above. There are three 1704 reasons to acknowledge DCCP B's acknowledgements: to allow DCCP B to 1705 free up information about previously acknowledged data packets from 1706 A; to shrink the size of future acknowledgements; and to manipulate 1707 the rate future acknowledgements are sent. Since these are secondary 1708 concerns, DCCP A can generally afford to wait indefinitely for a 1709 data packet to piggyback its acknowledgement onto. 1711 Any restrictions on ack piggybacking are described in the relevant 1712 CCID's profile. 1714 7.3. Ack Ratio Feature 1716 With Ack Ratio, DCCP A can perform rudimentary congestion control on 1717 DCCP B's acknowledgement stream by telling DCCP B how to clock its 1718 acks. 1720 Ack Ratio has feature number 3. The Ack Ratio feature located at 1721 DCCP B equals the ratio of data packets sent by DCCP A to 1722 acknowledgement packets sent back by DCCP B. For example, if it is 1723 set to four, then DCCP B will send at least one acknowledgement 1724 packet for every four data packets DCCP A sends. DCCP A sends a 1725 "Change(Ack Ratio)" option to DCCP B to change DCCP B's ack ratio. 1727 An Ack Ratio option contains two bytes of data: a sixteen-bit 1728 integer representing the ratio. A new connection starts with Ack 1729 Ratio 2 for both DCCPs. 1731 This feature is non-negotiable. 1733 7.4. Use Ack Vector Feature 1735 The Use Ack Vector feature lets DCCPs negotiate whether they should 1736 use Ack Vector options to report congestion. Ack Vector provides 1737 detailed loss information, and lets senders report back to their 1738 applications whether particular packets were dropped. Use Ack Vector 1739 is mandatory for some CCIDs, and optional for others. 1741 Use Ack Vector has feature number 4. The Use Ack Vector feature 1742 located at DCCP B specifies whether DCCP B should use the Ack Vector 1743 option to report congestion back to DCCP A. DCCP A sends a 1744 "Change(Use Ack Vector, 1)" option to DCCP B to ask B to send Ack 1745 Vector options as part of its acknowledgement traffic. 1747 A Use Ack Vector option contains a single octet of data. The 1748 receiver should send Ack Vector options if and only if this octet is 1749 nonzero. A new connection starts with Use Ack Vector 0 for both 1750 DCCPs. 1752 7.5. Ack Vector Options 1754 The Ack Vector gives a run-length encoded history of data packets 1755 received at the client. Each octet of the vector gives the state of 1756 that data packet in the loss history, and the number of preceding 1757 packets with the same state. The option's data looks like this: 1759 +--------+--------+--------+--------+--------+ 1760 |001001??| Length |SSLLLLLL|SSLLLLLL|SSLLLLLL|... 1761 +--------+--------+--------+--------+--------+ 1762 Type=37/38 \________ Vector ________/ 1764 The two Ack Vector options (option types 37 and 38) differ only in 1765 the values they imply for ECN Nonce Echo. Section 8.2 describes this 1766 further. 1768 The vector itself consists of a series of octets, each of whose 1769 encoding is: 1771 0 1 2 3 4 5 6 7 1772 +-+-+-+-+-+-+-+-+ 1773 |St | Run Length| 1774 +-+-+-+-+-+-+-+-+ 1775 St[ate]: 2 bits 1777 Run Length: 6 bits 1779 State occupies the most significant two bits of each byte, and can 1780 have one of four values: 1782 0 Packet received (and not ECN marked). 1784 1 Packet ECN marked. 1786 2 Reserved. 1788 3 Packet not yet received. 1790 The first byte in the first Ack Vector option refers to the packet 1791 indicated in the Acknowledgement Number; subsequent bytes refer to 1792 older packets. (Ack Vector may not be sent on DCCP-Data packets, 1793 which lack an Acknowledgement Number.) If an Ack Vector contains the 1794 decimal values 0,192,3,64,5 and the Acknowledgement Number is 1795 decimal 100, then: 1797 Packet 100 was received (Acknowledgement Number 100, State 0, 1798 Run Length 0). 1800 Packet 99 was lost (State 3, Run Length 0). 1802 Packets 98, 97, 96 and 95 were received (State 0, Run Length 3). 1804 Packet 94 was ECN marked (State 1, Run Length 0). 1806 Packets 93, 92, 91, 90, 89, and 88 were received (State 0, Run 1807 Length 5). 1809 Run lengths of more than 64 must be encoded in multiple bytes. A 1810 single Ack Vector option can acknowledge up to 16192 data packets. 1811 Should more packets need to be acknowledged than can fit in 253 1812 bytes of Ack Vector, then multiple Ack Vector options can be sent. 1813 The second Ack Vector option will begin where the first Ack Vector 1814 option left off, and so forth. 1816 Packets dropped in the receive buffer should be reported as not 1817 received (State 3). The Receive Buffer Drops and Buffer Closed Drops 1818 options distinguishes between congestion losses and losses due to 1819 receive buffer overflow. 1821 7.5.1. Ack Vector Consistency 1823 A DCCP sender will commonly receive multiple acknowledgements for 1824 some of its data packets. For instance, an HC-Sender might receive 1825 two DCCP-Acks with Ack Vectors, both of which contained information 1826 about sequence number 24. (Because of cumulative acking, 1827 information about a sequence number is repeated in every ack until 1828 the HC-Sender acknowledges an ack. Perhaps the HC-Receiver is 1829 sending acks faster than the HC-Sender is acknowledging them.) In a 1830 perfect world, the two Ack Vectors would always be consistent. 1831 However, there are many reasons why they might not be: 1833 o The HC-Receiver received packet 24 between sending its acks, so 1834 the first ack said 24 was not received (State 3) and the second 1835 said it was received or ECN marked (State 0 or 1). 1837 o The HC-Receiver received packet 24 between sending its acks, and 1838 the network reordered the acks. In this case, the packet will 1839 appear to transition from State 0 or 1 to State 3. 1841 o The network duplicated packet 24, but only one of the duplicates 1842 was ECN marked. Depending on the HC-Receiver's implementation, 1843 this might show up as a transition between States 0 and 1. 1845 To cope with these situations, HC-Sender DCCP implementations SHOULD 1846 combine multiple received Ack Vector states according to this table: 1848 Received State 1849 0 1 3 1850 +---+---+---+ 1851 0 | 0 | 1 | 0 | 1852 Old +---+---+---+ 1853 1 | 1 | 1 | 1 | 1854 State +---+---+---+ 1855 3 | 0 | 1 | 3 | 1856 +---+---+---+ 1858 To read the table, choose the row corresponding to the packet's old 1859 state and the column corresponding to the packet's state in the 1860 newly received Ack Vector, then read the packet's new state off the 1861 table. The table is symmetric about the main diagonal, so it is 1862 indifferent to ack reordering. 1864 A HC-Sender MAY choose to throw away old information gleaned from 1865 the HC-Receiver's Ack Vectors, in which case it MUST ignore newly 1866 received acknowledgements from the HC-Receiver for those old 1867 packets. However, it is often kinder to save recent Ack Vector 1868 information for a while, so that the HC-Sender can undo its reaction 1869 to presumed congestion when a "lost" packet unexpectedly shows up 1870 (the transition from State 3 to State 0). 1872 7.5.2. Ack Vector Coverage 1874 We can divide the packets that have been sent from an HC-Sender to 1875 an HC-Receiver into four roughly contiguous groups. From oldest to 1876 youngest, these are: 1878 (1) Packets already acknowledged by the HC-Receiver, where the HC- 1879 Receiver knows that the HC-Sender has definitely received the 1880 acknowledgements. 1882 (2) Packets already acknowledged by the HC-Receiver, where the HC- 1883 Receiver cannot be sure that the HC-Sender has received the 1884 acknowledgements. 1886 (3) Packets not yet acknowledged by the HC-Receiver. 1888 (4) Packets not yet received by the HC-Receiver. 1890 The union of groups 2 and 3 is called the Unacknowledged Window. 1891 Generally, every Ack Vector the HC-Receiver sends will cover the 1892 whole Unacknowledged Window: Ack Vector acknowledgements are 1893 cumulative. (This simplifies Ack Vector maintenance at the HC- 1894 Receiver; see Section 7.9, below.) As packets are received, this 1895 window both grows on the right and shrinks on the left. It grows 1896 because there are more packets, and shrinks because the data 1897 packets' Acknowledgement Numbers will acknowledge previous 1898 acknowledgements, moving packets from group 2 into group 1. 1900 7.6. Slow Receiver Option 1902 An HC-Receiver sends the Slow Receiver option to its sender to 1903 indicate that it is having trouble keeping up with the sender's 1904 data. The HC-Sender SHOULD NOT increase its sending rate for 1905 approximately one round-trip time after seeing a packet with a Slow 1906 Receiver option. However, the Slow Receiver option does not indicate 1907 congestion, and the HC-Sender need not reduce its sending rate. (If 1908 necessary, the receiver can force the sender to slow down by 1909 dropping packets and including Receive Buffer Drops options.) APIs 1910 SHOULD let receiver applications set Slow Receiver, and sending 1911 applications determine whether or not their receivers are Slow. 1913 The Slow Receiver option takes just one byte: 1915 +--------+ 1916 |00000010| 1917 +--------+ 1918 Type=2 1920 Slow Receiver does not specify why the receiver is having trouble 1921 keeping up with the sender. Possible reasons include lack of buffer 1922 space, CPU overload, and application quotas. A sending application 1923 might react to Slow Receiver by reducing its sending rate or by 1924 switching to a lossier compression algorithm. However, a smart 1925 sender might actually *increase* its sending rate in response to 1926 Slow Receiver, by switching to a less-compressed sending format. (A 1927 highly-compressed data format might overwhelm a slow CPU more 1928 seriously than the higher memory requirements of a less-compressed 1929 data format.) This tension between transfer size (less compression 1930 means more congestion) and processing speed (more compression means 1931 more processing) cannot be resolved in general. 1933 Slow Receiver implements a portion of TCP's receive window 1934 functionality. We believe receiver operating systems and 1935 applications will find it much easier to send Slow Receiver when 1936 appropriate than they currently find it to correctly set a TCP 1937 receive window. 1939 7.7. Receive Buffer Drops Option 1941 The Receive Buffer Drops option indicates that some packets reported 1942 as not received were actually dropped at the endpoint, due to 1943 insufficient kernel space. The sender will probably react 1944 differently to receive buffer drops than congestion losses; for 1945 instance, it might not reduce its congestion window. The option's 1946 data looks like this: 1948 +--------+--------+--------+ 1949 |00100111|00000011| Count | 1950 +--------+--------+--------+ 1951 Type=39 Length=3 1953 Count: 8 bits 1954 The Count field says how many acknowledged packets were dropped 1955 at the receive buffer, limited to packets acknowledged by the 1956 packet containing the option. Count is simply a number between 0 1957 and 255. 1959 Multiple Receive Buffer Drops options are added together, so a 1960 single option with Count 2 is equivalent to two options, each with 1961 Count 1. A packet's total Receive Buffer Drops count MUST be less 1962 than or equal to the number of packets acknowledged by it as "not 1963 yet received". For example, assuming Ack Vector, the Receive Buffer 1964 Drops count must be less than or equal to the total number of 1965 State-3 packets in the Ack Vectors. 1967 If an ECN-marked packet is dropped at the receive buffer, it MUST 1968 NOT be included in the Receive Buffer Drops count. Such packets MUST 1969 be reported as the equivalent of "dropped by the network". (For Ack 1970 Vector, this is "not yet received".) 1972 7.8. Buffer Closed Drops Option 1974 The Buffer Closed Drops option indicates that some packets reported 1975 as not received were actually dropped at the endpoint, because the 1976 application is no longer listening for data. For example, a server 1977 might close its receiving half-connection to new data after 1978 receiving a complete request from the client. This would limit the 1979 amount of state the server would expend on incoming data, and thus 1980 reduce the potential damage from certain denial-of-service attacks. 1981 A DCCP receiving a Buffer Closed Drops option MAY report this event 1982 to the application. 1984 The semantics of Buffer Closed Drops are similar to those of Receive 1985 Buffer Drops. 1987 +--------+--------+--------+ 1988 |00101011|00000011| Count | 1989 +--------+--------+--------+ 1990 Type=43 Length=3 1992 Count: 8 bits 1993 Like the Count field in Receive Buffer Drops. 1995 Multiple Buffer Closed Drops options are added together, so a single 1996 option with Count 2 is equivalent to two options, each with Count 1. 1997 A packet's total Buffer Closed Drops count MUST be less than or 1998 equal to the number of packets acknowledged by it as "not yet 1999 received". If an ECN-marked packet is dropped due to a closed 2000 receive buffer, it MUST NOT be included in the Buffer Closed Drops 2001 count. Such packets MUST be reported as the equivalent of "dropped 2002 by the network". (For Ack Vector, this is "not yet received".) No 2003 packet should be included in both the Receive Buffer Drops and 2004 Buffer Closed Drops count. 2006 7.9. Ack Vector Implementation Notes 2008 This section discusses the particulars of DCCP acknowledgement 2009 handling, in the context of an abstract implementation for Ack 2010 Vector. It may safely be skipped. 2012 The first part of our implementation runs at the HC-Receiver, and 2013 therefore acknowledges data packets. It generates Ack Vector 2014 options. The implementation has the following characteristics: 2016 o At most one byte of state per acknowledged packet. 2018 o O(1) time to update that state when a new packet arrives (normal 2019 case). 2021 o Cumulative acknowledgements. 2023 o Quick removal of old state. 2025 The basic data structure is a circular buffer containing information 2026 about acknowledged packets. Each byte in this buffer contains a 2027 state and run length; the state can be 0 (packet received), 1 2028 (packet ECN marked), or 3 (packet not yet received). The live 2029 portion of the buffer is marked off by head and tail pointers; each 2030 is further marked with the HC-Sender sequence number to which it 2031 corresponds. The buffer grows from right to left. For example: 2033 +-------------------------------------------------------------------+ 2034 |S,L|S,L|S,L|S,L|S,L| | | | |S,L|S,L|S,L|S,L|S,L|S,L|S,L|S,L| 2035 +-------------------------------------------------------------------+ 2036 ^ ^ 2037 Tail, seqno = T Head, seqno = H 2039 <=== Head and Tail move this way <=== 2041 Each `S,L' represents a State/Run length byte. We will draw these 2042 buffers showing only their live portion; for example, here is 2043 another representation for the buffer above: 2045 +---------------------------------------------------+ 2046 (Head) H |S,L|S,L|S,L|S,L|S,L|S,L|S,L|S,L|S,L|S,L|S,L|S,L|S,L| T (Tail) 2047 +---------------------------------------------------+ 2049 This smaller Example Buffer contains actual data. 2051 +---------------------------+ 2052 10 |0,0|3,0|3,0|3,0|0,4|1,0|0,0| 0 [Example Buffer] 2053 +---------------------------+ 2055 In concrete terms, its meaning is as follows: 2057 Packet 10 was received. (The head of the buffer has sequence 2058 number 10, state 0, and run length 0.) 2060 Packets 9, 8, and 7 have not yet been received. (The three bytes 2061 preceding the head each have state 3 and run length 0.) 2063 Packets 6, 5, 4, 3, and 2 were received. 2065 Packet 1 was ECN marked. 2067 Packet 0 was received. 2069 7.9.1. New Packets 2071 When a packet arrives whose sequence number is larger than any in 2072 the buffer, the HC-Receiver simply moves the Head pointer to the 2073 left, increases the head sequence number, and stores a byte 2074 representing the packet into the buffer. For example, if HC-Sender 2075 packet 11 arrived ECN marked, the Example Buffer above would enter 2076 this new state (the change is marked with stars): 2078 +***----------------------------+ 2079 11 |1,0|0,0|3,0|3,0|3,0|0,4|1,0|0,0| 0 2080 +***----------------------------+ 2082 If the packet's state equals the state at the head of the buffer, 2083 the HC-Receiver may choose to increment its run length (up to the 2084 maximum). For example, if HC-Sender packet 11 arrived without ECN 2085 marking, the Example Buffer might enter this state instead: 2087 +--*------------------------+ 2088 11 |0,1|3,0|3,0|3,0|0,4|1,0|0,0| 0 2089 +--*------------------------+ 2091 Of course, the new packet's sequence number might not equal the 2092 expected sequence number. In this case, the HC-Receiver should enter 2093 the intervening packets as State 3. If several packets are missing, 2094 the HC-Receiver may prefer to enter multiple bytes with run length 2095 0, rather than a single byte with a larger run length; this 2096 simplifies table updates when one of the missing packets arrives. 2097 For example, if HC-Sender packet 12 arrived, the Example Buffer 2098 would enter this state: 2100 +*******----------------------------+ 2101 12 |0,0|3,0|0,1|3,0|3,0|3,0|0,4|1,0|0,0| 0 2102 +*******----------------------------+ 2104 When a new packet's sequence number is less than the head sequence 2105 number, the HC-Receiver should scan the table for the byte 2106 corresponding to that sequence number. (Slightly more complex 2107 indexing structures could reduce the complexity of this scan.) 2108 Assume that the sequence number was previously lost (State 3), and 2109 that it was stored in a byte with run length 0. Then the HC-Receiver 2110 can simply change the byte's state. For example, if HC-Sender packet 2111 8 was received, the Example Buffer would enter this state: 2113 +--------*------------------+ 2114 10 |0,0|3,0|0,0|3,0|0,4|1,0|0,0| 0 2115 +--------*------------------+ 2117 If the packet is not marked as lost, or if its sequence number is 2118 not contained in the table, the packet is probably a duplicate, and 2119 should be ignored. (The new packet's ECN marking state might differ 2120 from the state in the buffer; Section 7.5.1 describes what to do 2121 then.) If the packet's corresponding buffer byte has a non-zero run 2122 length, then the buffer might need be reshuffled to make space for 2123 one or two new bytes. 2125 Of course, the circular buffer may overflow, either when the HC- 2126 Sender is sending data at a very high rate, when the HC-Receiver's 2127 acknowledgements are not reaching the HC-Sender, or when the HC- 2128 Sender is forgetting to acknowledge those acks (so the HC-Receiver 2129 is unable to clean up old state). In this case, the HC-Receiver 2130 should either compress the buffer, transfer its state to a larger 2131 buffer, or drop all received packets until its buffer shrinks again. 2133 7.9.2. Sending Acknowledgements 2135 Whenever the HC-Receiver needs to generate an acknowledgement, the 2136 buffer's contents can simply be copied into one or more Ack Vector 2137 options. Copied Ack Vectors might not be maximally compressed; for 2138 example, the Example Buffer above contains three adjacent 3,0 bytes 2139 that could be combined into a single 3,2 byte. The HC-Receiver 2140 might, therefore, choose to compress the buffer in place before 2141 sending the option, or to compress the buffer while copying it; 2142 either operation is simple. 2144 Every acknowledgement sent by the HC-Receiver should include the 2145 entire state of the buffer. That is, acknowledgements are 2146 cumulative. 2148 The HC-Receiver should store information about each acknowledgement 2149 it sends in another buffer. Specifically, for every acknowledgement 2150 it sends, the HC-Receiver should store: 2152 o The HC-Receiver sequence number it used for the ack packet. 2154 o The HC-Sender sequence number it acknowledged (that is, the 2155 packet's Acknowledgement Number). Since acknowledgements are 2156 cumulative, this single number completely specifies the set of HC- 2157 Sender packets acknowledged by this ack packet. 2159 7.9.3. Clearing State 2161 Some of the HC-Sender's packets will include acknowledgement 2162 numbers, which ack the HC-Receiver's acknowledgements. When such an 2163 ack is received, the HC-Receiver simply finds the HC-Sender sequence 2164 number corresponding to that acked HC-Receiver packet, and moves the 2165 buffer's Tail pointer up to that sequence number. (It may choose to 2166 keep some older information, in case a lost packet shows up late.) 2167 For example, say that the HC-Receiver storing the Example Buffer had 2168 sent two acknowledgements already: 2170 HC-Receiver Ack 59 acknowledged HC-Sender Seq 3, and 2171 HC-Receiver Ack 60 acknowledged HC-Sender Seq 10. 2173 Say the HC-Receiver then received a DCCP-DataAck packet from the HC- 2174 Sender with Acknowledgement Number 59. This informs the HC-Receiver 2175 that the HC-Sender received, and processed, all the information in 2176 HC-Receiver packet 59. This packet acknowledged HC-Sender packet 3, 2177 so the HC-Sender has now received HC-Receiver's acknowledgements for 2178 packets 0, 1, 2, and 3. The Example Buffer should enter this state: 2180 +------------------*+ * 2181 10 |0,0|3,0|3,0|3,0|0,2| 4 2182 +------------------*+ * 2184 Note that the tail byte's run length was adjusted, since packet 3 2185 was in the middle of that byte. The HC-Receiver can also throw away 2186 the information about HC-Receiver Ack 59. 2188 A careful implementation might also modify its own acknowledgement 2189 record to ensure that it is reasonably robust to reordering. 2190 Suppose that the Example Buffer is as before, but that packet 9 now 2191 arrives, out of sequence. The Example buffer would enter this 2192 state: 2194 +----*----------------------+ 2195 10 |0,0|0,0|3,0|3,0|0,4|1,0|0,0| 0 2196 +----*----------------------+ 2198 Now, if the HC-Receiver then received a DCCP-DataAck packet from the 2199 HC-Sender with Sequence Number 11 and Acknowledgement Number 60, 2200 this might cause the tail pointer to be moved up to packet 10, 2201 although packet 9's arrival has not yet been acknowledged. Instead, 2202 when packet 9 arrived, the HC-Receiver's acknowledgement record 2203 might be modified to: 2205 HC-Receiver Ack 59 acknowledged HC-Sender Seq 3, and 2206 HC-Receiver Ack 60 acknowledged HC-Sender Seq 8. 2208 That is, any HC-Sender sequence number in the acknowledgement record 2209 is reduced to at most 8. This would prevent the Tail pointer from 2210 moving past packet 9 until the HC-Receiver knows that the HC-Sender 2211 has seen an Ack Vector indicating this packets arrival. 2213 7.9.4. Processing Acknowledgements 2215 When the HC-Sender receives an acknowledgement, it generally cares 2216 about the number of packets that were dropped and/or ECN marked. It 2217 simply reads this off the Ack Vector. Additionally, it may check the 2218 ECN Nonce for correctness. (As described in Section 7.5.1, it may 2219 want to keep more detailed information about acknowledged packets in 2220 case packets change states between acknowledgements, or in case the 2221 application queries whether a packet arrived.) 2223 The HC-Sender must also acknowledge the HC-Receiver's 2224 acknowledgements so that the HC-Receiver can free old Ack Vector 2225 state. (Since Ack Vector acknowledgements are reliable, the HC- 2226 Receiver must maintain and resend Ack Vector information until it is 2227 sure that the HC-Sender has received that information.) A simple 2228 algorithm suffices: since Ack Vector acknowledgements are 2229 cumulative, a single acknowledgement number tells HC-Receiver how 2230 much ack information has arrived. Assuming that the HC-Receiver 2231 sends no data, the HC-Sender can simply ensure that at least once a 2232 round-trip time, it sends a DCCP-DataAck packet acknowledging the 2233 latest DCCP-Ack packet it has received. Of course, the HC-Sender 2234 only needs to acknowledge the HC-Receiver's acknowledgements if the 2235 HC-Sender is also sending data. If the HC-Sender is not sending 2236 data, then the HC-Receiver's Ack Vector state is stable, and there 2237 is no need to shrink it. The HC-Sender must watch for drops and ECN 2238 marks on received DCCP-Ack packets so that it can adjust the HC- 2239 Receiver's ack-sending rate with Ack Ratio in response to 2240 congestion. 2242 If the other half-connection is not quiescent---that is, the HC- 2243 Receiver is sending data to the HC-Sender, possibly using another 2244 CCID---then the acknowledgements on that half-connection are 2245 sufficient for the HC-Receiver to free its state. 2247 8. Explicit Congestion Notification 2249 The DCCP protocol is fully ECN-aware. Every CCID specifies how its 2250 endpoints respond to ECN marks. Furthermore, DCCP, unlike TCP, 2251 allows senders to control the rate at which acknowledgements are 2252 generated (with options like Ack Ratio); this means that 2253 acknowledgements are generally congestion-controlled, and may have 2254 ECN-Capable Transport set. 2256 Every CCID profile describes how that profile interacts with ECN, 2257 both for data traffic and pure-acknowledgement traffic. A sender 2258 SHOULD set ECN-Capable Transport on a sent packet whenever the 2259 receiver has its ECN Capable feature turned on, and the relevant 2260 CCID allows it. 2262 The rest of this section describes the ECN Capable feature, and the 2263 interaction of the ECN Nonce with acknowledgement options such as 2264 Ack Vector. 2266 8.1. ECN Capable Feature 2268 The ECN Capable feature lets a DCCP inform its partner that it 2269 cannot read ECN bits from received IP headers, so the partner must 2270 not set ECN-Capable Transport on its packets. 2272 ECN Capable has feature number 2. The ECN Capable feature located at 2273 DCCP A indicates whether or not A can successfully read ECN bits 2274 from received frames' IP headers. (This is independent of whether it 2275 can set ECN bits on sent frames.) DCCP A sends a "Prefer(ECN 2276 Capable, 0)" option to DCCP B to inform B that A cannot read ECN 2277 bits. 2279 An ECN Capable feature contains a single octet of data. ECN 2280 capability is on if and only if this octet is nonzero. 2282 A new connection starts with ECN Capable 1 (that is, ECN capable) 2283 for both DCCPs. If a DCCP is not ECN capable, it MUST send 2284 "Prefer(ECN Capable, 0)" options to the other endpoint until 2285 acknowledged (by "Change(ECN Capable, 0)") or the connection closes. 2286 Furthermore, it MUST NOT accept any data until the other endpoint 2287 sends "Change(ECN Capable, 0)". 2289 8.2. ECN Nonces 2291 Congestion avoidance will not occur, and the receiver will sometimes 2292 get its data faster, when the sender is not told about any 2293 congestion events. Thus, the receiver has some incentive to falsify 2294 acknowledgement information, reporting that marked or dropped 2295 packets were actually received unmarked. This problem is more 2296 serious with DCCP than with TCP, since TCP provides reliable 2297 transport: it is more difficult with TCP to lie about lost packets 2298 without breaking the application. 2300 ECN Nonces are a general mechanism to prevent ECN cheating (or loss 2301 cheating). Two values for the two-bit ECN header field indicate ECN- 2302 Capable Transport, 01 and 10. The second code point, 10, is the ECN 2303 Nonce. In general, a protocol sender chooses between these code 2304 points randomly on its output packets, remembering the sequence it 2305 chose. The protocol receiver reports, on every acknowledgement, the 2306 number of ECN Nonces it has received thus far. This is called the 2307 ECN Nonce Echo. Since ECN marking and packet dropping both destroy 2308 the ECN Nonce, a receiver that lies about an ECN mark or packet drop 2309 has a 50% chance of guessing right and avoiding discipline. The 2310 sender may react punitively to an ECN Nonce mismatch, possibly up to 2311 dropping the connection. The ECN Nonce Echo field need not be an 2312 integer; one bit is enough to catch 50% of infractions. 2314 In DCCP, the ECN Nonce Echo field is encoded in acknowledgement 2315 options. For example, the Ack Vector option comes in two forms, Ack 2316 Vector [Nonce 0] (option 37) and Ack Vector [Nonce 1] (option 38), 2317 corresponding to the two values for a one-bit ECN Nonce Echo. The 2318 Nonce Echo for a given Ack Vector equals the base-2 modulus of the 2319 number of received ECN Nonce packets represented by that Ack Vector. 2320 Only packets marked as State 0 matter for this calculation (that is, 2321 received packets that were not ECN marked or dropped in the receive 2322 buffer). Every Ack Vector option is detailed enough for the sender 2323 to determine what the Nonce Echo should have been. It can check this 2324 calculation against the actual Nonce Echo, and complain if there is 2325 a mismatch. 2327 (The Ack Vector could conceivably report every ECN Nonce packet, 2328 using a separate code point for received ECN Nonces. However, this 2329 would limit Ack Vector's compressibility without providing much 2330 extra protection.) 2331 Consider a half-connection from DCCP A to DCCP B. DCCP A SHOULD set 2332 ECN Nonces on its packets, and remember which packets had nonces, 2333 whenever DCCP B reports that it is ECN Capable. An ECN-capable 2334 endpoint MUST calculate and use the correct value for ECN Nonce Echo 2335 when sending acknowledgement options. An ECN-incapable endpoint, 2336 however, SHOULD treat the ECN Nonce Echo as always zero. When a 2337 sender detects an ECN Nonce Echo mismatch, it SHOULD behave as if 2338 the receiver had reported one or more packets as ECN-marked (instead 2339 of unmarked). It MAY take more punitive action, such as resetting 2340 the connection. 2342 9. Multihoming and Mobility 2344 DCCP provides primitive support for multihoming and mobility, via a 2345 mechanism for transferring a connection endpoint from one IP address 2346 to another. The moving endpoint must negotiate mobility support 2347 beforehand, and both endpoints must share their Connection Nonces. 2348 When the moving endpoint gets a new IP address, it sends a DCCP-Move 2349 packet from that address to the stationary endpoint, including proof 2350 that it knows both nonces. The stationary endpoint then changes its 2351 connection state to use the new IP address. 2353 DCCP's support for mobility is intended to solve only the simplest 2354 multihoming and mobility problems. For instance, DCCP has no support 2355 for simultaneous moves. Applications requiring more complex mobility 2356 semantics, or more stringent security guarantees, should use an 2357 existing solution like Mobile IP or Snoeren and Balakrishnan's work 2358 [SB00]. 2360 9.1. Mobility Capable Feature 2362 A DCCP uses the Mobility Capable feature to inform its partner that 2363 it would like to be able to change its IP address and/or port during 2364 the course of the connection. 2366 Mobility Capable has feature number 5. The Mobility Capable feature 2367 located at DCCP A indicates whether or not A will accept a DCCP-Move 2368 packet sent by B. DCCP B sends a "Change(Mobility Capable, 1)" 2369 option to DCCP A to inform it that B might like to move later. 2371 A Mobility Capable feature contains a single octet of data. Mobility 2372 is allowed if and only if this octet is nonzero. A DCCP MUST reject 2373 a DCCP-Move packet referring to a connection when Mobility Capable 2374 is 0; however, it MAY reject a valid DCCP-Move packet even when 2375 Mobility Capable is 1. 2377 A new connection starts with Mobility Capable 0 (that is, mobility 2378 is not allowed) for both DCCPs. 2380 9.2. Security 2382 The DCCP mobility mechanism, like DCCP in general, does not provide 2383 cryptographic security guarantees. Nevertheless, DCCP-Move packets 2384 must have valid sequence numbers and Connection Proof, providing 2385 protection against some classes of attackers. Specifically, an 2386 attacker cannot move a DCCP connection to a new IP address unless 2387 they know both the Connection Proof and a valid sequence number. If 2388 initial sequence numbers and Connection Nonces are chosen well (that 2389 is, randomly), this means that attackers must snoop on data packets 2390 to get any reasonable probability of success. Section 14 further 2391 describes DCCP security considerations. 2393 9.3. Congestion Control State 2395 Once an endpoint has transitioned to a new IP address, the 2396 connection is effectively a new connection in terms of its 2397 congestion control state: the accumulated information about 2398 congestion between the old endpoints no longer applies. Both DCCPs 2399 MUST initialize their congestion control state (windows, rates, and 2400 so forth) to that of a new connection---that is, they must "slow 2401 start"---unless they have high-quality information about actual 2402 network conditions between the two new endpoints. Normally, the only 2403 way to get this information would be by instrumenting a DCCP 2404 connection between the new addresses. 2406 Similarly, the endpoints' configured MTUs (see 10) should be 2407 reinitialized, and PMTU discovery performed again, following an IP 2408 address change. 2410 9.4. Loss During Transition 2412 (This section is preliminary.) Several loss and delay events may 2413 affect the transition of a DCCP connection from one IP address to 2414 another. The DCCP-Move packet itself might be lost; the 2415 acknowledgement to that packet might be lost, leaving the mobile 2416 endpoint unsure of whether the transition has completed; and data 2417 from the old endpoint might continue to arrive at the receiver even 2418 after the transition. 2420 To protect against lost DCCP-Move packets, the mobile host SHOULD 2421 retransmit a DCCP-Move packet if it does not receive an 2422 acknowledgement within a reasonable time period. Section 4.10 2423 describes the mechanism used to protect against duplicate DCCP-Move 2424 packets. 2426 A receiver MAY drop all data received from the old IP address/port 2427 pair, once a DCCP-Move has successfully completed. Alternately, it 2428 MAY accept one loss window's worth of this data. Congestion and loss 2429 events on this data SHOULD NOT affect the new connection's 2430 congestion control state. The receiver MUST NOT accept data with the 2431 old IP address/port pair past one loss window, and SHOULD send DCCP- 2432 Resets in response to those packets. 2434 During some transition period, acknowledgements from the receiver to 2435 the mobile host will contain information about packets sent both 2436 from the old IP address/port pair, and from the new IP address/port 2437 pair. The mobile DCCP MUST NOT let loss events on packets from the 2438 old IP address/port pair affect the new congestion control state. 2440 10. Path MTU Discovery 2442 A DCCP implementation should be capable of performing Path MTU 2443 (PMTU) discovery, as described in [RFC 1191]. The API to DCCP SHOULD 2444 allow this mechanism to be disabled in cases where IP fragmentation 2445 is preferred. The rest of this section assumes PMTU discovery has 2446 not been disabled. 2448 A DCCP implementation MUST maintain its idea of the current PMTU for 2449 each active DCCP session. The PMTU should be initialized from the 2450 interface MTU that will be used to send packets. 2452 To perform PMTU discovery, the DCCP sender sets the IP Don't 2453 Fragment (DF) bit. However, it is undersirable for MTU discovery to 2454 occur on the initial connection setup handshake, as the connection 2455 setup process may not be representative of packet sizes used during 2456 the connection, and performing MTU discovery on the initial 2457 handshake might unnecessarily delay connection establishment. Thus, 2458 DF SHOULD NOT be set on DCCP-Request and DCCP-Response packets. In 2459 addition DF SHOULD NOT be set on DCCP-Reset packets, although 2460 typically these would be small enough to not be a problem. On all 2461 other DCCP packets, DF SHOULD be set. 2463 Any API to DCCP MUST allow the application to discover DCCP's 2464 current PMTU. DCCP applications SHOULD use the API to discover the 2465 PMTU, and SHOULD NOT send datagrams that are greater than the PMTU; 2466 the only exception to this is if the application disables PMTU 2467 discovery. If the application tries to send a packet bigger than the 2468 PMTU, the DCCP implementation MUST drop the packet and return an 2469 appropriate error. 2471 As specified in [RFC 1191], when a router receives a packet with DF 2472 set that is larger than the PMTU, it sends an ICMP Destination 2473 Unreachable message to the source of the datagram with the Code 2474 indicating "fragmentation needed and DF set" (also known as a 2475 "Datagram Too Big" message). When a DCCP implementation receives a 2476 Datagram Too Big message, it decreases its PMTU to the Next-Hop MTU 2477 value given in the ICMP message. If the MTU given in the message is 2478 zero, the sender chooses a value for PMTU using the algorithm 2479 described in Section 7 of [RFC 1191]. If the MTU given in the 2480 message is greater than the current PMTU, the Datagram Too Big 2481 message is ignored, as described in [RFC 1191]. (We are aware that 2482 this may cause problems for DCCP endpoints behind certain 2483 firewalls.) 2485 If the DCCP implementation has decreased the PMTU, and the sending 2486 application attempts to send a packet larger than the new MTU, the 2487 API MUST cause the send to fail returning an appropriate error to 2488 the application, and the application SHOULD then use the API to 2489 query the new value of the PMTU. When this occurs, it is possible 2490 that the kernel has some packets buffered for transmission that are 2491 smaller than the old PMTU, but larger than the new PMTU. The kernel 2492 MAY send these packets with the DF bit cleared, or it MAY discard 2493 these packets; it MUST NOT transmit these datagrams with the DF bit 2494 set. 2496 DCCP currently provides no way to increase the PMTU once it has 2497 decreased. 2499 A DCCP sender MAY optionally treat the reception of an ICMP Datagram 2500 Too Big message as an indication that the packet being reported was 2501 not lost due congestion, and so for the purposes of congestion 2502 control it MAY ignore the DCCP receiver's indication that this 2503 packet did not arrive. However, if this is done, then the DCCP 2504 sender MUST check the ECN bits of the IP header echoed in the ICMP 2505 message, and only perform this optimization if these ECN bits 2506 indicate that the packet did not experience congestion prior to 2507 reaching the router whose MTU it exceeded. 2509 11. Abstract API 2511 TBA 2513 12. Multiplexing Issues 2515 In contrast to TCP, DCCP does not offer reliable ordered delivery. 2516 As a consequence, with DCCP there are no inherent performance 2517 penalties in layering functionality above DCCP to multiplex several 2518 sub-flows into a single DCCP connection. 2520 However, this approach of multiplexing sub-flows above DCCP will not 2521 work in circumstances such as RTP where the RTP subflows require 2522 separate port numbers. In this case, if it is desired to share 2523 congestion control state among multiple DCCP flows that share the 2524 same source and destination addresses, the possibilities are to add 2525 DCCP-specific mechanisms to enable this, or to use a generic 2526 multiplexing facility like the Congestion Manager [RFC 3124] 2527 residing below the transport layer. For some DCCP flows, the 2528 ability to specify the congestion control mechanism might be 2529 critical, and for these flows the Congestion Manager will only be a 2530 viable tool if it allows DCCP to specify the congestion control 2531 mechanism used by the Congestion Manager for that flow. Thus, to 2532 allow the sharing of congestion control state among multiple DCCP 2533 flows, the alternatives seem to be to add DCCP-specific 2534 functionality to the Congestion Manager, or to add a similar layer 2535 below DCCP that is specific to DCCP. We defer issues of DCCP 2536 operating over a revised version of the Congestion Manager, or over 2537 a DCCP-specific module for the sharing of congestion control state, 2538 to later work. 2540 13. DCCP and RTP 2542 This section discusses the relationship between DCCP and RTP [RFC 2543 1889]. 2545 TBA 2547 14. Security Considerations 2549 DCCP does not provide cryptographic security guarantees. 2550 Applications desiring hard security should use IPsec or end-to-end 2551 security of some kind. 2553 Nevertheless, DCCP is intended to protect against some classes of 2554 attackers. Attackers cannot hijack a DCCP connection (close the 2555 connection unexpectedly, or cause attacker data to be accepted by an 2556 endpoint as if it came from the sender) unless they can guess valid 2557 sequence numbers. Thus, as long as endpoints choose initial sequence 2558 numbers well, a DCCP attacker must snoop on data packets to get any 2559 reasonable probability of success. The sequence number validity 2560 (Section 4.3) and mobility (Section 9) mechanisms provide this 2561 guarantee. 2563 This section is not in its final state. Further research is needed 2564 to ensure that we have met our stated security requirement. 2566 15. IANA Considerations 2568 DCCP introduces five sets of numbers whose values should be 2569 allocated by IANA. 2571 o 32-bit Service Names (Section 4.5). 2573 o 32-bit DCCP-Reset Reasons (Section 4.9). 2575 o 8-bit DCCP Option Types (Section 5). The CCID-specific options 128 2576 through 255 need not be allocated by IANA. 2578 o 8-bit DCCP Feature Numbers (Section 5.3). The CCID-specific 2579 features 128 through 255 need not be allocated by IANA. 2581 o 8-bit DCCP Congestion Control Identifiers (CCIDs) (Section 6). 2583 In addition, DCCP requires a Protocol Number to be added to the 2584 registry of Assigned Internet Protocol Numbers. Experimental 2585 implementors should use Protocol Number 33 for DCCP, but this number 2586 may change in future. 2588 16. Thanks 2590 There is a wealth of work in this area, including the Congestion 2591 Manager. We thank the staff and interns of ICIR and, formerly, 2592 ACIRI, the members of the End-to-End Research Group, and the members 2593 of the Transport Area Working Group for their feedback on DCCP. 2595 17. References 2597 [CCID 2 PROFILE] S. Floyd and E. Kohler. Profile for DCCP Congestion 2598 Control ID 2: TCP-like Congestion Control. Work in progress. 2600 [CCID 3 PROFILE] J. Padhye, S. Floyd, and E. Kohler. Profile for 2601 DCCP Congestion Control ID 3: TFRC Congestion Control. Work in 2602 progress. 2604 [RFC 793] J. Postol, editor. Transmission Control Protocol. RFC 793. 2606 [RFC 1191] J. C. Mogul and S. E. Deering. Path MTU discovery. RFC 2607 1191. 2609 [RFC 1889] Audio-Video Transport Working Group, H. Schulzrinne, S. 2610 Casner, R. Frederick, and V. Jacobson. RTP: A Transport 2611 Protocol for Real-Time Applications. RFC 1889. 2613 [RFC 2026] S. Bradner. The Internet Standards Process---Revision 3. 2614 RFC 2026. 2616 [RFC 2460] S. Deering and R. Hinden. Internet Protocol, Version 6 2617 (IPv6) Specification. RFC 2460. 2619 [RFC 2960] R. Stewart, Q. Xie, K. Morneault, C. Sharp, H. 2620 Schwarzbauer, T. Taylor, I. Rytina, M. Kalla, L. Zhang, and V. 2621 Paxson. Stream Control Transmission Protocol. RFC 2960. 2623 [RFC 3124] H. Balakrishnan and S. Seshan. The Congestion Manager. 2624 RFC 3124. 2626 [RFC 3168] K.K. Ramakrishnan, S. Floyd, and D. Black. The Addition 2627 of Explicit Congestion Notification (ECN) to IP. RFC 3168. 2628 September 2001. 2630 [SB00] Alex C. Snoeren and Hari Balakrishnan. An End-to-End Approach 2631 to Host Mobility. Proc. 6th Annual ACM/IEEE International 2632 Conference on Mobile Computing and Networking (MOBICOM '00), 2633 August 2000. 2635 [WES01] David Wetherall, David Ely, Neil Spring. Robust ECN 2636 Signaling with Nonces. draft-ietf-tsvwg-tcp-nonce-00.txt, work 2637 in progress, January 2001. 2639 18. Authors' Addresses 2641 Eddie Kohler 2642 Mark Handley 2643 Sally Floyd 2645 ICSI Center for Internet Research 2646 1947 Center Street, Suite 600 2647 Berkeley, CA 94704 USA 2649 Jitendra Padhye 2651 Microsoft Research 2652 One Microsoft Way 2653 Redmond, WA 98052 USA