7 Network Working Group R. Stewart
\r
8 Request for Comments: 2960 Q. Xie
\r
9 Category: Standards Track Motorola
\r
28 Stream Control Transmission Protocol
\r
32 This document specifies an Internet standards track protocol for the
\r
33 Internet community, and requests discussion and suggestions for
\r
34 improvements. Please refer to the current edition of the "Internet
\r
35 Official Protocol Standards" (STD 1) for the standardization state
\r
36 and status of this protocol. Distribution of this memo is unlimited.
\r
40 Copyright (C) The Internet Society (2000). All Rights Reserved.
\r
44 This document describes the Stream Control Transmission Protocol
\r
45 (SCTP). SCTP is designed to transport PSTN signaling messages over
\r
46 IP networks, but is capable of broader applications.
\r
48 SCTP is a reliable transport protocol operating on top of a
\r
49 connectionless packet network such as IP. It offers the following
\r
50 services to its users:
\r
52 -- acknowledged error-free non-duplicated transfer of user data,
\r
53 -- data fragmentation to conform to discovered path MTU size,
\r
58 Stewart, et al. Standards Track [Page 1]
\r
60 RFC 2960 Stream Control Transmission Protocol October 2000
\r
63 -- sequenced delivery of user messages within multiple streams,
\r
64 with an option for order-of-arrival delivery of individual user
\r
66 -- optional bundling of multiple user messages into a single SCTP
\r
68 -- network-level fault tolerance through supporting of multi-
\r
69 homing at either or both ends of an association.
\r
71 The design of SCTP includes appropriate congestion avoidance behavior
\r
72 and resistance to flooding and masquerade attacks.
\r
114 Stewart, et al. Standards Track [Page 2]
\r
116 RFC 2960 Stream Control Transmission Protocol October 2000
\r
121 1. Introduction.................................................. 5
\r
122 1.1 Motivation.................................................. 6
\r
123 1.2 Architectural View of SCTP.................................. 6
\r
124 1.3 Functional View of SCTP..................................... 7
\r
125 1.3.1 Association Startup and Takedown........................ 8
\r
126 1.3.2 Sequenced Delivery within Streams....................... 9
\r
127 1.3.3 User Data Fragmentation................................. 9
\r
128 1.3.4 Acknowledgement and Congestion Avoidance................ 9
\r
129 1.3.5 Chunk Bundling ......................................... 10
\r
130 1.3.6 Packet Validation....................................... 10
\r
131 1.3.7 Path Management......................................... 11
\r
132 1.4 Key Terms................................................... 11
\r
133 1.5 Abbreviations............................................... 15
\r
134 1.6 Serial Number Arithmetic.................................... 15
\r
135 2. Conventions.................................................... 16
\r
136 3. SCTP packet Format............................................ 16
\r
137 3.1 SCTP Common Header Field Descriptions....................... 17
\r
138 3.2 Chunk Field Descriptions.................................... 18
\r
139 3.2.1 Optional/Variable-length Parameter Format............... 20
\r
140 3.3 SCTP Chunk Definitions...................................... 21
\r
141 3.3.1 Payload Data (DATA)..................................... 22
\r
142 3.3.2 Initiation (INIT)....................................... 24
\r
143 3.3.2.1 Optional or Variable Length Parameters.............. 26
\r
144 3.3.3 Initiation Acknowledgement (INIT ACK)................... 30
\r
145 3.3.3.1 Optional or Variable Length Parameters.............. 33
\r
146 3.3.4 Selective Acknowledgement (SACK)........................ 33
\r
147 3.3.5 Heartbeat Request (HEARTBEAT)........................... 37
\r
148 3.3.6 Heartbeat Acknowledgement (HEARTBEAT ACK)............... 38
\r
149 3.3.7 Abort Association (ABORT)............................... 39
\r
150 3.3.8 Shutdown Association (SHUTDOWN)......................... 40
\r
151 3.3.9 Shutdown Acknowledgement (SHUTDOWN ACK)................. 40
\r
152 3.3.10 Operation Error (ERROR)................................ 41
\r
153 3.3.10.1 Invalid Stream Identifier.......................... 42
\r
154 3.3.10.2 Missing Mandatory Parameter........................ 43
\r
155 3.3.10.3 Stale Cookie Error................................. 43
\r
156 3.3.10.4 Out of Resource.................................... 44
\r
157 3.3.10.5 Unresolvable Address............................... 44
\r
158 3.3.10.6 Unrecognized Chunk Type............................ 44
\r
159 3.3.10.7 Invalid Mandatory Parameter........................ 45
\r
160 3.3.10.8 Unrecognized Parameters............................ 45
\r
161 3.3.10.9 No User Data....................................... 46
\r
162 3.3.10.10 Cookie Received While Shutting Down............... 46
\r
163 3.3.11 Cookie Echo (COOKIE ECHO).............................. 46
\r
164 3.3.12 Cookie Acknowledgement (COOKIE ACK).................... 47
\r
165 3.3.13 Shutdown Complete (SHUTDOWN COMPLETE).................. 48
\r
166 4. SCTP Association State Diagram................................. 48
\r
170 Stewart, et al. Standards Track [Page 3]
\r
172 RFC 2960 Stream Control Transmission Protocol October 2000
\r
175 5. Association Initialization..................................... 52
\r
176 5.1 Normal Establishment of an Association...................... 52
\r
177 5.1.1 Handle Stream Parameters................................ 54
\r
178 5.1.2 Handle Address Parameters............................... 54
\r
179 5.1.3 Generating State Cookie................................. 56
\r
180 5.1.4 State Cookie Processing................................. 57
\r
181 5.1.5 State Cookie Authentication............................. 57
\r
182 5.1.6 An Example of Normal Association Establishment.......... 58
\r
183 5.2 Handle Duplicate or unexpected INIT, INIT ACK, COOKIE ECHO,
\r
184 and COOKIE ACK.............................................. 60
\r
185 5.2.1 Handle Duplicate INIT in COOKIE-WAIT
\r
186 or COOKIE-ECHOED States................................. 60
\r
187 5.2.2 Unexpected INIT in States Other than CLOSED,
\r
188 COOKIE-ECHOED, COOKIE-WAIT and SHUTDOWN-ACK-SENT........ 61
\r
189 5.2.3 Unexpected INIT ACK..................................... 61
\r
190 5.2.4 Handle a COOKIE ECHO when a TCB exists.................. 62
\r
191 5.2.4.1 An Example of a Association Restart................. 64
\r
192 5.2.5 Handle Duplicate COOKIE ACK............................. 66
\r
193 5.2.6 Handle Stale COOKIE Error............................... 66
\r
194 5.3 Other Initialization Issues................................. 67
\r
195 5.3.1 Selection of Tag Value.................................. 67
\r
196 6. User Data Transfer............................................. 67
\r
197 6.1 Transmission of DATA Chunks................................. 69
\r
198 6.2 Acknowledgement on Reception of DATA Chunks................. 70
\r
199 6.2.1 Tracking Peer's Receive Buffer Space.................... 73
\r
200 6.3 Management Retransmission Timer............................. 75
\r
201 6.3.1 RTO Calculation......................................... 75
\r
202 6.3.2 Retransmission Timer Rules.............................. 76
\r
203 6.3.3 Handle T3-rtx Expiration................................ 77
\r
204 6.4 Multi-homed SCTP Endpoints.................................. 78
\r
205 6.4.1 Failover from Inactive Destination Address.............. 79
\r
206 6.5 Stream Identifier and Stream Sequence Number................ 80
\r
207 6.6 Ordered and Unordered Delivery.............................. 80
\r
208 6.7 Report Gaps in Received DATA TSNs........................... 81
\r
209 6.8 Adler-32 Checksum Calculation............................... 82
\r
210 6.9 Fragmentation............................................... 83
\r
211 6.10 Bundling .................................................. 84
\r
212 7. Congestion Control .......................................... 85
\r
213 7.1 SCTP Differences from TCP Congestion Control................ 85
\r
214 7.2 SCTP Slow-Start and Congestion Avoidance.................... 87
\r
215 7.2.1 Slow-Start.............................................. 87
\r
216 7.2.2 Congestion Avoidance.................................... 89
\r
217 7.2.3 Congestion Control...................................... 89
\r
218 7.2.4 Fast Retransmit on Gap Reports.......................... 90
\r
219 7.3 Path MTU Discovery.......................................... 91
\r
220 8. Fault Management.............................................. 92
\r
221 8.1 Endpoint Failure Detection.................................. 92
\r
222 8.2 Path Failure Detection...................................... 92
\r
226 Stewart, et al. Standards Track [Page 4]
\r
228 RFC 2960 Stream Control Transmission Protocol October 2000
\r
231 8.3 Path Heartbeat.............................................. 93
\r
232 8.4 Handle "Out of the blue" Packets............................ 95
\r
233 8.5 Verification Tag............................................ 96
\r
234 8.5.1 Exceptions in Verification Tag Rules.................... 97
\r
235 9. Termination of Association..................................... 98
\r
236 9.1 Abort of an Association..................................... 98
\r
237 9.2 Shutdown of an Association.................................. 98
\r
238 10. Interface with Upper Layer....................................101
\r
239 10.1 ULP-to-SCTP................................................101
\r
240 10.2 SCTP-to-ULP................................................111
\r
241 11. Security Considerations.......................................114
\r
242 11.1 Security Objectives........................................114
\r
243 11.2 SCTP Responses To Potential Threats........................115
\r
244 11.2.1 Countering Insider Attacks.............................115
\r
245 11.2.2 Protecting against Data Corruption in the Network......115
\r
246 11.2.3 Protecting Confidentiality.............................115
\r
247 11.2.4 Protecting against Blind Denial of Service Attacks.....116
\r
248 11.2.4.1 Flooding...........................................116
\r
249 11.2.4.2 Blind Masquerade...................................118
\r
250 11.2.4.3 Improper Monopolization of Services................118
\r
251 11.3 Protection against Fraud and Repudiation...................119
\r
252 12. Recommended Transmission Control Block (TCB) Parameters.......120
\r
253 12.1 Parameters necessary for the SCTP instance.................120
\r
254 12.2 Parameters necessary per association (i.e. the TCB)........120
\r
255 12.3 Per Transport Address Data.................................122
\r
256 12.4 General Parameters Needed..................................123
\r
257 13. IANA Considerations...........................................123
\r
258 13.1 IETF-defined Chunk Extension...............................123
\r
259 13.2 IETF-defined Chunk Parameter Extension.....................124
\r
260 13.3 IETF-defined Additional Error Causes.......................124
\r
261 13.4 Payload Protocol Identifiers...............................125
\r
262 14. Suggested SCTP Protocol Parameter Values......................125
\r
263 15. Acknowledgements..............................................126
\r
264 16. Authors' Addresses............................................126
\r
265 17. References....................................................128
\r
266 18. Bibliography..................................................129
\r
267 Appendix A .......................................................131
\r
268 Appendix B .......................................................132
\r
269 Full Copyright Statement .........................................134
\r
273 This section explains the reasoning behind the development of the
\r
274 Stream Control Transmission Protocol (SCTP), the services it offers,
\r
275 and the basic concepts needed to understand the detailed description
\r
282 Stewart, et al. Standards Track [Page 5]
\r
284 RFC 2960 Stream Control Transmission Protocol October 2000
\r
289 TCP [RFC793] has performed immense service as the primary means of
\r
290 reliable data transfer in IP networks. However, an increasing number
\r
291 of recent applications have found TCP too limiting, and have
\r
292 incorporated their own reliable data transfer protocol on top of UDP
\r
293 [RFC768]. The limitations which users have wished to bypass include
\r
296 -- TCP provides both reliable data transfer and strict order-of-
\r
297 transmission delivery of data. Some applications need reliable
\r
298 transfer without sequence maintenance, while others would be
\r
299 satisfied with partial ordering of the data. In both of these
\r
300 cases the head-of-line blocking offered by TCP causes unnecessary
\r
303 -- The stream-oriented nature of TCP is often an inconvenience.
\r
304 Applications must add their own record marking to delineate their
\r
305 messages, and must make explicit use of the push facility to
\r
306 ensure that a complete message is transferred in a reasonable
\r
309 -- The limited scope of TCP sockets complicates the task of
\r
310 providing highly-available data transfer capability using multi-
\r
313 -- TCP is relatively vulnerable to denial of service attacks, such
\r
316 Transport of PSTN signaling across the IP network is an application
\r
317 for which all of these limitations of TCP are relevant. While this
\r
318 application directly motivated the development of SCTP, other
\r
319 applications may find SCTP a good match to their requirements.
\r
321 1.2 Architectural View of SCTP
\r
323 SCTP is viewed as a layer between the SCTP user application ("SCTP
\r
324 user" for short) and a connectionless packet network service such as
\r
325 IP. The remainder of this document assumes SCTP runs on top of IP.
\r
326 The basic service offered by SCTP is the reliable transfer of user
\r
327 messages between peer SCTP users. It performs this service within
\r
328 the context of an association between two SCTP endpoints. Section 10
\r
329 of this document sketches the API which should exist at the boundary
\r
330 between the SCTP and the SCTP user layers.
\r
332 SCTP is connection-oriented in nature, but the SCTP association is a
\r
333 broader concept than the TCP connection. SCTP provides the means for
\r
334 each SCTP endpoint (Section 1.4) to provide the other endpoint
\r
338 Stewart, et al. Standards Track [Page 6]
\r
340 RFC 2960 Stream Control Transmission Protocol October 2000
\r
343 (during association startup) with a list of transport addresses
\r
344 (i.e., multiple IP addresses in combination with an SCTP port)
\r
345 through which that endpoint can be reached and from which it will
\r
346 originate SCTP packets. The association spans transfers over all of
\r
347 the possible source/destination combinations which may be generated
\r
348 from each endpoint's lists.
\r
350 _____________ _____________
\r
351 | SCTP User | | SCTP User |
\r
352 | Application | | Application |
\r
353 |-------------| |-------------|
\r
355 | Transport | | Transport |
\r
356 | Service | | Service |
\r
357 |-------------| |-------------|
\r
358 | |One or more ---- One or more| |
\r
359 | IP Network |IP address \/ IP address| IP Network |
\r
360 | Service |appearances /\ appearances| Service |
\r
361 |_____________| ---- |_____________|
\r
363 SCTP Node A |<-------- Network transport ------->| SCTP Node B
\r
365 Figure 1: An SCTP Association
\r
367 1.3 Functional View of SCTP
\r
369 The SCTP transport service can be decomposed into a number of
\r
370 functions. These are depicted in Figure 2 and explained in the
\r
371 remainder of this section.
\r
394 Stewart, et al. Standards Track [Page 7]
\r
396 RFC 2960 Stream Control Transmission Protocol October 2000
\r
399 SCTP User Application
\r
401 -----------------------------------------------------
\r
402 _____________ ____________________
\r
403 | | | Sequenced delivery |
\r
404 | Association | | within streams |
\r
405 | | |____________________|
\r
407 | | ____________________________
\r
408 | and | | User Data Fragmentation |
\r
409 | | |____________________________|
\r
411 | | ____________________________
\r
412 | | | Acknowledgement |
\r
414 | | | Congestion Avoidance |
\r
415 | | |____________________________|
\r
417 | | ____________________________
\r
418 | | | Chunk Bundling |
\r
419 | | |____________________________|
\r
421 | | ________________________________
\r
422 | | | Packet Validation |
\r
423 | | |________________________________|
\r
425 | | ________________________________
\r
426 | | | Path Management |
\r
427 |_____________| |________________________________|
\r
429 Figure 2: Functional View of the SCTP Transport Service
\r
431 1.3.1 Association Startup and Takedown
\r
433 An association is initiated by a request from the SCTP user (see the
\r
434 description of the ASSOCIATE (or SEND) primitive in Section 10).
\r
436 A cookie mechanism, similar to one described by Karn and Simpson in
\r
437 [RFC2522], is employed during the initialization to provide
\r
438 protection against security attacks. The cookie mechanism uses a
\r
439 four-way handshake, the last two legs of which are allowed to carry
\r
440 user data for fast setup. The startup sequence is described in
\r
441 Section 5 of this document.
\r
443 SCTP provides for graceful close (i.e., shutdown) of an active
\r
444 association on request from the SCTP user. See the description of
\r
445 the SHUTDOWN primitive in Section 10. SCTP also allows ungraceful
\r
446 close (i.e., abort), either on request from the user (ABORT
\r
450 Stewart, et al. Standards Track [Page 8]
\r
452 RFC 2960 Stream Control Transmission Protocol October 2000
\r
455 primitive) or as a result of an error condition detected within the
\r
456 SCTP layer. Section 9 describes both the graceful and the ungraceful
\r
459 SCTP does not support a half-open state (like TCP) wherein one side
\r
460 may continue sending data while the other end is closed. When either
\r
461 endpoint performs a shutdown, the association on each peer will stop
\r
462 accepting new data from its user and only deliver data in queue at
\r
463 the time of the graceful close (see Section 9).
\r
465 1.3.2 Sequenced Delivery within Streams
\r
467 The term "stream" is used in SCTP to refer to a sequence of user
\r
468 messages that are to be delivered to the upper-layer protocol in
\r
469 order with respect to other messages within the same stream. This is
\r
470 in contrast to its usage in TCP, where it refers to a sequence of
\r
471 bytes (in this document a byte is assumed to be eight bits).
\r
473 The SCTP user can specify at association startup time the number of
\r
474 streams to be supported by the association. This number is
\r
475 negotiated with the remote end (see Section 5.1.1). User messages
\r
476 are associated with stream numbers (SEND, RECEIVE primitives, Section
\r
477 10). Internally, SCTP assigns a stream sequence number to each
\r
478 message passed to it by the SCTP user. On the receiving side, SCTP
\r
479 ensures that messages are delivered to the SCTP user in sequence
\r
480 within a given stream. However, while one stream may be blocked
\r
481 waiting for the next in-sequence user message, delivery from other
\r
482 streams may proceed.
\r
484 SCTP provides a mechanism for bypassing the sequenced delivery
\r
485 service. User messages sent using this mechanism are delivered to
\r
486 the SCTP user as soon as they are received.
\r
488 1.3.3 User Data Fragmentation
\r
490 When needed, SCTP fragments user messages to ensure that the SCTP
\r
491 packet passed to the lower layer conforms to the path MTU. On
\r
492 receipt, fragments are reassembled into complete messages before
\r
493 being passed to the SCTP user.
\r
495 1.3.4 Acknowledgement and Congestion Avoidance
\r
497 SCTP assigns a Transmission Sequence Number (TSN) to each user data
\r
498 fragment or unfragmented message. The TSN is independent of any
\r
499 stream sequence number assigned at the stream level. The receiving
\r
506 Stewart, et al. Standards Track [Page 9]
\r
508 RFC 2960 Stream Control Transmission Protocol October 2000
\r
511 end acknowledges all TSNs received, even if there are gaps in the
\r
512 sequence. In this way, reliable delivery is kept functionally
\r
513 separate from sequenced stream delivery.
\r
515 The acknowledgement and congestion avoidance function is responsible
\r
516 for packet retransmission when timely acknowledgement has not been
\r
517 received. Packet retransmission is conditioned by congestion
\r
518 avoidance procedures similar to those used for TCP. See Sections 6
\r
519 and 7 for a detailed description of the protocol procedures
\r
520 associated with this function.
\r
522 1.3.5 Chunk Bundling
\r
524 As described in Section 3, the SCTP packet as delivered to the lower
\r
525 layer consists of a common header followed by one or more chunks.
\r
526 Each chunk may contain either user data or SCTP control information.
\r
527 The SCTP user has the option to request bundling of more than one
\r
528 user messages into a single SCTP packet. The chunk bundling function
\r
529 of SCTP is responsible for assembly of the complete SCTP packet and
\r
530 its disassembly at the receiving end.
\r
532 During times of congestion an SCTP implementation MAY still perform
\r
533 bundling even if the user has requested that SCTP not bundle. The
\r
534 user's disabling of bundling only affects SCTP implementations that
\r
535 may delay a small period of time before transmission (to attempt to
\r
536 encourage bundling). When the user layer disables bundling, this
\r
537 small delay is prohibited but not bundling that is performed during
\r
538 congestion or retransmission.
\r
540 1.3.6 Packet Validation
\r
542 A mandatory Verification Tag field and a 32 bit checksum field (see
\r
543 Appendix B for a description of the Adler-32 checksum) are included
\r
544 in the SCTP common header. The Verification Tag value is chosen by
\r
545 each end of the association during association startup. Packets
\r
546 received without the expected Verification Tag value are discarded,
\r
547 as a protection against blind masquerade attacks and against stale
\r
548 SCTP packets from a previous association. The Adler-32 checksum
\r
549 should be set by the sender of each SCTP packet to provide additional
\r
550 protection against data corruption in the network. The receiver of
\r
551 an SCTP packet with an invalid Adler-32 checksum silently discards
\r
562 Stewart, et al. Standards Track [Page 10]
\r
564 RFC 2960 Stream Control Transmission Protocol October 2000
\r
567 1.3.7 Path Management
\r
569 The sending SCTP user is able to manipulate the set of transport
\r
570 addresses used as destinations for SCTP packets through the
\r
571 primitives described in Section 10. The SCTP path management
\r
572 function chooses the destination transport address for each outgoing
\r
573 SCTP packet based on the SCTP user's instructions and the currently
\r
574 perceived reachability status of the eligible destination set. The
\r
575 path management function monitors reachability through heartbeats
\r
576 when other packet traffic is inadequate to provide this information
\r
577 and advises the SCTP user when reachability of any far-end transport
\r
578 address changes. The path management function is also responsible
\r
579 for reporting the eligible set of local transport addresses to the
\r
580 far end during association startup, and for reporting the transport
\r
581 addresses returned from the far end to the SCTP user.
\r
583 At association start-up, a primary path is defined for each SCTP
\r
584 endpoint, and is used for normal sending of SCTP packets.
\r
586 On the receiving end, the path management is responsible for
\r
587 verifying the existence of a valid SCTP association to which the
\r
588 inbound SCTP packet belongs before passing it for further processing.
\r
590 Note: Path Management and Packet Validation are done at the same
\r
591 time, so although described separately above, in reality they cannot
\r
592 be performed as separate items.
\r
596 Some of the language used to describe SCTP has been introduced in the
\r
597 previous sections. This section provides a consolidated list of the
\r
598 key terms and their definitions.
\r
600 o Active destination transport address: A transport address on a
\r
601 peer endpoint which a transmitting endpoint considers available
\r
602 for receiving user messages.
\r
604 o Bundling: An optional multiplexing operation, whereby more than
\r
605 one user message may be carried in the same SCTP packet. Each
\r
606 user message occupies its own DATA chunk.
\r
608 o Chunk: A unit of information within an SCTP packet, consisting of
\r
609 a chunk header and chunk-specific content.
\r
611 o Congestion Window (cwnd): An SCTP variable that limits the data,
\r
612 in number of bytes, a sender can send to a particular destination
\r
613 transport address before receiving an acknowledgement.
\r
618 Stewart, et al. Standards Track [Page 11]
\r
620 RFC 2960 Stream Control Transmission Protocol October 2000
\r
623 o Cumulative TSN Ack Point: The TSN of the last DATA chunk
\r
624 acknowledged via the Cumulative TSN Ack field of a SACK.
\r
626 o Idle destination address: An address that has not had user
\r
627 messages sent to it within some length of time, normally the
\r
628 HEARTBEAT interval or greater.
\r
630 o Inactive destination transport address: An address which is
\r
631 considered inactive due to errors and unavailable to transport
\r
634 o Message = user message: Data submitted to SCTP by the Upper Layer
\r
637 o Message Authentication Code (MAC): An integrity check mechanism
\r
638 based on cryptographic hash functions using a secret key.
\r
639 Typically, message authentication codes are used between two
\r
640 parties that share a secret key in order to validate information
\r
641 transmitted between these parties. In SCTP it is used by an
\r
642 endpoint to validate the State Cookie information that is returned
\r
643 from the peer in the COOKIE ECHO chunk. The term "MAC" has
\r
644 different meanings in different contexts. SCTP uses this term
\r
645 with the same meaning as in [RFC2104].
\r
647 o Network Byte Order: Most significant byte first, a.k.a., Big
\r
650 o Ordered Message: A user message that is delivered in order with
\r
651 respect to all previous user messages sent within the stream the
\r
652 message was sent on.
\r
654 o Outstanding TSN (at an SCTP endpoint): A TSN (and the associated
\r
655 DATA chunk) that has been sent by the endpoint but for which it
\r
656 has not yet received an acknowledgement.
\r
658 o Path: The route taken by the SCTP packets sent by one SCTP
\r
659 endpoint to a specific destination transport address of its peer
\r
660 SCTP endpoint. Sending to different destination transport
\r
661 addresses does not necessarily guarantee getting separate paths.
\r
663 o Primary Path: The primary path is the destination and source
\r
664 address that will be put into a packet outbound to the peer
\r
665 endpoint by default. The definition includes the source address
\r
666 since an implementation MAY wish to specify both destination and
\r
667 source address to better control the return path taken by reply
\r
668 chunks and on which interface the packet is transmitted when the
\r
669 data sender is multi-homed.
\r
674 Stewart, et al. Standards Track [Page 12]
\r
676 RFC 2960 Stream Control Transmission Protocol October 2000
\r
679 o Receiver Window (rwnd): An SCTP variable a data sender uses to
\r
680 store the most recently calculated receiver window of its peer, in
\r
681 number of bytes. This gives the sender an indication of the space
\r
682 available in the receiver's inbound buffer.
\r
684 o SCTP association: A protocol relationship between SCTP endpoints,
\r
685 composed of the two SCTP endpoints and protocol state information
\r
686 including Verification Tags and the currently active set of
\r
687 Transmission Sequence Numbers (TSNs), etc. An association can be
\r
688 uniquely identified by the transport addresses used by the
\r
689 endpoints in the association. Two SCTP endpoints MUST NOT have
\r
690 more than one SCTP association between them at any given time.
\r
692 o SCTP endpoint: The logical sender/receiver of SCTP packets. On a
\r
693 multi-homed host, an SCTP endpoint is represented to its peers as
\r
694 a combination of a set of eligible destination transport addresses
\r
695 to which SCTP packets can be sent and a set of eligible source
\r
696 transport addresses from which SCTP packets can be received. All
\r
697 transport addresses used by an SCTP endpoint must use the same
\r
698 port number, but can use multiple IP addresses. A transport
\r
699 address used by an SCTP endpoint must not be used by another SCTP
\r
700 endpoint. In other words, a transport address is unique to an
\r
703 o SCTP packet (or packet): The unit of data delivery across the
\r
704 interface between SCTP and the connectionless packet network
\r
705 (e.g., IP). An SCTP packet includes the common SCTP header,
\r
706 possible SCTP control chunks, and user data encapsulated within
\r
709 o SCTP user application (SCTP user): The logical higher-layer
\r
710 application entity which uses the services of SCTP, also called
\r
711 the Upper-layer Protocol (ULP).
\r
713 o Slow Start Threshold (ssthresh): An SCTP variable. This is the
\r
714 threshold which the endpoint will use to determine whether to
\r
715 perform slow start or congestion avoidance on a particular
\r
716 destination transport address. Ssthresh is in number of bytes.
\r
718 o Stream: A uni-directional logical channel established from one to
\r
719 another associated SCTP endpoint, within which all user messages
\r
720 are delivered in sequence except for those submitted to the
\r
721 unordered delivery service.
\r
723 Note: The relationship between stream numbers in opposite directions
\r
724 is strictly a matter of how the applications use them. It is the
\r
725 responsibility of the SCTP user to create and manage these
\r
726 correlations if they are so desired.
\r
730 Stewart, et al. Standards Track [Page 13]
\r
732 RFC 2960 Stream Control Transmission Protocol October 2000
\r
735 o Stream Sequence Number: A 16-bit sequence number used internally
\r
736 by SCTP to assure sequenced delivery of the user messages within a
\r
737 given stream. One stream sequence number is attached to each user
\r
740 o Tie-Tags: Verification Tags from a previous association. These
\r
741 Tags are used within a State Cookie so that the newly restarting
\r
742 association can be linked to the original association within the
\r
743 endpoint that did not restart.
\r
745 o Transmission Control Block (TCB): An internal data structure
\r
746 created by an SCTP endpoint for each of its existing SCTP
\r
747 associations to other SCTP endpoints. TCB contains all the status
\r
748 and operational information for the endpoint to maintain and
\r
749 manage the corresponding association.
\r
751 o Transmission Sequence Number (TSN): A 32-bit sequence number used
\r
752 internally by SCTP. One TSN is attached to each chunk containing
\r
753 user data to permit the receiving SCTP endpoint to acknowledge its
\r
754 receipt and detect duplicate deliveries.
\r
756 o Transport address: A Transport Address is traditionally defined
\r
757 by Network Layer address, Transport Layer protocol and Transport
\r
758 Layer port number. In the case of SCTP running over IP, a
\r
759 transport address is defined by the combination of an IP address
\r
760 and an SCTP port number (where SCTP is the Transport protocol).
\r
762 o Unacknowledged TSN (at an SCTP endpoint): A TSN (and the associated
\r
763 DATA chunk) which has been received by the endpoint but for which
\r
764 an acknowledgement has not yet been sent. Or in the opposite case,
\r
765 for a packet that has been sent but no acknowledgement has been
\r
768 o Unordered Message: Unordered messages are "unordered" with respect
\r
769 to any other message, this includes both other unordered messages
\r
770 as well as other ordered messages. Unordered message might be
\r
771 delivered prior to or later than ordered messages sent on the same
\r
774 o User message: The unit of data delivery across the interface
\r
775 between SCTP and its user.
\r
777 o Verification Tag: A 32 bit unsigned integer that is randomly
\r
778 generated. The Verification Tag provides a key that allows a
\r
779 receiver to verify that the SCTP packet belongs to the current
\r
780 association and is not an old or stale packet from a previous
\r
786 Stewart, et al. Standards Track [Page 14]
\r
788 RFC 2960 Stream Control Transmission Protocol October 2000
\r
793 MAC - Message Authentication Code [RFC2104]
\r
795 RTO - Retransmission Time-out
\r
797 RTT - Round-trip Time
\r
799 RTTVAR - Round-trip Time Variation
\r
801 SCTP - Stream Control Transmission Protocol
\r
803 SRTT - Smoothed RTT
\r
805 TCB - Transmission Control Block
\r
807 TLV - Type-Length-Value Coding Format
\r
809 TSN - Transmission Sequence Number
\r
811 ULP - Upper-layer Protocol
\r
813 1.6 Serial Number Arithmetic
\r
815 It is essential to remember that the actual Transmission Sequence
\r
816 Number space is finite, though very large. This space ranges from 0
\r
817 to 2**32 - 1. Since the space is finite, all arithmetic dealing with
\r
818 Transmission Sequence Numbers must be performed modulo 2**32. This
\r
819 unsigned arithmetic preserves the relationship of sequence numbers as
\r
820 they cycle from 2**32 - 1 to 0 again. There are some subtleties to
\r
821 computer modulo arithmetic, so great care should be taken in
\r
822 programming the comparison of such values. When referring to TSNs,
\r
823 the symbol "=<" means "less than or equal"(modulo 2**32).
\r
825 Comparisons and arithmetic on TSNs in this document SHOULD use Serial
\r
826 Number Arithmetic as defined in [RFC1982] where SERIAL_BITS = 32.
\r
828 An endpoint SHOULD NOT transmit a DATA chunk with a TSN that is more
\r
829 than 2**31 - 1 above the beginning TSN of its current send window.
\r
830 Doing so will cause problems in comparing TSNs.
\r
832 Transmission Sequence Numbers wrap around when they reach 2**32 - 1.
\r
833 That is, the next TSN a DATA chunk MUST use after transmitting TSN =
\r
834 2*32 - 1 is TSN = 0.
\r
836 Any arithmetic done on Stream Sequence Numbers SHOULD use Serial
\r
837 Number Arithmetic as defined in [RFC1982] where SERIAL_BITS = 16.
\r
842 Stewart, et al. Standards Track [Page 15]
\r
844 RFC 2960 Stream Control Transmission Protocol October 2000
\r
847 All other arithmetic and comparisons in this document uses normal
\r
852 The keywords MUST, MUST NOT, REQUIRED, SHALL, SHALL NOT, SHOULD,
\r
853 SHOULD NOT, RECOMMENDED, NOT RECOMMENDED, MAY, and OPTIONAL, when
\r
854 they appear in this document, are to be interpreted as described in
\r
857 3. SCTP packet Format
\r
859 An SCTP packet is composed of a common header and chunks. A chunk
\r
860 contains either control information or user data.
\r
862 The SCTP packet format is shown below:
\r
865 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
\r
866 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
868 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
870 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
872 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
874 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
876 Multiple chunks can be bundled into one SCTP packet up to the MTU
\r
877 size, except for the INIT, INIT ACK, and SHUTDOWN COMPLETE chunks.
\r
878 These chunks MUST NOT be bundled with any other chunk in a packet.
\r
879 See Section 6.10 for more details on chunk bundling.
\r
881 If a user data message doesn't fit into one SCTP packet it can be
\r
882 fragmented into multiple chunks using the procedure defined in
\r
885 All integer fields in an SCTP packet MUST be transmitted in network
\r
886 byte order, unless otherwise stated.
\r
898 Stewart, et al. Standards Track [Page 16]
\r
900 RFC 2960 Stream Control Transmission Protocol October 2000
\r
903 3.1 SCTP Common Header Field Descriptions
\r
905 SCTP Common Header Format
\r
908 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
\r
909 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
910 | Source Port Number | Destination Port Number |
\r
911 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
912 | Verification Tag |
\r
913 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
915 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
917 Source Port Number: 16 bits (unsigned integer)
\r
919 This is the SCTP sender's port number. It can be used by the
\r
920 receiver in combination with the source IP address, the SCTP
\r
921 destination port and possibly the destination IP address to
\r
922 identify the association to which this packet belongs.
\r
924 Destination Port Number: 16 bits (unsigned integer)
\r
926 This is the SCTP port number to which this packet is destined.
\r
927 The receiving host will use this port number to de-multiplex the
\r
928 SCTP packet to the correct receiving endpoint/application.
\r
930 Verification Tag: 32 bits (unsigned integer)
\r
932 The receiver of this packet uses the Verification Tag to validate
\r
933 the sender of this SCTP packet. On transmit, the value of this
\r
934 Verification Tag MUST be set to the value of the Initiate Tag
\r
935 received from the peer endpoint during the association
\r
936 initialization, with the following exceptions:
\r
938 - A packet containing an INIT chunk MUST have a zero Verification
\r
940 - A packet containing a SHUTDOWN-COMPLETE chunk with the T-bit
\r
941 set MUST have the Verification Tag copied from the packet with
\r
942 the SHUTDOWN-ACK chunk.
\r
943 - A packet containing an ABORT chunk may have the verification
\r
944 tag copied from the packet which caused the ABORT to be sent.
\r
945 For details see Section 8.4 and 8.5.
\r
947 An INIT chunk MUST be the only chunk in the SCTP packet carrying it.
\r
954 Stewart, et al. Standards Track [Page 17]
\r
956 RFC 2960 Stream Control Transmission Protocol October 2000
\r
959 Checksum: 32 bits (unsigned integer)
\r
961 This field contains the checksum of this SCTP packet. Its
\r
962 calculation is discussed in Section 6.8. SCTP uses the Adler-
\r
963 32 algorithm as described in Appendix B for calculating the
\r
966 3.2 Chunk Field Descriptions
\r
968 The figure below illustrates the field format for the chunks to be
\r
969 transmitted in the SCTP packet. Each chunk is formatted with a Chunk
\r
970 Type field, a chunk-specific Flag field, a Chunk Length field, and a
\r
974 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
\r
975 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
976 | Chunk Type | Chunk Flags | Chunk Length |
\r
977 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
981 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
983 Chunk Type: 8 bits (unsigned integer)
\r
985 This field identifies the type of information contained in the
\r
986 Chunk Value field. It takes a value from 0 to 254. The value of
\r
987 255 is reserved for future use as an extension field.
\r
989 The values of Chunk Types are defined as follows:
\r
991 ID Value Chunk Type
\r
993 0 - Payload Data (DATA)
\r
994 1 - Initiation (INIT)
\r
995 2 - Initiation Acknowledgement (INIT ACK)
\r
996 3 - Selective Acknowledgement (SACK)
\r
997 4 - Heartbeat Request (HEARTBEAT)
\r
998 5 - Heartbeat Acknowledgement (HEARTBEAT ACK)
\r
1000 7 - Shutdown (SHUTDOWN)
\r
1001 8 - Shutdown Acknowledgement (SHUTDOWN ACK)
\r
1002 9 - Operation Error (ERROR)
\r
1003 10 - State Cookie (COOKIE ECHO)
\r
1004 11 - Cookie Acknowledgement (COOKIE ACK)
\r
1005 12 - Reserved for Explicit Congestion Notification Echo (ECNE)
\r
1006 13 - Reserved for Congestion Window Reduced (CWR)
\r
1010 Stewart, et al. Standards Track [Page 18]
\r
1012 RFC 2960 Stream Control Transmission Protocol October 2000
\r
1015 14 - Shutdown Complete (SHUTDOWN COMPLETE)
\r
1016 15 to 62 - reserved by IETF
\r
1017 63 - IETF-defined Chunk Extensions
\r
1018 64 to 126 - reserved by IETF
\r
1019 127 - IETF-defined Chunk Extensions
\r
1020 128 to 190 - reserved by IETF
\r
1021 191 - IETF-defined Chunk Extensions
\r
1022 192 to 254 - reserved by IETF
\r
1023 255 - IETF-defined Chunk Extensions
\r
1025 Chunk Types are encoded such that the highest-order two bits specify
\r
1026 the action that must be taken if the processing endpoint does not
\r
1027 recognize the Chunk Type.
\r
1029 00 - Stop processing this SCTP packet and discard it, do not process
\r
1030 any further chunks within it.
\r
1032 01 - Stop processing this SCTP packet and discard it, do not process
\r
1033 any further chunks within it, and report the unrecognized
\r
1034 parameter in an 'Unrecognized Parameter Type' (in either an
\r
1035 ERROR or in the INIT ACK).
\r
1037 10 - Skip this chunk and continue processing.
\r
1039 11 - Skip this chunk and continue processing, but report in an ERROR
\r
1040 Chunk using the 'Unrecognized Chunk Type' cause of error.
\r
1042 Note: The ECNE and CWR chunk types are reserved for future use of
\r
1043 Explicit Congestion Notification (ECN).
\r
1045 Chunk Flags: 8 bits
\r
1047 The usage of these bits depends on the chunk type as given by the
\r
1048 Chunk Type. Unless otherwise specified, they are set to zero on
\r
1049 transmit and are ignored on receipt.
\r
1051 Chunk Length: 16 bits (unsigned integer)
\r
1053 This value represents the size of the chunk in bytes including the
\r
1054 Chunk Type, Chunk Flags, Chunk Length, and Chunk Value fields.
\r
1055 Therefore, if the Chunk Value field is zero-length, the Length
\r
1056 field will be set to 4. The Chunk Length field does not count any
\r
1066 Stewart, et al. Standards Track [Page 19]
\r
1068 RFC 2960 Stream Control Transmission Protocol October 2000
\r
1071 Chunk Value: variable length
\r
1073 The Chunk Value field contains the actual information to be
\r
1074 transferred in the chunk. The usage and format of this field is
\r
1075 dependent on the Chunk Type.
\r
1077 The total length of a chunk (including Type, Length and Value fields)
\r
1078 MUST be a multiple of 4 bytes. If the length of the chunk is not a
\r
1079 multiple of 4 bytes, the sender MUST pad the chunk with all zero
\r
1080 bytes and this padding is not included in the chunk length field.
\r
1081 The sender should never pad with more than 3 bytes. The receiver
\r
1082 MUST ignore the padding bytes.
\r
1084 SCTP defined chunks are described in detail in Section 3.3. The
\r
1085 guidelines for IETF-defined chunk extensions can be found in Section
\r
1086 13.1 of this document.
\r
1088 3.2.1 Optional/Variable-length Parameter Format
\r
1090 Chunk values of SCTP control chunks consist of a chunk-type-specific
\r
1091 header of required fields, followed by zero or more parameters. The
\r
1092 optional and variable-length parameters contained in a chunk are
\r
1093 defined in a Type-Length-Value format as shown below.
\r
1096 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
\r
1097 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1098 | Parameter Type | Parameter Length |
\r
1099 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1101 / Parameter Value /
\r
1103 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1105 Chunk Parameter Type: 16 bits (unsigned integer)
\r
1107 The Type field is a 16 bit identifier of the type of parameter.
\r
1108 It takes a value of 0 to 65534.
\r
1110 The value of 65535 is reserved for IETF-defined extensions. Values
\r
1111 other than those defined in specific SCTP chunk description are
\r
1112 reserved for use by IETF.
\r
1122 Stewart, et al. Standards Track [Page 20]
\r
1124 RFC 2960 Stream Control Transmission Protocol October 2000
\r
1127 Chunk Parameter Length: 16 bits (unsigned integer)
\r
1129 The Parameter Length field contains the size of the parameter in
\r
1130 bytes, including the Parameter Type, Parameter Length, and
\r
1131 Parameter Value fields. Thus, a parameter with a zero-length
\r
1132 Parameter Value field would have a Length field of 4. The
\r
1133 Parameter Length does not include any padding bytes.
\r
1135 Chunk Parameter Value: variable-length.
\r
1137 The Parameter Value field contains the actual information to be
\r
1138 transferred in the parameter.
\r
1140 The total length of a parameter (including Type, Parameter Length and
\r
1141 Value fields) MUST be a multiple of 4 bytes. If the length of the
\r
1142 parameter is not a multiple of 4 bytes, the sender pads the Parameter
\r
1143 at the end (i.e., after the Parameter Value field) with all zero
\r
1144 bytes. The length of the padding is not included in the parameter
\r
1145 length field. A sender SHOULD NOT pad with more than 3 bytes. The
\r
1146 receiver MUST ignore the padding bytes.
\r
1148 The Parameter Types are encoded such that the highest-order two bits
\r
1149 specify the action that must be taken if the processing endpoint does
\r
1150 not recognize the Parameter Type.
\r
1152 00 - Stop processing this SCTP packet and discard it, do not process
\r
1153 any further chunks within it.
\r
1155 01 - Stop processing this SCTP packet and discard it, do not process
\r
1156 any further chunks within it, and report the unrecognized
\r
1157 parameter in an 'Unrecognized Parameter Type' (in either an
\r
1158 ERROR or in the INIT ACK).
\r
1160 10 - Skip this parameter and continue processing.
\r
1162 11 - Skip this parameter and continue processing but report the
\r
1163 unrecognized parameter in an 'Unrecognized Parameter Type' (in
\r
1164 either an ERROR or in the INIT ACK).
\r
1166 The actual SCTP parameters are defined in the specific SCTP chunk
\r
1167 sections. The rules for IETF-defined parameter extensions are
\r
1168 defined in Section 13.2.
\r
1170 3.3 SCTP Chunk Definitions
\r
1172 This section defines the format of the different SCTP chunk types.
\r
1178 Stewart, et al. Standards Track [Page 21]
\r
1180 RFC 2960 Stream Control Transmission Protocol October 2000
\r
1183 3.3.1 Payload Data (DATA) (0)
\r
1185 The following format MUST be used for the DATA chunk:
\r
1188 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
\r
1189 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1190 | Type = 0 | Reserved|U|B|E| Length |
\r
1191 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1193 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1194 | Stream Identifier S | Stream Sequence Number n |
\r
1195 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1196 | Payload Protocol Identifier |
\r
1197 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1199 / User Data (seq n of Stream S) /
\r
1201 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1205 Should be set to all '0's and ignored by the receiver.
\r
1209 The (U)nordered bit, if set to '1', indicates that this is an
\r
1210 unordered DATA chunk, and there is no Stream Sequence Number
\r
1211 assigned to this DATA chunk. Therefore, the receiver MUST ignore
\r
1212 the Stream Sequence Number field.
\r
1214 After re-assembly (if necessary), unordered DATA chunks MUST be
\r
1215 dispatched to the upper layer by the receiver without any attempt
\r
1218 If an unordered user message is fragmented, each fragment of the
\r
1219 message MUST have its U bit set to '1'.
\r
1223 The (B)eginning fragment bit, if set, indicates the first fragment
\r
1224 of a user message.
\r
1228 The (E)nding fragment bit, if set, indicates the last fragment of
\r
1234 Stewart, et al. Standards Track [Page 22]
\r
1236 RFC 2960 Stream Control Transmission Protocol October 2000
\r
1239 An unfragmented user message shall have both the B and E bits set to
\r
1240 '1'. Setting both B and E bits to '0' indicates a middle fragment of
\r
1241 a multi-fragment user message, as summarized in the following table:
\r
1244 ============================================================
\r
1245 | 1 0 | First piece of a fragmented user message |
\r
1246 +----------------------------------------------------------+
\r
1247 | 0 0 | Middle piece of a fragmented user message |
\r
1248 +----------------------------------------------------------+
\r
1249 | 0 1 | Last piece of a fragmented user message |
\r
1250 +----------------------------------------------------------+
\r
1251 | 1 1 | Unfragmented Message |
\r
1252 ============================================================
\r
1253 | Table 1: Fragment Description Flags |
\r
1254 ============================================================
\r
1256 When a user message is fragmented into multiple chunks, the TSNs are
\r
1257 used by the receiver to reassemble the message. This means that the
\r
1258 TSNs for each fragment of a fragmented user message MUST be strictly
\r
1261 Length: 16 bits (unsigned integer)
\r
1263 This field indicates the length of the DATA chunk in bytes from
\r
1264 the beginning of the type field to the end of the user data field
\r
1265 excluding any padding. A DATA chunk with no user data field will
\r
1266 have Length set to 16 (indicating 16 bytes).
\r
1268 TSN : 32 bits (unsigned integer)
\r
1270 This value represents the TSN for this DATA chunk. The valid
\r
1271 range of TSN is from 0 to 4294967295 (2**32 - 1). TSN wraps back
\r
1272 to 0 after reaching 4294967295.
\r
1274 Stream Identifier S: 16 bits (unsigned integer)
\r
1276 Identifies the stream to which the following user data belongs.
\r
1278 Stream Sequence Number n: 16 bits (unsigned integer)
\r
1280 This value represents the stream sequence number of the following
\r
1281 user data within the stream S. Valid range is 0 to 65535.
\r
1283 When a user message is fragmented by SCTP for transport, the same
\r
1284 stream sequence number MUST be carried in each of the fragments of
\r
1290 Stewart, et al. Standards Track [Page 23]
\r
1292 RFC 2960 Stream Control Transmission Protocol October 2000
\r
1295 Payload Protocol Identifier: 32 bits (unsigned integer)
\r
1297 This value represents an application (or upper layer) specified
\r
1298 protocol identifier. This value is passed to SCTP by its upper
\r
1299 layer and sent to its peer. This identifier is not used by SCTP
\r
1300 but can be used by certain network entities as well as the peer
\r
1301 application to identify the type of information being carried in
\r
1302 this DATA chunk. This field must be sent even in fragmented DATA
\r
1303 chunks (to make sure it is available for agents in the middle of
\r
1306 The value 0 indicates no application identifier is specified by
\r
1307 the upper layer for this payload data.
\r
1309 User Data: variable length
\r
1311 This is the payload user data. The implementation MUST pad the
\r
1312 end of the data to a 4 byte boundary with all-zero bytes. Any
\r
1313 padding MUST NOT be included in the length field. A sender MUST
\r
1314 never add more than 3 bytes of padding.
\r
1316 3.3.2 Initiation (INIT) (1)
\r
1318 This chunk is used to initiate a SCTP association between two
\r
1319 endpoints. The format of the INIT chunk is shown below:
\r
1322 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
\r
1323 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1324 | Type = 1 | Chunk Flags | Chunk Length |
\r
1325 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1327 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1328 | Advertised Receiver Window Credit (a_rwnd) |
\r
1329 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1330 | Number of Outbound Streams | Number of Inbound Streams |
\r
1331 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1333 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1335 / Optional/Variable-Length Parameters /
\r
1337 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1339 The INIT chunk contains the following parameters. Unless otherwise
\r
1340 noted, each parameter MUST only be included once in the INIT chunk.
\r
1346 Stewart, et al. Standards Track [Page 24]
\r
1348 RFC 2960 Stream Control Transmission Protocol October 2000
\r
1351 Fixed Parameters Status
\r
1352 ----------------------------------------------
\r
1353 Initiate Tag Mandatory
\r
1354 Advertised Receiver Window Credit Mandatory
\r
1355 Number of Outbound Streams Mandatory
\r
1356 Number of Inbound Streams Mandatory
\r
1357 Initial TSN Mandatory
\r
1359 Variable Parameters Status Type Value
\r
1360 -------------------------------------------------------------
\r
1361 IPv4 Address (Note 1) Optional 5
\r
1362 IPv6 Address (Note 1) Optional 6
\r
1363 Cookie Preservative Optional 9
\r
1364 Reserved for ECN Capable (Note 2) Optional 32768 (0x8000)
\r
1365 Host Name Address (Note 3) Optional 11
\r
1366 Supported Address Types (Note 4) Optional 12
\r
1368 Note 1: The INIT chunks can contain multiple addresses that can be
\r
1369 IPv4 and/or IPv6 in any combination.
\r
1371 Note 2: The ECN capable field is reserved for future use of Explicit
\r
1372 Congestion Notification.
\r
1374 Note 3: An INIT chunk MUST NOT contain more than one Host Name
\r
1375 address parameter. Moreover, the sender of the INIT MUST NOT combine
\r
1376 any other address types with the Host Name address in the INIT. The
\r
1377 receiver of INIT MUST ignore any other address types if the Host Name
\r
1378 address parameter is present in the received INIT chunk.
\r
1380 Note 4: This parameter, when present, specifies all the address types
\r
1381 the sending endpoint can support. The absence of this parameter
\r
1382 indicates that the sending endpoint can support any address type.
\r
1384 The Chunk Flags field in INIT is reserved and all bits in it should
\r
1385 be set to 0 by the sender and ignored by the receiver. The sequence
\r
1386 of parameters within an INIT can be processed in any order.
\r
1388 Initiate Tag: 32 bits (unsigned integer)
\r
1390 The receiver of the INIT (the responding end) records the value of
\r
1391 the Initiate Tag parameter. This value MUST be placed into the
\r
1392 Verification Tag field of every SCTP packet that the receiver of
\r
1393 the INIT transmits within this association.
\r
1395 The Initiate Tag is allowed to have any value except 0. See
\r
1396 Section 5.3.1 for more on the selection of the tag value.
\r
1402 Stewart, et al. Standards Track [Page 25]
\r
1404 RFC 2960 Stream Control Transmission Protocol October 2000
\r
1407 If the value of the Initiate Tag in a received INIT chunk is found
\r
1408 to be 0, the receiver MUST treat it as an error and close the
\r
1409 association by transmitting an ABORT.
\r
1411 Advertised Receiver Window Credit (a_rwnd): 32 bits (unsigned
\r
1414 This value represents the dedicated buffer space, in number of
\r
1415 bytes, the sender of the INIT has reserved in association with
\r
1416 this window. During the life of the association this buffer space
\r
1417 SHOULD not be lessened (i.e. dedicated buffers taken away from
\r
1418 this association); however, an endpoint MAY change the value of
\r
1419 a_rwnd it sends in SACK chunks.
\r
1421 Number of Outbound Streams (OS): 16 bits (unsigned integer)
\r
1423 Defines the number of outbound streams the sender of this INIT
\r
1424 chunk wishes to create in this association. The value of 0 MUST
\r
1427 Note: A receiver of an INIT with the OS value set to 0 SHOULD
\r
1428 abort the association.
\r
1430 Number of Inbound Streams (MIS) : 16 bits (unsigned integer)
\r
1432 Defines the maximum number of streams the sender of this INIT
\r
1433 chunk allows the peer end to create in this association. The
\r
1434 value 0 MUST NOT be used.
\r
1436 Note: There is no negotiation of the actual number of streams but
\r
1437 instead the two endpoints will use the min(requested, offered).
\r
1438 See Section 5.1.1 for details.
\r
1440 Note: A receiver of an INIT with the MIS value of 0 SHOULD abort
\r
1443 Initial TSN (I-TSN) : 32 bits (unsigned integer)
\r
1445 Defines the initial TSN that the sender will use. The valid range
\r
1446 is from 0 to 4294967295. This field MAY be set to the value of
\r
1447 the Initiate Tag field.
\r
1449 3.3.2.1 Optional/Variable Length Parameters in INIT
\r
1451 The following parameters follow the Type-Length-Value format as
\r
1452 defined in Section 3.2.1. Any Type-Length-Value fields MUST come
\r
1453 after the fixed-length fields defined in the previous section.
\r
1458 Stewart, et al. Standards Track [Page 26]
\r
1460 RFC 2960 Stream Control Transmission Protocol October 2000
\r
1463 IPv4 Address Parameter (5)
\r
1466 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
\r
1467 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1468 | Type = 5 | Length = 8 |
\r
1469 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1471 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1474 IPv4 Address: 32 bits (unsigned integer)
\r
1476 Contains an IPv4 address of the sending endpoint. It is binary
\r
1479 IPv6 Address Parameter (6)
\r
1482 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
\r
1483 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1484 | Type = 6 | Length = 20 |
\r
1485 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1490 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1492 IPv6 Address: 128 bit (unsigned integer)
\r
1494 Contains an IPv6 address of the sending endpoint. It is binary
\r
1497 Note: A sender MUST NOT use an IPv4-mapped IPv6 address [RFC2373]
\r
1498 but should instead use an IPv4 Address Parameter for an IPv4
\r
1501 Combined with the Source Port Number in the SCTP common header,
\r
1502 the value passed in an IPv4 or IPv6 Address parameter indicates a
\r
1503 transport address the sender of the INIT will support for the
\r
1504 association being initiated. That is, during the lifetime of this
\r
1505 association, this IP address can appear in the source address
\r
1506 field of an IP datagram sent from the sender of the INIT, and can
\r
1507 be used as a destination address of an IP datagram sent from the
\r
1508 receiver of the INIT.
\r
1514 Stewart, et al. Standards Track [Page 27]
\r
1516 RFC 2960 Stream Control Transmission Protocol October 2000
\r
1519 More than one IP Address parameter can be included in an INIT
\r
1520 chunk when the INIT sender is multi-homed. Moreover, a multi-
\r
1521 homed endpoint may have access to different types of network, thus
\r
1522 more than one address type can be present in one INIT chunk, i.e.,
\r
1523 IPv4 and IPv6 addresses are allowed in the same INIT chunk.
\r
1525 If the INIT contains at least one IP Address parameter, then the
\r
1526 source address of the IP datagram containing the INIT chunk and
\r
1527 any additional address(es) provided within the INIT can be used as
\r
1528 destinations by the endpoint receiving the INIT. If the INIT does
\r
1529 not contain any IP Address parameters, the endpoint receiving the
\r
1530 INIT MUST use the source address associated with the received IP
\r
1531 datagram as its sole destination address for the association.
\r
1533 Note that not using any IP address parameters in the INIT and
\r
1534 INIT-ACK is an alternative to make an association more likely to
\r
1535 work across a NAT box.
\r
1537 Cookie Preservative (9)
\r
1539 The sender of the INIT shall use this parameter to suggest to the
\r
1540 receiver of the INIT for a longer life-span of the State Cookie.
\r
1543 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
\r
1544 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1545 | Type = 9 | Length = 8 |
\r
1546 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1547 | Suggested Cookie Life-span Increment (msec.) |
\r
1548 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1550 Suggested Cookie Life-span Increment: 32 bits (unsigned integer)
\r
1552 This parameter indicates to the receiver how much increment in
\r
1553 milliseconds the sender wishes the receiver to add to its default
\r
1556 This optional parameter should be added to the INIT chunk by the
\r
1557 sender when it re-attempts establishing an association with a peer
\r
1558 to which its previous attempt of establishing the association failed
\r
1559 due to a stale cookie operation error. The receiver MAY choose to
\r
1560 ignore the suggested cookie life-span increase for its own security
\r
1570 Stewart, et al. Standards Track [Page 28]
\r
1572 RFC 2960 Stream Control Transmission Protocol October 2000
\r
1575 Host Name Address (11)
\r
1577 The sender of INIT uses this parameter to pass its Host Name (in
\r
1578 place of its IP addresses) to its peer. The peer is responsible
\r
1579 for resolving the name. Using this parameter might make it more
\r
1580 likely for the association to work across a NAT box.
\r
1583 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
\r
1584 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1585 | Type = 11 | Length |
\r
1586 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1589 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1591 Host Name: variable length
\r
1593 This field contains a host name in "host name syntax" per RFC1123
\r
1594 Section 2.1 [RFC1123]. The method for resolving the host name is
\r
1595 out of scope of SCTP.
\r
1597 Note: At least one null terminator is included in the Host Name
\r
1598 string and must be included in the length.
\r
1600 Supported Address Types (12)
\r
1602 The sender of INIT uses this parameter to list all the address
\r
1603 types it can support.
\r
1606 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
\r
1607 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1608 | Type = 12 | Length |
\r
1609 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1610 | Address Type #1 | Address Type #2 |
\r
1611 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1613 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1615 Address Type: 16 bits (unsigned integer)
\r
1617 This is filled with the type value of the corresponding address
\r
1618 TLV (e.g., IPv4 = 5, IPv6 = 6, Hostname = 11).
\r
1626 Stewart, et al. Standards Track [Page 29]
\r
1628 RFC 2960 Stream Control Transmission Protocol October 2000
\r
1631 3.3.3 Initiation Acknowledgement (INIT ACK) (2):
\r
1633 The INIT ACK chunk is used to acknowledge the initiation of an SCTP
\r
1636 The parameter part of INIT ACK is formatted similarly to the INIT
\r
1637 chunk. It uses two extra variable parameters: The State Cookie and
\r
1638 the Unrecognized Parameter:
\r
1640 The format of the INIT ACK chunk is shown below:
\r
1643 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
\r
1644 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1645 | Type = 2 | Chunk Flags | Chunk Length |
\r
1646 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1648 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1649 | Advertised Receiver Window Credit |
\r
1650 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1651 | Number of Outbound Streams | Number of Inbound Streams |
\r
1652 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1654 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1656 / Optional/Variable-Length Parameters /
\r
1658 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1660 Initiate Tag: 32 bits (unsigned integer)
\r
1662 The receiver of the INIT ACK records the value of the Initiate Tag
\r
1663 parameter. This value MUST be placed into the Verification Tag
\r
1664 field of every SCTP packet that the INIT ACK receiver transmits
\r
1665 within this association.
\r
1667 The Initiate Tag MUST NOT take the value 0. See Section 5.3.1 for
\r
1668 more on the selection of the Initiate Tag value.
\r
1670 If the value of the Initiate Tag in a received INIT ACK chunk is
\r
1671 found to be 0, the receiver MUST treat it as an error and close
\r
1672 the association by transmitting an ABORT.
\r
1682 Stewart, et al. Standards Track [Page 30]
\r
1684 RFC 2960 Stream Control Transmission Protocol October 2000
\r
1687 Advertised Receiver Window Credit (a_rwnd): 32 bits (unsigned
\r
1690 This value represents the dedicated buffer space, in number of
\r
1691 bytes, the sender of the INIT ACK has reserved in association with
\r
1692 this window. During the life of the association this buffer space
\r
1693 SHOULD not be lessened (i.e. dedicated buffers taken away from
\r
1694 this association).
\r
1696 Number of Outbound Streams (OS): 16 bits (unsigned integer)
\r
1698 Defines the number of outbound streams the sender of this INIT ACK
\r
1699 chunk wishes to create in this association. The value of 0 MUST
\r
1702 Note: A receiver of an INIT ACK with the OS value set to 0 SHOULD
\r
1703 destroy the association discarding its TCB.
\r
1705 Number of Inbound Streams (MIS) : 16 bits (unsigned integer)
\r
1707 Defines the maximum number of streams the sender of this INIT ACK
\r
1708 chunk allows the peer end to create in this association. The
\r
1709 value 0 MUST NOT be used.
\r
1711 Note: There is no negotiation of the actual number of streams but
\r
1712 instead the two endpoints will use the min(requested, offered).
\r
1713 See Section 5.1.1 for details.
\r
1715 Note: A receiver of an INIT ACK with the MIS value set to 0
\r
1716 SHOULD destroy the association discarding its TCB.
\r
1718 Initial TSN (I-TSN) : 32 bits (unsigned integer)
\r
1720 Defines the initial TSN that the INIT-ACK sender will use. The
\r
1721 valid range is from 0 to 4294967295. This field MAY be set to the
\r
1722 value of the Initiate Tag field.
\r
1724 Fixed Parameters Status
\r
1725 ----------------------------------------------
\r
1726 Initiate Tag Mandatory
\r
1727 Advertised Receiver Window Credit Mandatory
\r
1728 Number of Outbound Streams Mandatory
\r
1729 Number of Inbound Streams Mandatory
\r
1730 Initial TSN Mandatory
\r
1738 Stewart, et al. Standards Track [Page 31]
\r
1740 RFC 2960 Stream Control Transmission Protocol October 2000
\r
1743 Variable Parameters Status Type Value
\r
1744 -------------------------------------------------------------
\r
1745 State Cookie Mandatory 7
\r
1746 IPv4 Address (Note 1) Optional 5
\r
1747 IPv6 Address (Note 1) Optional 6
\r
1748 Unrecognized Parameters Optional 8
\r
1749 Reserved for ECN Capable (Note 2) Optional 32768 (0x8000)
\r
1750 Host Name Address (Note 3) Optional 11
\r
1752 Note 1: The INIT ACK chunks can contain any number of IP address
\r
1753 parameters that can be IPv4 and/or IPv6 in any combination.
\r
1755 Note 2: The ECN capable field is reserved for future use of Explicit
\r
1756 Congestion Notification.
\r
1758 Note 3: The INIT ACK chunks MUST NOT contain more than one Host Name
\r
1759 address parameter. Moreover, the sender of the INIT ACK MUST NOT
\r
1760 combine any other address types with the Host Name address in the
\r
1761 INIT ACK. The receiver of the INIT ACK MUST ignore any other address
\r
1762 types if the Host Name address parameter is present.
\r
1764 IMPLEMENTATION NOTE: An implementation MUST be prepared to receive a
\r
1765 INIT ACK that is quite large (more than 1500 bytes) due to the
\r
1766 variable size of the state cookie AND the variable address list. For
\r
1767 example if a responder to the INIT has 1000 IPv4 addresses it wishes
\r
1768 to send, it would need at least 8,000 bytes to encode this in the
\r
1771 In combination with the Source Port carried in the SCTP common
\r
1772 header, each IP Address parameter in the INIT ACK indicates to the
\r
1773 receiver of the INIT ACK a valid transport address supported by the
\r
1774 sender of the INIT ACK for the lifetime of the association being
\r
1777 If the INIT ACK contains at least one IP Address parameter, then the
\r
1778 source address of the IP datagram containing the INIT ACK and any
\r
1779 additional address(es) provided within the INIT ACK may be used as
\r
1780 destinations by the receiver of the INIT-ACK. If the INIT ACK does
\r
1781 not contain any IP Address parameters, the receiver of the INIT-ACK
\r
1782 MUST use the source address associated with the received IP datagram
\r
1783 as its sole destination address for the association.
\r
1785 The State Cookie and Unrecognized Parameters use the Type-Length-
\r
1786 Value format as defined in Section 3.2.1 and are described below.
\r
1787 The other fields are defined the same as their counterparts in the
\r
1794 Stewart, et al. Standards Track [Page 32]
\r
1796 RFC 2960 Stream Control Transmission Protocol October 2000
\r
1799 3.3.3.1 Optional or Variable Length Parameters
\r
1803 Parameter Type Value: 7
\r
1805 Parameter Length: variable size, depending on Size of Cookie
\r
1809 This parameter value MUST contain all the necessary state and
\r
1810 parameter information required for the sender of this INIT ACK
\r
1811 to create the association, along with a Message Authentication
\r
1812 Code (MAC). See Section 5.1.3 for details on State Cookie
\r
1815 Unrecognized Parameters:
\r
1817 Parameter Type Value: 8
\r
1819 Parameter Length: Variable Size.
\r
1823 This parameter is returned to the originator of the INIT chunk
\r
1824 when the INIT contains an unrecognized parameter which has a
\r
1825 value that indicates that it should be reported to the sender.
\r
1826 This parameter value field will contain unrecognized parameters
\r
1827 copied from the INIT chunk complete with Parameter Type, Length
\r
1830 3.3.4 Selective Acknowledgement (SACK) (3):
\r
1832 This chunk is sent to the peer endpoint to acknowledge received DATA
\r
1833 chunks and to inform the peer endpoint of gaps in the received
\r
1834 subsequences of DATA chunks as represented by their TSNs.
\r
1836 The SACK MUST contain the Cumulative TSN Ack and Advertised Receiver
\r
1837 Window Credit (a_rwnd) parameters.
\r
1839 By definition, the value of the Cumulative TSN Ack parameter is the
\r
1840 last TSN received before a break in the sequence of received TSNs
\r
1841 occurs; the next TSN value following this one has not yet been
\r
1842 received at the endpoint sending the SACK. This parameter therefore
\r
1843 acknowledges receipt of all TSNs less than or equal to its value.
\r
1845 The handling of a_rwnd by the receiver of the SACK is discussed in
\r
1846 detail in Section 6.2.1.
\r
1850 Stewart, et al. Standards Track [Page 33]
\r
1852 RFC 2960 Stream Control Transmission Protocol October 2000
\r
1855 The SACK also contains zero or more Gap Ack Blocks. Each Gap Ack
\r
1856 Block acknowledges a subsequence of TSNs received following a break
\r
1857 in the sequence of received TSNs. By definition, all TSNs
\r
1858 acknowledged by Gap Ack Blocks are greater than the value of the
\r
1859 Cumulative TSN Ack.
\r
1862 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
\r
1863 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1864 | Type = 3 |Chunk Flags | Chunk Length |
\r
1865 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1866 | Cumulative TSN Ack |
\r
1867 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1868 | Advertised Receiver Window Credit (a_rwnd) |
\r
1869 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1870 | Number of Gap Ack Blocks = N | Number of Duplicate TSNs = X |
\r
1871 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1872 | Gap Ack Block #1 Start | Gap Ack Block #1 End |
\r
1873 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1877 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1878 | Gap Ack Block #N Start | Gap Ack Block #N End |
\r
1879 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1880 | Duplicate TSN 1 |
\r
1881 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1885 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1886 | Duplicate TSN X |
\r
1887 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
1889 Chunk Flags: 8 bits
\r
1891 Set to all zeros on transmit and ignored on receipt.
\r
1893 Cumulative TSN Ack: 32 bits (unsigned integer)
\r
1895 This parameter contains the TSN of the last DATA chunk received in
\r
1896 sequence before a gap.
\r
1898 Advertised Receiver Window Credit (a_rwnd): 32 bits (unsigned
\r
1901 This field indicates the updated receive buffer space in bytes of
\r
1902 the sender of this SACK, see Section 6.2.1 for details.
\r
1906 Stewart, et al. Standards Track [Page 34]
\r
1908 RFC 2960 Stream Control Transmission Protocol October 2000
\r
1911 Number of Gap Ack Blocks: 16 bits (unsigned integer)
\r
1913 Indicates the number of Gap Ack Blocks included in this SACK.
\r
1915 Number of Duplicate TSNs: 16 bit
\r
1917 This field contains the number of duplicate TSNs the endpoint has
\r
1918 received. Each duplicate TSN is listed following the Gap Ack
\r
1923 These fields contain the Gap Ack Blocks. They are repeated for
\r
1924 each Gap Ack Block up to the number of Gap Ack Blocks defined in
\r
1925 the Number of Gap Ack Blocks field. All DATA chunks with TSNs
\r
1926 greater than or equal to (Cumulative TSN Ack + Gap Ack Block
\r
1927 Start) and less than or equal to (Cumulative TSN Ack + Gap Ack
\r
1928 Block End) of each Gap Ack Block are assumed to have been received
\r
1931 Gap Ack Block Start: 16 bits (unsigned integer)
\r
1933 Indicates the Start offset TSN for this Gap Ack Block. To
\r
1934 calculate the actual TSN number the Cumulative TSN Ack is added to
\r
1935 this offset number. This calculated TSN identifies the first TSN
\r
1936 in this Gap Ack Block that has been received.
\r
1938 Gap Ack Block End: 16 bits (unsigned integer)
\r
1940 Indicates the End offset TSN for this Gap Ack Block. To calculate
\r
1941 the actual TSN number the Cumulative TSN Ack is added to this
\r
1942 offset number. This calculated TSN identifies the TSN of the last
\r
1943 DATA chunk received in this Gap Ack Block.
\r
1945 For example, assume the receiver has the following DATA chunks newly
\r
1946 arrived at the time when it decides to send a Selective ACK,
\r
1962 Stewart, et al. Standards Track [Page 35]
\r
1964 RFC 2960 Stream Control Transmission Protocol October 2000
\r
1970 | | <- still missing
\r
1976 | | <- still missing
\r
1985 then, the parameter part of the SACK MUST be constructed as follows
\r
1986 (assuming the new a_rwnd is set to 4660 by the sender):
\r
1988 +--------------------------------+
\r
1989 | Cumulative TSN Ack = 12 |
\r
1990 +--------------------------------+
\r
1992 +----------------+---------------+
\r
1993 | num of block=2 | num of dup=0 |
\r
1994 +----------------+---------------+
\r
1995 |block #1 strt=2 |block #1 end=3 |
\r
1996 +----------------+---------------+
\r
1997 |block #2 strt=5 |block #2 end=5 |
\r
1998 +----------------+---------------+
\r
2001 Duplicate TSN: 32 bits (unsigned integer)
\r
2003 Indicates the number of times a TSN was received in duplicate
\r
2004 since the last SACK was sent. Every time a receiver gets a
\r
2005 duplicate TSN (before sending the SACK) it adds it to the list of
\r
2006 duplicates. The duplicate count is re-initialized to zero after
\r
2007 sending each SACK.
\r
2009 For example, if a receiver were to get the TSN 19 three times it
\r
2010 would list 19 twice in the outbound SACK. After sending the SACK
\r
2011 if it received yet one more TSN 19 it would list 19 as a duplicate
\r
2012 once in the next outgoing SACK.
\r
2018 Stewart, et al. Standards Track [Page 36]
\r
2020 RFC 2960 Stream Control Transmission Protocol October 2000
\r
2023 3.3.5 Heartbeat Request (HEARTBEAT) (4):
\r
2025 An endpoint should send this chunk to its peer endpoint to probe the
\r
2026 reachability of a particular destination transport address defined in
\r
2027 the present association.
\r
2029 The parameter field contains the Heartbeat Information which is a
\r
2030 variable length opaque data structure understood only by the sender.
\r
2033 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
\r
2034 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2035 | Type = 4 | Chunk Flags | Heartbeat Length |
\r
2036 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2038 / Heartbeat Information TLV (Variable-Length) /
\r
2040 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2042 Chunk Flags: 8 bits
\r
2044 Set to zero on transmit and ignored on receipt.
\r
2046 Heartbeat Length: 16 bits (unsigned integer)
\r
2048 Set to the size of the chunk in bytes, including the chunk header
\r
2049 and the Heartbeat Information field.
\r
2051 Heartbeat Information: variable length
\r
2053 Defined as a variable-length parameter using the format described
\r
2054 in Section 3.2.1, i.e.:
\r
2056 Variable Parameters Status Type Value
\r
2057 -------------------------------------------------------------
\r
2058 Heartbeat Info Mandatory 1
\r
2061 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
\r
2062 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2063 | Heartbeat Info Type=1 | HB Info Length |
\r
2064 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2065 / Sender-specific Heartbeat Info /
\r
2067 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2074 Stewart, et al. Standards Track [Page 37]
\r
2076 RFC 2960 Stream Control Transmission Protocol October 2000
\r
2079 The Sender-specific Heartbeat Info field should normally include
\r
2080 information about the sender's current time when this HEARTBEAT
\r
2081 chunk is sent and the destination transport address to which this
\r
2082 HEARTBEAT is sent (see Section 8.3).
\r
2084 3.3.6 Heartbeat Acknowledgement (HEARTBEAT ACK) (5):
\r
2086 An endpoint should send this chunk to its peer endpoint as a response
\r
2087 to a HEARTBEAT chunk (see Section 8.3). A HEARTBEAT ACK is always
\r
2088 sent to the source IP address of the IP datagram containing the
\r
2089 HEARTBEAT chunk to which this ack is responding.
\r
2091 The parameter field contains a variable length opaque data structure.
\r
2094 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
\r
2095 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2096 | Type = 5 | Chunk Flags | Heartbeat Ack Length |
\r
2097 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2099 / Heartbeat Information TLV (Variable-Length) /
\r
2101 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2103 Chunk Flags: 8 bits
\r
2105 Set to zero on transmit and ignored on receipt.
\r
2107 Heartbeat Ack Length: 16 bits (unsigned integer)
\r
2109 Set to the size of the chunk in bytes, including the chunk header
\r
2110 and the Heartbeat Information field.
\r
2112 Heartbeat Information: variable length
\r
2114 This field MUST contain the Heartbeat Information parameter of
\r
2115 the Heartbeat Request to which this Heartbeat Acknowledgement is
\r
2118 Variable Parameters Status Type Value
\r
2119 -------------------------------------------------------------
\r
2120 Heartbeat Info Mandatory 1
\r
2130 Stewart, et al. Standards Track [Page 38]
\r
2132 RFC 2960 Stream Control Transmission Protocol October 2000
\r
2135 3.3.7 Abort Association (ABORT) (6):
\r
2137 The ABORT chunk is sent to the peer of an association to close the
\r
2138 association. The ABORT chunk may contain Cause Parameters to inform
\r
2139 the receiver the reason of the abort. DATA chunks MUST NOT be
\r
2140 bundled with ABORT. Control chunks (except for INIT, INIT ACK and
\r
2141 SHUTDOWN COMPLETE) MAY be bundled with an ABORT but they MUST be
\r
2142 placed before the ABORT in the SCTP packet, or they will be ignored
\r
2145 If an endpoint receives an ABORT with a format error or for an
\r
2146 association that doesn't exist, it MUST silently discard it.
\r
2147 Moreover, under any circumstances, an endpoint that receives an ABORT
\r
2148 MUST NOT respond to that ABORT by sending an ABORT of its own.
\r
2151 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
\r
2152 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2153 | Type = 6 |Reserved |T| Length |
\r
2154 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2156 / zero or more Error Causes /
\r
2158 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2160 Chunk Flags: 8 bits
\r
2164 Set to 0 on transmit and ignored on receipt.
\r
2168 The T bit is set to 0 if the sender had a TCB that it destroyed.
\r
2169 If the sender did not have a TCB it should set this bit to 1.
\r
2171 Note: Special rules apply to this chunk for verification, please see
\r
2172 Section 8.5.1 for details.
\r
2174 Length: 16 bits (unsigned integer)
\r
2176 Set to the size of the chunk in bytes, including the chunk header
\r
2177 and all the Error Cause fields present.
\r
2179 See Section 3.3.10 for Error Cause definitions.
\r
2186 Stewart, et al. Standards Track [Page 39]
\r
2188 RFC 2960 Stream Control Transmission Protocol October 2000
\r
2191 3.3.8 Shutdown Association (SHUTDOWN) (7):
\r
2193 An endpoint in an association MUST use this chunk to initiate a
\r
2194 graceful close of the association with its peer. This chunk has the
\r
2198 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
\r
2199 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2200 | Type = 7 | Chunk Flags | Length = 8 |
\r
2201 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2202 | Cumulative TSN Ack |
\r
2203 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2205 Chunk Flags: 8 bits
\r
2207 Set to zero on transmit and ignored on receipt.
\r
2209 Length: 16 bits (unsigned integer)
\r
2211 Indicates the length of the parameter. Set to 8.
\r
2213 Cumulative TSN Ack: 32 bits (unsigned integer)
\r
2215 This parameter contains the TSN of the last chunk received in
\r
2216 sequence before any gaps.
\r
2218 Note: Since the SHUTDOWN message does not contain Gap Ack Blocks,
\r
2219 it cannot be used to acknowledge TSNs received out of order. In a
\r
2220 SACK, lack of Gap Ack Blocks that were previously included
\r
2221 indicates that the data receiver reneged on the associated DATA
\r
2222 chunks. Since SHUTDOWN does not contain Gap Ack Blocks, the
\r
2223 receiver of the SHUTDOWN shouldn't interpret the lack of a Gap Ack
\r
2224 Block as a renege. (see Section 6.2 for information on reneging)
\r
2226 3.3.9 Shutdown Acknowledgement (SHUTDOWN ACK) (8):
\r
2228 This chunk MUST be used to acknowledge the receipt of the SHUTDOWN
\r
2229 chunk at the completion of the shutdown process, see Section 9.2 for
\r
2232 The SHUTDOWN ACK chunk has no parameters.
\r
2235 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
\r
2236 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2237 | Type = 8 |Chunk Flags | Length = 4 |
\r
2238 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2242 Stewart, et al. Standards Track [Page 40]
\r
2244 RFC 2960 Stream Control Transmission Protocol October 2000
\r
2247 Chunk Flags: 8 bits
\r
2249 Set to zero on transmit and ignored on receipt.
\r
2251 3.3.10 Operation Error (ERROR) (9):
\r
2253 An endpoint sends this chunk to its peer endpoint to notify it of
\r
2254 certain error conditions. It contains one or more error causes. An
\r
2255 Operation Error is not considered fatal in and of itself, but may be
\r
2256 used with an ABORT chunk to report a fatal condition. It has the
\r
2257 following parameters:
\r
2260 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
\r
2261 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2262 | Type = 9 | Chunk Flags | Length |
\r
2263 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2265 / one or more Error Causes /
\r
2267 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2269 Chunk Flags: 8 bits
\r
2271 Set to zero on transmit and ignored on receipt.
\r
2273 Length: 16 bits (unsigned integer)
\r
2275 Set to the size of the chunk in bytes, including the chunk header
\r
2276 and all the Error Cause fields present.
\r
2278 Error causes are defined as variable-length parameters using the
\r
2279 format described in 3.2.1, i.e.:
\r
2282 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
\r
2283 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2284 | Cause Code | Cause Length |
\r
2285 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2286 / Cause-specific Information /
\r
2288 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2290 Cause Code: 16 bits (unsigned integer)
\r
2292 Defines the type of error conditions being reported.
\r
2298 Stewart, et al. Standards Track [Page 41]
\r
2300 RFC 2960 Stream Control Transmission Protocol October 2000
\r
2305 --------- ----------------
\r
2306 1 Invalid Stream Identifier
\r
2307 2 Missing Mandatory Parameter
\r
2308 3 Stale Cookie Error
\r
2310 5 Unresolvable Address
\r
2311 6 Unrecognized Chunk Type
\r
2312 7 Invalid Mandatory Parameter
\r
2313 8 Unrecognized Parameters
\r
2315 10 Cookie Received While Shutting Down
\r
2317 Cause Length: 16 bits (unsigned integer)
\r
2319 Set to the size of the parameter in bytes, including the Cause
\r
2320 Code, Cause Length, and Cause-Specific Information fields
\r
2322 Cause-specific Information: variable length
\r
2324 This field carries the details of the error condition.
\r
2326 Sections 3.3.10.1 - 3.3.10.10 define error causes for SCTP.
\r
2327 Guidelines for the IETF to define new error cause values are
\r
2328 discussed in Section 13.3.
\r
2330 3.3.10.1 Invalid Stream Identifier (1)
\r
2334 Invalid Stream Identifier: Indicates endpoint received a DATA chunk
\r
2335 sent to a nonexistent stream.
\r
2337 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2338 | Cause Code=1 | Cause Length=8 |
\r
2339 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2340 | Stream Identifier | (Reserved) |
\r
2341 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2343 Stream Identifier: 16 bits (unsigned integer)
\r
2345 Contains the Stream Identifier of the DATA chunk received in
\r
2354 Stewart, et al. Standards Track [Page 42]
\r
2356 RFC 2960 Stream Control Transmission Protocol October 2000
\r
2361 This field is reserved. It is set to all 0's on transmit and
\r
2362 Ignored on receipt.
\r
2364 3.3.10.2 Missing Mandatory Parameter (2)
\r
2368 Missing Mandatory Parameter: Indicates that one or more mandatory
\r
2369 TLV parameters are missing in a received INIT or INIT ACK.
\r
2371 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2372 | Cause Code=2 | Cause Length=8+N*2 |
\r
2373 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2374 | Number of missing params=N |
\r
2375 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2376 | Missing Param Type #1 | Missing Param Type #2 |
\r
2377 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2378 | Missing Param Type #N-1 | Missing Param Type #N |
\r
2379 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2381 Number of Missing params: 32 bits (unsigned integer)
\r
2383 This field contains the number of parameters contained in the
\r
2384 Cause-specific Information field.
\r
2386 Missing Param Type: 16 bits (unsigned integer)
\r
2388 Each field will contain the missing mandatory parameter number.
\r
2390 3.3.10.3 Stale Cookie Error (3)
\r
2394 Stale Cookie Error: Indicates the receipt of a valid State Cookie
\r
2397 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2398 | Cause Code=3 | Cause Length=8 |
\r
2399 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2400 | Measure of Staleness (usec.) |
\r
2401 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2403 Measure of Staleness: 32 bits (unsigned integer)
\r
2405 This field contains the difference, in microseconds, between the
\r
2406 current time and the time the State Cookie expired.
\r
2410 Stewart, et al. Standards Track [Page 43]
\r
2412 RFC 2960 Stream Control Transmission Protocol October 2000
\r
2415 The sender of this error cause MAY choose to report how long past
\r
2416 expiration the State Cookie is by including a non-zero value in
\r
2417 the Measure of Staleness field. If the sender does not wish to
\r
2418 provide this information it should set the Measure of Staleness
\r
2419 field to the value of zero.
\r
2421 3.3.10.4 Out of Resource (4)
\r
2425 Out of Resource: Indicates that the sender is out of resource. This
\r
2426 is usually sent in combination with or within an ABORT.
\r
2428 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2429 | Cause Code=4 | Cause Length=4 |
\r
2430 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2432 3.3.10.5 Unresolvable Address (5)
\r
2436 Unresolvable Address: Indicates that the sender is not able to
\r
2437 resolve the specified address parameter (e.g., type of address is not
\r
2438 supported by the sender). This is usually sent in combination with
\r
2439 or within an ABORT.
\r
2441 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2442 | Cause Code=5 | Cause Length |
\r
2443 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2444 / Unresolvable Address /
\r
2446 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2448 Unresolvable Address: variable length
\r
2450 The unresolvable address field contains the complete Type, Length
\r
2451 and Value of the address parameter (or Host Name parameter) that
\r
2452 contains the unresolvable address or host name.
\r
2454 3.3.10.6 Unrecognized Chunk Type (6)
\r
2458 Unrecognized Chunk Type: This error cause is returned to the
\r
2459 originator of the chunk if the receiver does not understand the chunk
\r
2460 and the upper bits of the 'Chunk Type' are set to 01 or 11.
\r
2466 Stewart, et al. Standards Track [Page 44]
\r
2468 RFC 2960 Stream Control Transmission Protocol October 2000
\r
2471 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2472 | Cause Code=6 | Cause Length |
\r
2473 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2474 / Unrecognized Chunk /
\r
2476 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2478 Unrecognized Chunk: variable length
\r
2480 The Unrecognized Chunk field contains the unrecognized Chunk from
\r
2481 the SCTP packet complete with Chunk Type, Chunk Flags and Chunk
\r
2484 3.3.10.7 Invalid Mandatory Parameter (7)
\r
2488 Invalid Mandatory Parameter: This error cause is returned to the
\r
2489 originator of an INIT or INIT ACK chunk when one of the mandatory
\r
2490 parameters is set to a invalid value.
\r
2492 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2493 | Cause Code=7 | Cause Length=4 |
\r
2494 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2496 3.3.10.8 Unrecognized Parameters (8)
\r
2500 Unrecognized Parameters: This error cause is returned to the
\r
2501 originator of the INIT ACK chunk if the receiver does not recognize
\r
2502 one or more Optional TLV parameters in the INIT ACK chunk.
\r
2504 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2505 | Cause Code=8 | Cause Length |
\r
2506 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2507 / Unrecognized Parameters /
\r
2509 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2511 Unrecognized Parameters: variable length
\r
2513 The Unrecognized Parameters field contains the unrecognized
\r
2514 parameters copied from the INIT ACK chunk complete with TLV. This
\r
2515 error cause is normally contained in an ERROR chunk bundled with
\r
2516 the COOKIE ECHO chunk when responding to the INIT ACK, when the
\r
2517 sender of the COOKIE ECHO chunk wishes to report unrecognized
\r
2522 Stewart, et al. Standards Track [Page 45]
\r
2524 RFC 2960 Stream Control Transmission Protocol October 2000
\r
2527 3.3.10.9 No User Data (9)
\r
2531 No User Data: This error cause is returned to the originator of a
\r
2532 DATA chunk if a received DATA chunk has no user data.
\r
2534 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2535 | Cause Code=9 | Cause Length=8 |
\r
2536 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2539 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2541 TSN value: 32 bits (+unsigned integer)
\r
2543 The TSN value field contains the TSN of the DATA chunk received
\r
2544 with no user data field.
\r
2546 This cause code is normally returned in an ABORT chunk (see
\r
2549 3.3.10.10 Cookie Received While Shutting Down (10)
\r
2553 Cookie Received While Shutting Down: A COOKIE ECHO was received
\r
2554 While the endpoint was in SHUTDOWN-ACK-SENT state. This error is
\r
2555 usually returned in an ERROR chunk bundled with the retransmitted
\r
2558 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2559 | Cause Code=10 | Cause Length=4 |
\r
2560 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2562 3.3.11 Cookie Echo (COOKIE ECHO) (10):
\r
2564 This chunk is used only during the initialization of an association.
\r
2565 It is sent by the initiator of an association to its peer to complete
\r
2566 the initialization process. This chunk MUST precede any DATA chunk
\r
2567 sent within the association, but MAY be bundled with one or more DATA
\r
2568 chunks in the same packet.
\r
2578 Stewart, et al. Standards Track [Page 46]
\r
2580 RFC 2960 Stream Control Transmission Protocol October 2000
\r
2584 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
\r
2585 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2586 | Type = 10 |Chunk Flags | Length |
\r
2587 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2590 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2592 Chunk Flags: 8 bit
\r
2594 Set to zero on transmit and ignored on receipt.
\r
2596 Length: 16 bits (unsigned integer)
\r
2598 Set to the size of the chunk in bytes, including the 4 bytes of
\r
2599 the chunk header and the size of the Cookie.
\r
2601 Cookie: variable size
\r
2603 This field must contain the exact cookie received in the State
\r
2604 Cookie parameter from the previous INIT ACK.
\r
2606 An implementation SHOULD make the cookie as small as possible to
\r
2607 insure interoperability.
\r
2609 3.3.12 Cookie Acknowledgement (COOKIE ACK) (11):
\r
2611 This chunk is used only during the initialization of an association.
\r
2612 It is used to acknowledge the receipt of a COOKIE ECHO chunk. This
\r
2613 chunk MUST precede any DATA or SACK chunk sent within the
\r
2614 association, but MAY be bundled with one or more DATA chunks or SACK
\r
2615 chunk in the same SCTP packet.
\r
2618 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
\r
2619 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2620 | Type = 11 |Chunk Flags | Length = 4 |
\r
2621 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2623 Chunk Flags: 8 bits
\r
2625 Set to zero on transmit and ignored on receipt.
\r
2634 Stewart, et al. Standards Track [Page 47]
\r
2636 RFC 2960 Stream Control Transmission Protocol October 2000
\r
2639 3.3.13 Shutdown Complete (SHUTDOWN COMPLETE) (14):
\r
2641 This chunk MUST be used to acknowledge the receipt of the SHUTDOWN
\r
2642 ACK chunk at the completion of the shutdown process, see Section 9.2
\r
2645 The SHUTDOWN COMPLETE chunk has no parameters.
\r
2648 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
\r
2649 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2650 | Type = 14 |Reserved |T| Length = 4 |
\r
2651 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
2653 Chunk Flags: 8 bits
\r
2657 Set to 0 on transmit and ignored on receipt.
\r
2661 The T bit is set to 0 if the sender had a TCB that it destroyed.
\r
2662 If the sender did not have a TCB it should set this bit to 1.
\r
2664 Note: Special rules apply to this chunk for verification, please see
\r
2665 Section 8.5.1 for details.
\r
2667 4. SCTP Association State Diagram
\r
2669 During the lifetime of an SCTP association, the SCTP endpoint's
\r
2670 association progress from one state to another in response to various
\r
2671 events. The events that may potentially advance an association's
\r
2674 o SCTP user primitive calls, e.g., [ASSOCIATE], [SHUTDOWN], [ABORT],
\r
2676 o Reception of INIT, COOKIE ECHO, ABORT, SHUTDOWN, etc., control
\r
2679 o Some timeout events.
\r
2681 The state diagram in the figures below illustrates state changes,
\r
2682 together with the causing events and resulting actions. Note that
\r
2683 some of the error conditions are not shown in the state diagram.
\r
2684 Full description of all special cases should be found in the text.
\r
2690 Stewart, et al. Standards Track [Page 48]
\r
2692 RFC 2960 Stream Control Transmission Protocol October 2000
\r
2695 Note: Chunk names are given in all capital letters, while parameter
\r
2696 names have the first letter capitalized, e.g., COOKIE ECHO chunk type
\r
2697 vs. State Cookie parameter. If more than one event/message can occur
\r
2698 which causes a state transition it is labeled (A), (B) etc.
\r
2700 ----- -------- (frm any state)
\r
2701 / \ / rcv ABORT [ABORT]
\r
2702 rcv INIT | | | ---------- or ----------
\r
2703 --------------- | v v delete TCB snd ABORT
\r
2704 generate Cookie \ +---------+ delete TCB
\r
2705 snd INIT ACK ---| CLOSED |
\r
2708 / \ ---------------
\r
2711 | | strt init timer
\r
2714 (1) ---------------- | +------------+
\r
2715 create TCB | | COOKIE-WAIT| (2)
\r
2716 snd COOKIE ACK | +------------+
\r
2719 | | -----------------
\r
2720 | | snd COOKIE ECHO
\r
2721 | | stop init timer
\r
2722 | | strt cookie timer
\r
2724 | +--------------+
\r
2725 | | COOKIE-ECHOED| (3)
\r
2726 | +--------------+
\r
2728 | | rcv COOKIE ACK
\r
2729 | | -----------------
\r
2730 | | stop cookie timer
\r
2746 Stewart, et al. Standards Track [Page 49]
\r
2748 RFC 2960 Stream Control Transmission Protocol October 2000
\r
2751 (from the ESTABLISHED state only)
\r
2754 /--------+--------\
\r
2756 -------------------| |
\r
2757 check outstanding | |
\r
2761 |SHUTDOWN-| | rcv SHUTDOWN/check
\r
2762 |PENDING | | outstanding DATA
\r
2763 +---------+ | chunks
\r
2764 | |------------------
\r
2765 No more outstanding | |
\r
2766 ---------------------| |
\r
2768 strt shutdown timer | |
\r
2770 +---------+ +-----------+
\r
2771 (4) |SHUTDOWN-| | SHUTDOWN- | (5,6)
\r
2772 |SENT | | RECEIVED |
\r
2773 +---------+ +-----------+
\r
2775 (A) rcv SHUTDOWN ACK | \ |
\r
2776 ----------------------| \ |
\r
2777 stop shutdown timer | \rcv:SHUTDOWN |
\r
2778 send SHUTDOWN COMPLETE| \ (B) |
\r
2780 | \ | No more outstanding
\r
2781 | \ |-----------------
\r
2782 | \ | send SHUTDOWN ACK
\r
2783 (B)rcv SHUTDOWN | \ | strt shutdown timer
\r
2784 ----------------------| \ |
\r
2785 send SHUTDOWN ACK | \ |
\r
2786 start shutdown timer | \ |
\r
2787 move to SHUTDOWN- | \ |
\r
2791 | | SHUTDOWN- | (7)
\r
2794 | | (C)rcv SHUTDOWN COMPLETE
\r
2795 | |-----------------
\r
2796 | | stop shutdown timer
\r
2802 Stewart, et al. Standards Track [Page 50]
\r
2804 RFC 2960 Stream Control Transmission Protocol October 2000
\r
2807 | | (D)rcv SHUTDOWN ACK
\r
2809 | | stop shutdown timer
\r
2810 | | send SHUTDOWN COMPLETE
\r
2814 \-->| CLOSED |<--/
\r
2817 Figure 3: State Transition Diagram of SCTP
\r
2821 1) If the State Cookie in the received COOKIE ECHO is invalid (i.e.,
\r
2822 failed to pass the integrity check), the receiver MUST silently
\r
2823 discard the packet. Or, if the received State Cookie is expired
\r
2824 (see Section 5.1.5), the receiver MUST send back an ERROR chunk.
\r
2825 In either case, the receiver stays in the CLOSED state.
\r
2827 2) If the T1-init timer expires, the endpoint MUST retransmit INIT
\r
2828 and re-start the T1-init timer without changing state. This MUST
\r
2829 be repeated up to 'Max.Init.Retransmits' times. After that, the
\r
2830 endpoint MUST abort the initialization process and report the
\r
2831 error to SCTP user.
\r
2833 3) If the T1-cookie timer expires, the endpoint MUST retransmit
\r
2834 COOKIE ECHO and re-start the T1-cookie timer without changing
\r
2835 state. This MUST be repeated up to 'Max.Init.Retransmits' times.
\r
2836 After that, the endpoint MUST abort the initialization process and
\r
2837 report the error to SCTP user.
\r
2839 4) In SHUTDOWN-SENT state the endpoint MUST acknowledge any received
\r
2840 DATA chunks without delay.
\r
2842 5) In SHUTDOWN-RECEIVED state, the endpoint MUST NOT accept any new
\r
2843 send request from its SCTP user.
\r
2845 6) In SHUTDOWN-RECEIVED state, the endpoint MUST transmit or
\r
2846 retransmit data and leave this state when all data in queue is
\r
2849 7) In SHUTDOWN-ACK-SENT state, the endpoint MUST NOT accept any new
\r
2850 send request from its SCTP user.
\r
2852 The CLOSED state is used to indicate that an association is not
\r
2853 created (i.e., doesn't exist).
\r
2858 Stewart, et al. Standards Track [Page 51]
\r
2860 RFC 2960 Stream Control Transmission Protocol October 2000
\r
2863 5. Association Initialization
\r
2865 Before the first data transmission can take place from one SCTP
\r
2866 endpoint ("A") to another SCTP endpoint ("Z"), the two endpoints must
\r
2867 complete an initialization process in order to set up an SCTP
\r
2868 association between them.
\r
2870 The SCTP user at an endpoint should use the ASSOCIATE primitive to
\r
2871 initialize an SCTP association to another SCTP endpoint.
\r
2873 IMPLEMENTATION NOTE: From an SCTP-user's point of view, an
\r
2874 association may be implicitly opened, without an ASSOCIATE primitive
\r
2875 (see 10.1 B) being invoked, by the initiating endpoint's sending of
\r
2876 the first user data to the destination endpoint. The initiating SCTP
\r
2877 will assume default values for all mandatory and optional parameters
\r
2878 for the INIT/INIT ACK.
\r
2880 Once the association is established, unidirectional streams are open
\r
2881 for data transfer on both ends (see Section 5.1.1).
\r
2883 5.1 Normal Establishment of an Association
\r
2885 The initialization process consists of the following steps (assuming
\r
2886 that SCTP endpoint "A" tries to set up an association with SCTP
\r
2887 endpoint "Z" and "Z" accepts the new association):
\r
2889 A) "A" first sends an INIT chunk to "Z". In the INIT, "A" must
\r
2890 provide its Verification Tag (Tag_A) in the Initiate Tag field.
\r
2891 Tag_A SHOULD be a random number in the range of 1 to 4294967295
\r
2892 (see 5.3.1 for Tag value selection). After sending the INIT, "A"
\r
2893 starts the T1-init timer and enters the COOKIE-WAIT state.
\r
2895 B) "Z" shall respond immediately with an INIT ACK chunk. The
\r
2896 destination IP address of the INIT ACK MUST be set to the source
\r
2897 IP address of the INIT to which this INIT ACK is responding. In
\r
2898 the response, besides filling in other parameters, "Z" must set
\r
2899 the Verification Tag field to Tag_A, and also provide its own
\r
2900 Verification Tag (Tag_Z) in the Initiate Tag field.
\r
2902 Moreover, "Z" MUST generate and send along with the INIT ACK a
\r
2903 State Cookie. See Section 5.1.3 for State Cookie generation.
\r
2905 Note: After sending out INIT ACK with the State Cookie parameter,
\r
2906 "Z" MUST NOT allocate any resources, nor keep any states for the
\r
2907 new association. Otherwise, "Z" will be vulnerable to resource
\r
2914 Stewart, et al. Standards Track [Page 52]
\r
2916 RFC 2960 Stream Control Transmission Protocol October 2000
\r
2919 C) Upon reception of the INIT ACK from "Z", "A" shall stop the T1-
\r
2920 init timer and leave COOKIE-WAIT state. "A" shall then send the
\r
2921 State Cookie received in the INIT ACK chunk in a COOKIE ECHO
\r
2922 chunk, start the T1-cookie timer, and enter the COOKIE-ECHOED
\r
2925 Note: The COOKIE ECHO chunk can be bundled with any pending
\r
2926 outbound DATA chunks, but it MUST be the first chunk in the packet
\r
2927 and until the COOKIE ACK is returned the sender MUST NOT send any
\r
2928 other packets to the peer.
\r
2930 D) Upon reception of the COOKIE ECHO chunk, Endpoint "Z" will reply
\r
2931 with a COOKIE ACK chunk after building a TCB and moving to the
\r
2932 ESTABLISHED state. A COOKIE ACK chunk may be bundled with any
\r
2933 pending DATA chunks (and/or SACK chunks), but the COOKIE ACK chunk
\r
2934 MUST be the first chunk in the packet.
\r
2936 IMPLEMENTATION NOTE: An implementation may choose to send the
\r
2937 Communication Up notification to the SCTP user upon reception of a
\r
2938 valid COOKIE ECHO chunk.
\r
2940 E) Upon reception of the COOKIE ACK, endpoint "A" will move from the
\r
2941 COOKIE-ECHOED state to the ESTABLISHED state, stopping the T1-
\r
2942 cookie timer. It may also notify its ULP about the successful
\r
2943 establishment of the association with a Communication Up
\r
2944 notification (see Section 10).
\r
2946 An INIT or INIT ACK chunk MUST NOT be bundled with any other chunk.
\r
2947 They MUST be the only chunks present in the SCTP packets that carry
\r
2950 An endpoint MUST send the INIT ACK to the IP address from which it
\r
2951 received the INIT.
\r
2953 Note: T1-init timer and T1-cookie timer shall follow the same rules
\r
2954 given in Section 6.3.
\r
2956 If an endpoint receives an INIT, INIT ACK, or COOKIE ECHO chunk but
\r
2957 decides not to establish the new association due to missing mandatory
\r
2958 parameters in the received INIT or INIT ACK, invalid parameter
\r
2959 values, or lack of local resources, it MUST respond with an ABORT
\r
2960 chunk. It SHOULD also specify the cause of abort, such as the type
\r
2961 of the missing mandatory parameters, etc., by including the error
\r
2962 cause parameters with the ABORT chunk. The Verification Tag field in
\r
2963 the common header of the outbound SCTP packet containing the ABORT
\r
2964 chunk MUST be set to the Initiate Tag value of the peer.
\r
2970 Stewart, et al. Standards Track [Page 53]
\r
2972 RFC 2960 Stream Control Transmission Protocol October 2000
\r
2975 After the reception of the first DATA chunk in an association the
\r
2976 endpoint MUST immediately respond with a SACK to acknowledge the DATA
\r
2977 chunk. Subsequent acknowledgements should be done as described in
\r
2980 When the TCB is created, each endpoint MUST set its internal
\r
2981 Cumulative TSN Ack Point to the value of its transmitted Initial TSN
\r
2984 IMPLEMENTATION NOTE: The IP addresses and SCTP port are generally
\r
2985 used as the key to find the TCB within an SCTP instance.
\r
2987 5.1.1 Handle Stream Parameters
\r
2989 In the INIT and INIT ACK chunks, the sender of the chunk shall
\r
2990 indicate the number of outbound streams (OS) it wishes to have in the
\r
2991 association, as well as the maximum inbound streams (MIS) it will
\r
2992 accept from the other endpoint.
\r
2994 After receiving the stream configuration information from the other
\r
2995 side, each endpoint shall perform the following check: If the peer's
\r
2996 MIS is less than the endpoint's OS, meaning that the peer is
\r
2997 incapable of supporting all the outbound streams the endpoint wants
\r
2998 to configure, the endpoint MUST either use MIS outbound streams, or
\r
2999 abort the association and report to its upper layer the resources
\r
3000 shortage at its peer.
\r
3002 After the association is initialized, the valid outbound stream
\r
3003 identifier range for either endpoint shall be 0 to min(local OS,
\r
3006 5.1.2 Handle Address Parameters
\r
3008 During the association initialization, an endpoint shall use the
\r
3009 following rules to discover and collect the destination transport
\r
3010 address(es) of its peer.
\r
3012 A) If there are no address parameters present in the received INIT or
\r
3013 INIT ACK chunk, the endpoint shall take the source IP address from
\r
3014 which the chunk arrives and record it, in combination with the
\r
3015 SCTP source port number, as the only destination transport address
\r
3018 B) If there is a Host Name parameter present in the received INIT or
\r
3019 INIT ACK chunk, the endpoint shall resolve that host name to a
\r
3020 list of IP address(es) and derive the transport address(es) of
\r
3021 this peer by combining the resolved IP address(es) with the SCTP
\r
3026 Stewart, et al. Standards Track [Page 54]
\r
3028 RFC 2960 Stream Control Transmission Protocol October 2000
\r
3031 The endpoint MUST ignore any other IP address parameters if they
\r
3032 are also present in the received INIT or INIT ACK chunk.
\r
3034 The time at which the receiver of an INIT resolves the host name
\r
3035 has potential security implications to SCTP. If the receiver of
\r
3036 an INIT resolves the host name upon the reception of the chunk,
\r
3037 and the mechanism the receiver uses to resolve the host name
\r
3038 involves potential long delay (e.g. DNS query), the receiver may
\r
3039 open itself up to resource attacks for the period of time while it
\r
3040 is waiting for the name resolution results before it can build the
\r
3041 State Cookie and release local resources.
\r
3043 Therefore, in cases where the name translation involves potential
\r
3044 long delay, the receiver of the INIT MUST postpone the name
\r
3045 resolution till the reception of the COOKIE ECHO chunk from the
\r
3046 peer. In such a case, the receiver of the INIT SHOULD build the
\r
3047 State Cookie using the received Host Name (instead of destination
\r
3048 transport addresses) and send the INIT ACK to the source IP
\r
3049 address from which the INIT was received.
\r
3051 The receiver of an INIT ACK shall always immediately attempt to
\r
3052 resolve the name upon the reception of the chunk.
\r
3054 The receiver of the INIT or INIT ACK MUST NOT send user data
\r
3055 (piggy-backed or stand-alone) to its peer until the host name is
\r
3056 successfully resolved.
\r
3058 If the name resolution is not successful, the endpoint MUST
\r
3059 immediately send an ABORT with "Unresolvable Address" error cause
\r
3060 to its peer. The ABORT shall be sent to the source IP address
\r
3061 from which the last peer packet was received.
\r
3063 C) If there are only IPv4/IPv6 addresses present in the received INIT
\r
3064 or INIT ACK chunk, the receiver shall derive and record all the
\r
3065 transport address(es) from the received chunk AND the source IP
\r
3066 address that sent the INIT or INIT ACK. The transport address(es)
\r
3067 are derived by the combination of SCTP source port (from the
\r
3068 common header) and the IP address parameter(s) carried in the INIT
\r
3069 or INIT ACK chunk and the source IP address of the IP datagram.
\r
3070 The receiver should use only these transport addresses as
\r
3071 destination transport addresses when sending subsequent packets to
\r
3074 IMPLEMENTATION NOTE: In some cases (e.g., when the implementation
\r
3075 doesn't control the source IP address that is used for
\r
3076 transmitting), an endpoint might need to include in its INIT or
\r
3077 INIT ACK all possible IP addresses from which packets to the peer
\r
3078 could be transmitted.
\r
3082 Stewart, et al. Standards Track [Page 55]
\r
3084 RFC 2960 Stream Control Transmission Protocol October 2000
\r
3087 After all transport addresses are derived from the INIT or INIT ACK
\r
3088 chunk using the above rules, the endpoint shall select one of the
\r
3089 transport addresses as the initial primary path.
\r
3091 Note: The INIT-ACK MUST be sent to the source address of the INIT.
\r
3093 The sender of INIT may include a 'Supported Address Types' parameter
\r
3094 in the INIT to indicate what types of address are acceptable. When
\r
3095 this parameter is present, the receiver of INIT (initiatee) MUST
\r
3096 either use one of the address types indicated in the Supported
\r
3097 Address Types parameter when responding to the INIT, or abort the
\r
3098 association with an "Unresolvable Address" error cause if it is
\r
3099 unwilling or incapable of using any of the address types indicated by
\r
3102 IMPLEMENTATION NOTE: In the case that the receiver of an INIT ACK
\r
3103 fails to resolve the address parameter due to an unsupported type, it
\r
3104 can abort the initiation process and then attempt a re-initiation by
\r
3105 using a 'Supported Address Types' parameter in the new INIT to
\r
3106 indicate what types of address it prefers.
\r
3108 5.1.3 Generating State Cookie
\r
3110 When sending an INIT ACK as a response to an INIT chunk, the sender
\r
3111 of INIT ACK creates a State Cookie and sends it in the State Cookie
\r
3112 parameter of the INIT ACK. Inside this State Cookie, the sender
\r
3113 should include a MAC (see [RFC2104] for an example), a time stamp on
\r
3114 when the State Cookie is created, and the lifespan of the State
\r
3115 Cookie, along with all the information necessary for it to establish
\r
3118 The following steps SHOULD be taken to generate the State Cookie:
\r
3120 1) Create an association TCB using information from both the received
\r
3121 INIT and the outgoing INIT ACK chunk,
\r
3123 2) In the TCB, set the creation time to the current time of day, and
\r
3124 the lifespan to the protocol parameter 'Valid.Cookie.Life',
\r
3126 3) From the TCB, identify and collect the minimal subset of
\r
3127 information needed to re-create the TCB, and generate a MAC using
\r
3128 this subset of information and a secret key (see [RFC2104] for an
\r
3129 example of generating a MAC), and
\r
3131 4) Generate the State Cookie by combining this subset of information
\r
3132 and the resultant MAC.
\r
3138 Stewart, et al. Standards Track [Page 56]
\r
3140 RFC 2960 Stream Control Transmission Protocol October 2000
\r
3143 After sending the INIT ACK with the State Cookie parameter, the
\r
3144 sender SHOULD delete the TCB and any other local resource related to
\r
3145 the new association, so as to prevent resource attacks.
\r
3147 The hashing method used to generate the MAC is strictly a private
\r
3148 matter for the receiver of the INIT chunk. The use of a MAC is
\r
3149 mandatory to prevent denial of service attacks. The secret key
\r
3150 SHOULD be random ([RFC1750] provides some information on randomness
\r
3151 guidelines); it SHOULD be changed reasonably frequently, and the
\r
3152 timestamp in the State Cookie MAY be used to determine which key
\r
3153 should be used to verify the MAC.
\r
3155 An implementation SHOULD make the cookie as small as possible to
\r
3156 insure interoperability.
\r
3158 5.1.4 State Cookie Processing
\r
3160 When an endpoint (in the COOKIE WAIT state) receives an INIT ACK
\r
3161 chunk with a State Cookie parameter, it MUST immediately send a
\r
3162 COOKIE ECHO chunk to its peer with the received State Cookie. The
\r
3163 sender MAY also add any pending DATA chunks to the packet after the
\r
3164 COOKIE ECHO chunk.
\r
3166 The endpoint shall also start the T1-cookie timer after sending out
\r
3167 the COOKIE ECHO chunk. If the timer expires, the endpoint shall
\r
3168 retransmit the COOKIE ECHO chunk and restart the T1-cookie timer.
\r
3169 This is repeated until either a COOKIE ACK is received or '
\r
3170 Max.Init.Retransmits' is reached causing the peer endpoint to be
\r
3171 marked unreachable (and thus the association enters the CLOSED
\r
3174 5.1.5 State Cookie Authentication
\r
3176 When an endpoint receives a COOKIE ECHO chunk from another endpoint
\r
3177 with which it has no association, it shall take the following
\r
3180 1) Compute a MAC using the TCB data carried in the State Cookie and
\r
3181 the secret key (note the timestamp in the State Cookie MAY be used
\r
3182 to determine which secret key to use). Reference [RFC2104] can be
\r
3183 used as a guideline for generating the MAC,
\r
3185 2) Authenticate the State Cookie as one that it previously generated
\r
3186 by comparing the computed MAC against the one carried in the State
\r
3187 Cookie. If this comparison fails, the SCTP packet, including the
\r
3188 COOKIE ECHO and any DATA chunks, should be silently discarded,
\r
3194 Stewart, et al. Standards Track [Page 57]
\r
3196 RFC 2960 Stream Control Transmission Protocol October 2000
\r
3199 3) Compare the creation timestamp in the State Cookie to the current
\r
3200 local time. If the elapsed time is longer than the lifespan
\r
3201 carried in the State Cookie, then the packet, including the COOKIE
\r
3202 ECHO and any attached DATA chunks, SHOULD be discarded and the
\r
3203 endpoint MUST transmit an ERROR chunk with a "Stale Cookie" error
\r
3204 cause to the peer endpoint,
\r
3206 4) If the State Cookie is valid, create an association to the sender
\r
3207 of the COOKIE ECHO chunk with the information in the TCB data
\r
3208 carried in the COOKIE ECHO, and enter the ESTABLISHED state,
\r
3210 5) Send a COOKIE ACK chunk to the peer acknowledging reception of the
\r
3211 COOKIE ECHO. The COOKIE ACK MAY be bundled with an outbound DATA
\r
3212 chunk or SACK chunk; however, the COOKIE ACK MUST be the first
\r
3213 chunk in the SCTP packet.
\r
3215 6) Immediately acknowledge any DATA chunk bundled with the COOKIE
\r
3216 ECHO with a SACK (subsequent DATA chunk acknowledgement should
\r
3217 follow the rules defined in Section 6.2). As mentioned in step
\r
3218 5), if the SACK is bundled with the COOKIE ACK, the COOKIE ACK
\r
3219 MUST appear first in the SCTP packet.
\r
3221 If a COOKIE ECHO is received from an endpoint with which the receiver
\r
3222 of the COOKIE ECHO has an existing association, the procedures in
\r
3223 Section 5.2 should be followed.
\r
3225 5.1.6 An Example of Normal Association Establishment
\r
3227 In the following example, "A" initiates the association and then
\r
3228 sends a user message to "Z", then "Z" sends two user messages to "A"
\r
3229 later (assuming no bundling or fragmentation occurs):
\r
3250 Stewart, et al. Standards Track [Page 58]
\r
3252 RFC 2960 Stream Control Transmission Protocol October 2000
\r
3255 Endpoint A Endpoint Z
\r
3256 {app sets association with Z}
\r
3259 & other info] --------\
\r
3260 (Start T1-init timer) \
\r
3261 (Enter COOKIE-WAIT state) \---> (compose temp TCB and Cookie_Z)
\r
3263 /--- INIT ACK [Veri Tag=Tag_A,
\r
3265 (Cancel T1-init timer) <------/ Cookie_Z, & other info]
\r
3266 (destroy temp TCB)
\r
3267 COOKIE ECHO [Cookie_Z] ------\
\r
3268 (Start T1-init timer) \
\r
3269 (Enter COOKIE-ECHOED state) \---> (build TCB enter ESTABLISHED
\r
3275 (Cancel T1-init timer, <-----/
\r
3276 Enter ESTABLISHED state)
\r
3277 {app sends 1st user data; strm 0}
\r
3278 DATA [TSN=initial TSN_A
\r
3279 Strm=0,Seq=1 & user data]--\
\r
3280 (Start T3-rtx timer) \
\r
3282 /----- SACK [TSN Ack=init
\r
3284 (Cancel T3-rtx timer) <------/
\r
3287 {app sends 2 messages;strm 0}
\r
3290 <--/ Strm=0,Seq=1 & user data 1]
\r
3291 SACK [TSN Ack=init TSN_Z, /---- DATA
\r
3292 Block=0] --------\ / [TSN=init TSN_Z +1,
\r
3293 \/ Strm=0,Seq=2 & user data 2]
\r
3298 Figure 4: INITiation Example
\r
3300 If the T1-init timer expires at "A" after the INIT or COOKIE ECHO
\r
3301 chunks are sent, the same INIT or COOKIE ECHO chunk with the same
\r
3302 Initiate Tag (i.e., Tag_A) or State Cookie shall be retransmitted and
\r
3306 Stewart, et al. Standards Track [Page 59]
\r
3308 RFC 2960 Stream Control Transmission Protocol October 2000
\r
3311 the timer restarted. This shall be repeated Max.Init.Retransmits
\r
3312 times before "A" considers "Z" unreachable and reports the failure to
\r
3313 its upper layer (and thus the association enters the CLOSED state).
\r
3314 When retransmitting the INIT, the endpoint MUST follow the rules
\r
3315 defined in 6.3 to determine the proper timer value.
\r
3317 5.2 Handle Duplicate or Unexpected INIT, INIT ACK, COOKIE ECHO, and
\r
3320 During the lifetime of an association (in one of the possible
\r
3321 states), an endpoint may receive from its peer endpoint one of the
\r
3322 setup chunks (INIT, INIT ACK, COOKIE ECHO, and COOKIE ACK). The
\r
3323 receiver shall treat such a setup chunk as a duplicate and process it
\r
3324 as described in this section.
\r
3326 Note: An endpoint will not receive the chunk unless the chunk was
\r
3327 sent to a SCTP transport address and is from a SCTP transport address
\r
3328 associated with this endpoint. Therefore, the endpoint processes
\r
3329 such a chunk as part of its current association.
\r
3331 The following scenarios can cause duplicated or unexpected chunks:
\r
3333 A) The peer has crashed without being detected, re-started itself and
\r
3334 sent out a new INIT chunk trying to restore the association,
\r
3336 B) Both sides are trying to initialize the association at about the
\r
3339 C) The chunk is from a stale packet that was used to establish the
\r
3340 present association or a past association that is no longer in
\r
3343 D) The chunk is a false packet generated by an attacker, or
\r
3345 E) The peer never received the COOKIE ACK and is retransmitting its
\r
3348 The rules in the following sections shall be applied in order to
\r
3349 identify and correctly handle these cases.
\r
3351 5.2.1 INIT received in COOKIE-WAIT or COOKIE-ECHOED State (Item B)
\r
3353 This usually indicates an initialization collision, i.e., each
\r
3354 endpoint is attempting, at about the same time, to establish an
\r
3355 association with the other endpoint.
\r
3357 Upon receipt of an INIT in the COOKIE-WAIT or COOKIE-ECHOED state, an
\r
3358 endpoint MUST respond with an INIT ACK using the same parameters it
\r
3362 Stewart, et al. Standards Track [Page 60]
\r
3364 RFC 2960 Stream Control Transmission Protocol October 2000
\r
3367 sent in its original INIT chunk (including its Initiation Tag,
\r
3368 unchanged). These original parameters are combined with those from
\r
3369 the newly received INIT chunk. The endpoint shall also generate a
\r
3370 State Cookie with the INIT ACK. The endpoint uses the parameters
\r
3371 sent in its INIT to calculate the State Cookie.
\r
3373 After that, the endpoint MUST NOT change its state, the T1-init timer
\r
3374 shall be left running and the corresponding TCB MUST NOT be
\r
3375 destroyed. The normal procedures for handling State Cookies when a
\r
3376 TCB exists will resolve the duplicate INITs to a single association.
\r
3378 For an endpoint that is in the COOKIE-ECHOED state it MUST populate
\r
3379 its Tie-Tags with the Tag information of itself and its peer (see
\r
3380 section 5.2.2 for a description of the Tie-Tags).
\r
3382 5.2.2 Unexpected INIT in States Other than CLOSED, COOKIE-ECHOED,
\r
3383 COOKIE-WAIT and SHUTDOWN-ACK-SENT
\r
3385 Unless otherwise stated, upon reception of an unexpected INIT for
\r
3386 this association, the endpoint shall generate an INIT ACK with a
\r
3387 State Cookie. In the outbound INIT ACK the endpoint MUST copy its
\r
3388 current Verification Tag and peer's Verification Tag into a reserved
\r
3389 place within the state cookie. We shall refer to these locations as
\r
3390 the Peer's-Tie-Tag and the Local-Tie-Tag. The outbound SCTP packet
\r
3391 containing this INIT ACK MUST carry a Verification Tag value equal to
\r
3392 the Initiation Tag found in the unexpected INIT. And the INIT ACK
\r
3393 MUST contain a new Initiation Tag (randomly generated see Section
\r
3394 5.3.1). Other parameters for the endpoint SHOULD be copied from the
\r
3395 existing parameters of the association (e.g. number of outbound
\r
3396 streams) into the INIT ACK and cookie.
\r
3398 After sending out the INIT ACK, the endpoint shall take no further
\r
3399 actions, i.e., the existing association, including its current state,
\r
3400 and the corresponding TCB MUST NOT be changed.
\r
3402 Note: Only when a TCB exists and the association is not in a COOKIE-
\r
3403 WAIT state are the Tie-Tags populated. For a normal association INIT
\r
3404 (i.e. the endpoint is in a COOKIE-WAIT state), the Tie-Tags MUST be
\r
3405 set to 0 (indicating that no previous TCB existed). The INIT ACK and
\r
3406 State Cookie are populated as specified in section 5.2.1.
\r
3408 5.2.3 Unexpected INIT ACK
\r
3410 If an INIT ACK is received by an endpoint in any state other than the
\r
3411 COOKIE-WAIT state, the endpoint should discard the INIT ACK chunk.
\r
3412 An unexpected INIT ACK usually indicates the processing of an old or
\r
3413 duplicated INIT chunk.
\r
3418 Stewart, et al. Standards Track [Page 61]
\r
3420 RFC 2960 Stream Control Transmission Protocol October 2000
\r
3423 5.2.4 Handle a COOKIE ECHO when a TCB exists
\r
3425 When a COOKIE ECHO chunk is received by an endpoint in any state for
\r
3426 an existing association (i.e., not in the CLOSED state) the following
\r
3427 rules shall be applied:
\r
3429 1) Compute a MAC as described in Step 1 of Section 5.1.5,
\r
3431 2) Authenticate the State Cookie as described in Step 2 of Section
\r
3432 5.1.5 (this is case C or D above).
\r
3434 3) Compare the timestamp in the State Cookie to the current time. If
\r
3435 the State Cookie is older than the lifespan carried in the State
\r
3436 Cookie and the Verification Tags contained in the State Cookie do
\r
3437 not match the current association's Verification Tags, the packet,
\r
3438 including the COOKIE ECHO and any DATA chunks, should be
\r
3439 discarded. The endpoint also MUST transmit an ERROR chunk with a
\r
3440 "Stale Cookie" error cause to the peer endpoint (this is case C or
\r
3441 D in section 5.2).
\r
3443 If both Verification Tags in the State Cookie match the
\r
3444 Verification Tags of the current association, consider the State
\r
3445 Cookie valid (this is case E of section 5.2) even if the lifespan
\r
3448 4) If the State Cookie proves to be valid, unpack the TCB into a
\r
3451 5) Refer to Table 2 to determine the correct action to be taken.
\r
3474 Stewart, et al. Standards Track [Page 62]
\r
3476 RFC 2960 Stream Control Transmission Protocol October 2000
\r
3479 +------------+------------+---------------+--------------+-------------+
\r
3480 | Local Tag | Peer's Tag | Local-Tie-Tag |Peer's-Tie-Tag| Action/ |
\r
3481 | | | | | Description |
\r
3482 +------------+------------+---------------+--------------+-------------+
\r
3483 | X | X | M | M | (A) |
\r
3484 +------------+------------+---------------+--------------+-------------+
\r
3485 | M | X | A | A | (B) |
\r
3486 +------------+------------+---------------+--------------+-------------+
\r
3487 | M | 0 | A | A | (B) |
\r
3488 +------------+------------+---------------+--------------+-------------+
\r
3489 | X | M | 0 | 0 | (C) |
\r
3490 +------------+------------+---------------+--------------+-------------+
\r
3491 | M | M | A | A | (D) |
\r
3492 +======================================================================+
\r
3493 | Table 2: Handling of a COOKIE ECHO when a TCB exists |
\r
3494 +======================================================================+
\r
3498 X - Tag does not match the existing TCB
\r
3499 M - Tag matches the existing TCB.
\r
3500 0 - No Tie-Tag in Cookie (unknown).
\r
3501 A - All cases, i.e. M, X or 0.
\r
3503 Note: For any case not shown in Table 2, the cookie should be
\r
3504 silently discarded.
\r
3508 A) In this case, the peer may have restarted. When the endpoint
\r
3509 recognizes this potential 'restart', the existing session is
\r
3510 treated the same as if it received an ABORT followed by a new
\r
3511 COOKIE ECHO with the following exceptions:
\r
3513 - Any SCTP DATA Chunks MAY be retained (this is an implementation
\r
3516 - A notification of RESTART SHOULD be sent to the ULP instead of
\r
3517 a "COMMUNICATION LOST" notification.
\r
3519 All the congestion control parameters (e.g., cwnd, ssthresh)
\r
3520 related to this peer MUST be reset to their initial values (see
\r
3523 After this the endpoint shall enter the ESTABLISHED state.
\r
3530 Stewart, et al. Standards Track [Page 63]
\r
3532 RFC 2960 Stream Control Transmission Protocol October 2000
\r
3535 If the endpoint is in the SHUTDOWN-ACK-SENT state and recognizes
\r
3536 the peer has restarted (Action A), it MUST NOT setup a new
\r
3537 association but instead resend the SHUTDOWN ACK and send an ERROR
\r
3538 chunk with a "Cookie Received while Shutting Down" error cause to
\r
3541 B) In this case, both sides may be attempting to start an association
\r
3542 at about the same time but the peer endpoint started its INIT
\r
3543 after responding to the local endpoint's INIT. Thus it may have
\r
3544 picked a new Verification Tag not being aware of the previous Tag
\r
3545 it had sent this endpoint. The endpoint should stay in or enter
\r
3546 the ESTABLISHED state but it MUST update its peer's Verification
\r
3547 Tag from the State Cookie, stop any init or cookie timers that may
\r
3548 running and send a COOKIE ACK.
\r
3550 C) In this case, the local endpoint's cookie has arrived late.
\r
3551 Before it arrived, the local endpoint sent an INIT and received an
\r
3552 INIT-ACK and finally sent a COOKIE ECHO with the peer's same tag
\r
3553 but a new tag of its own. The cookie should be silently
\r
3554 discarded. The endpoint SHOULD NOT change states and should leave
\r
3555 any timers running.
\r
3557 D) When both local and remote tags match the endpoint should always
\r
3558 enter the ESTABLISHED state, if it has not already done so. It
\r
3559 should stop any init or cookie timers that may be running and send
\r
3562 Note: The "peer's Verification Tag" is the tag received in the
\r
3563 Initiate Tag field of the INIT or INIT ACK chunk.
\r
3565 5.2.4.1 An Example of a Association Restart
\r
3567 In the following example, "A" initiates the association after a
\r
3568 restart has occurred. Endpoint "Z" had no knowledge of the restart
\r
3569 until the exchange (i.e. Heartbeats had not yet detected the failure
\r
3570 of "A"). (assuming no bundling or fragmentation occurs):
\r
3586 Stewart, et al. Standards Track [Page 64]
\r
3588 RFC 2960 Stream Control Transmission Protocol October 2000
\r
3591 Endpoint A Endpoint Z
\r
3592 <-------------- Association is established---------------------->
\r
3593 Tag=Tag_A Tag=Tag_Z
\r
3594 <--------------------------------------------------------------->
\r
3595 {A crashes and restarts}
\r
3596 {app sets up a association with Z}
\r
3598 INIT [I-Tag=Tag_A'
\r
3599 & other info] --------\
\r
3600 (Start T1-init timer) \
\r
3601 (Enter COOKIE-WAIT state) \---> (find a existing TCB
\r
3602 compose temp TCB and Cookie_Z
\r
3603 with Tie-Tags to previous
\r
3605 /--- INIT ACK [Veri Tag=Tag_A',
\r
3607 (Cancel T1-init timer) <------/ Cookie_Z[TieTags=
\r
3610 (destroy temp TCB,leave original
\r
3612 COOKIE ECHO [Veri=Tag_Z',
\r
3616 (Start T1-init timer) \
\r
3617 (Enter COOKIE-ECHOED state) \---> (Find existing association,
\r
3618 Tie-Tags match old tags,
\r
3619 Tags do not match i.e.
\r
3620 case X X M M above,
\r
3621 Announce Restart to ULP
\r
3622 and reset association).
\r
3625 (Cancel T1-init timer, <-----/
\r
3626 Enter ESTABLISHED state)
\r
3627 {app sends 1st user data; strm 0}
\r
3628 DATA [TSN=initial TSN_A
\r
3629 Strm=0,Seq=1 & user data]--\
\r
3630 (Start T3-rtx timer) \
\r
3632 /----- SACK [TSN Ack=init TSN_A,Block=0]
\r
3633 (Cancel T3-rtx timer) <------/
\r
3635 Figure 5: A Restart Example
\r
3642 Stewart, et al. Standards Track [Page 65]
\r
3644 RFC 2960 Stream Control Transmission Protocol October 2000
\r
3647 5.2.5 Handle Duplicate COOKIE-ACK.
\r
3649 At any state other than COOKIE-ECHOED, an endpoint should silently
\r
3650 discard a received COOKIE ACK chunk.
\r
3652 5.2.6 Handle Stale COOKIE Error
\r
3654 Receipt of an ERROR chunk with a "Stale Cookie" error cause indicates
\r
3655 one of a number of possible events:
\r
3657 A) That the association failed to completely setup before the State
\r
3658 Cookie issued by the sender was processed.
\r
3660 B) An old State Cookie was processed after setup completed.
\r
3662 C) An old State Cookie is received from someone that the receiver is
\r
3663 not interested in having an association with and the ABORT chunk
\r
3666 When processing an ERROR chunk with a "Stale Cookie" error cause an
\r
3667 endpoint should first examine if an association is in the process of
\r
3668 being setup, i.e. the association is in the COOKIE-ECHOED state. In
\r
3669 all cases if the association is not in the COOKIE-ECHOED state, the
\r
3670 ERROR chunk should be silently discarded.
\r
3672 If the association is in the COOKIE-ECHOED state, the endpoint may
\r
3673 elect one of the following three alternatives.
\r
3675 1) Send a new INIT chunk to the endpoint to generate a new State
\r
3676 Cookie and re-attempt the setup procedure.
\r
3678 2) Discard the TCB and report to the upper layer the inability to
\r
3679 setup the association.
\r
3681 3) Send a new INIT chunk to the endpoint, adding a Cookie
\r
3682 Preservative parameter requesting an extension to the lifetime of
\r
3683 the State Cookie. When calculating the time extension, an
\r
3684 implementation SHOULD use the RTT information measured based on
\r
3685 the previous COOKIE ECHO / ERROR exchange, and should add no more
\r
3686 than 1 second beyond the measured RTT, due to long State Cookie
\r
3687 lifetimes making the endpoint more subject to a replay attack.
\r
3698 Stewart, et al. Standards Track [Page 66]
\r
3700 RFC 2960 Stream Control Transmission Protocol October 2000
\r
3703 5.3 Other Initialization Issues
\r
3705 5.3.1 Selection of Tag Value
\r
3707 Initiate Tag values should be selected from the range of 1 to 2**32 -
\r
3708 1. It is very important that the Initiate Tag value be randomized to
\r
3709 help protect against "man in the middle" and "sequence number"
\r
3710 attacks. The methods described in [RFC1750] can be used for the
\r
3711 Initiate Tag randomization. Careful selection of Initiate Tags is
\r
3712 also necessary to prevent old duplicate packets from previous
\r
3713 associations being mistakenly processed as belonging to the current
\r
3716 Moreover, the Verification Tag value used by either endpoint in a
\r
3717 given association MUST NOT change during the lifetime of an
\r
3718 association. A new Verification Tag value MUST be used each time the
\r
3719 endpoint tears-down and then re-establishes an association to the
\r
3722 6. User Data Transfer
\r
3724 Data transmission MUST only happen in the ESTABLISHED, SHUTDOWN-
\r
3725 PENDING, and SHUTDOWN-RECEIVED states. The only exception to this is
\r
3726 that DATA chunks are allowed to be bundled with an outbound COOKIE
\r
3727 ECHO chunk when in COOKIE-WAIT state.
\r
3729 DATA chunks MUST only be received according to the rules below in
\r
3730 ESTABLISHED, SHUTDOWN-PENDING, SHUTDOWN-SENT. A DATA chunk received
\r
3731 in CLOSED is out of the blue and SHOULD be handled per 8.4. A DATA
\r
3732 chunk received in any other state SHOULD be discarded.
\r
3734 A SACK MUST be processed in ESTABLISHED, SHUTDOWN-PENDING, and
\r
3735 SHUTDOWN-RECEIVED. An incoming SACK MAY be processed in COOKIE-
\r
3736 ECHOED. A SACK in the CLOSED state is out of the blue and SHOULD be
\r
3737 processed according to the rules in 8.4. A SACK chunk received in
\r
3738 any other state SHOULD be discarded.
\r
3741 A SCTP receiver MUST be able to receive a minimum of 1500 bytes in
\r
3742 one SCTP packet. This means that a SCTP endpoint MUST NOT indicate
\r
3743 less than 1500 bytes in its Initial a_rwnd sent in the INIT or INIT
\r
3746 For transmission efficiency, SCTP defines mechanisms for bundling of
\r
3747 small user messages and fragmentation of large user messages. The
\r
3748 following diagram depicts the flow of user messages through SCTP.
\r
3754 Stewart, et al. Standards Track [Page 67]
\r
3756 RFC 2960 Stream Control Transmission Protocol October 2000
\r
3759 In this section the term "data sender" refers to the endpoint that
\r
3760 transmits a DATA chunk and the term "data receiver" refers to the
\r
3761 endpoint that receives a DATA chunk. A data receiver will transmit
\r
3764 +--------------------------+
\r
3766 +--------------------------+
\r
3768 ==================|==|=======================================
\r
3770 +------------------+ +--------------------+
\r
3771 | SCTP DATA Chunks | |SCTP Control Chunks |
\r
3772 +------------------+ +--------------------+
\r
3775 +--------------------------+
\r
3777 +--------------------------+
\r
3779 ===========================|==|===========================
\r
3781 Connectionless Packet Transfer Service (e.g., IP)
\r
3785 1) When converting user messages into DATA chunks, an endpoint
\r
3786 will fragment user messages larger than the current association
\r
3787 path MTU into multiple DATA chunks. The data receiver will
\r
3788 normally reassemble the fragmented message from DATA chunks
\r
3789 before delivery to the user (see Section 6.9 for details).
\r
3791 2) Multiple DATA and control chunks may be bundled by the sender
\r
3792 into a single SCTP packet for transmission, as long as the
\r
3793 final size of the packet does not exceed the current path MTU.
\r
3794 The receiver will unbundle the packet back into the original
\r
3795 chunks. Control chunks MUST come before DATA chunks in the
\r
3798 Figure 6: Illustration of User Data Transfer
\r
3800 The fragmentation and bundling mechanisms, as detailed in Sections
\r
3801 6.9 and 6.10, are OPTIONAL to implement by the data sender, but they
\r
3802 MUST be implemented by the data receiver, i.e., an endpoint MUST
\r
3803 properly receive and process bundled or fragmented data.
\r
3810 Stewart, et al. Standards Track [Page 68]
\r
3812 RFC 2960 Stream Control Transmission Protocol October 2000
\r
3815 6.1 Transmission of DATA Chunks
\r
3817 This document is specified as if there is a single retransmission
\r
3818 timer per destination transport address, but implementations MAY have
\r
3819 a retransmission timer for each DATA chunk.
\r
3821 The following general rules MUST be applied by the data sender for
\r
3822 transmission and/or retransmission of outbound DATA chunks:
\r
3824 A) At any given time, the data sender MUST NOT transmit new data to
\r
3825 any destination transport address if its peer's rwnd indicates
\r
3826 that the peer has no buffer space (i.e. rwnd is 0, see Section
\r
3827 6.2.1). However, regardless of the value of rwnd (including if it
\r
3828 is 0), the data sender can always have one DATA chunk in flight to
\r
3829 the receiver if allowed by cwnd (see rule B below). This rule
\r
3830 allows the sender to probe for a change in rwnd that the sender
\r
3831 missed due to the SACK having been lost in transit from the data
\r
3832 receiver to the data sender.
\r
3834 B) At any given time, the sender MUST NOT transmit new data to a
\r
3835 given transport address if it has cwnd or more bytes of data
\r
3836 outstanding to that transport address.
\r
3838 C) When the time comes for the sender to transmit, before sending new
\r
3839 DATA chunks, the sender MUST first transmit any outstanding DATA
\r
3840 chunks which are marked for retransmission (limited by the current
\r
3843 D) Then, the sender can send out as many new DATA chunks as Rule A
\r
3844 and Rule B above allow.
\r
3846 Multiple DATA chunks committed for transmission MAY be bundled in a
\r
3847 single packet. Furthermore, DATA chunks being retransmitted MAY be
\r
3848 bundled with new DATA chunks, as long as the resulting packet size
\r
3849 does not exceed the path MTU. A ULP may request that no bundling is
\r
3850 performed but this should only turn off any delays that a SCTP
\r
3851 implementation may be using to increase bundling efficiency. It does
\r
3852 not in itself stop all bundling from occurring (i.e. in case of
\r
3853 congestion or retransmission).
\r
3855 Before an endpoint transmits a DATA chunk, if any received DATA
\r
3856 chunks have not been acknowledged (e.g., due to delayed ack), the
\r
3857 sender should create a SACK and bundle it with the outbound DATA
\r
3858 chunk, as long as the size of the final SCTP packet does not exceed
\r
3859 the current MTU. See Section 6.2.
\r
3866 Stewart, et al. Standards Track [Page 69]
\r
3868 RFC 2960 Stream Control Transmission Protocol October 2000
\r
3871 IMPLEMENTATION NOTE: When the window is full (i.e., transmission is
\r
3872 disallowed by Rule A and/or Rule B), the sender MAY still accept send
\r
3873 requests from its upper layer, but MUST transmit no more DATA chunks
\r
3874 until some or all of the outstanding DATA chunks are acknowledged and
\r
3875 transmission is allowed by Rule A and Rule B again.
\r
3877 Whenever a transmission or retransmission is made to any address, if
\r
3878 the T3-rtx timer of that address is not currently running, the sender
\r
3879 MUST start that timer. If the timer for that address is already
\r
3880 running, the sender MUST restart the timer if the earliest (i.e.,
\r
3881 lowest TSN) outstanding DATA chunk sent to that address is being
\r
3882 retransmitted. Otherwise, the data sender MUST NOT restart the
\r
3885 When starting or restarting the T3-rtx timer, the timer value must be
\r
3886 adjusted according to the timer rules defined in Sections 6.3.2, and
\r
3889 Note: The data sender SHOULD NOT use a TSN that is more than 2**31 -
\r
3890 1 above the beginning TSN of the current send window.
\r
3892 6.2 Acknowledgement on Reception of DATA Chunks
\r
3894 The SCTP endpoint MUST always acknowledge the reception of each valid
\r
3897 The guidelines on delayed acknowledgement algorithm specified in
\r
3898 Section 4.2 of [RFC2581] SHOULD be followed. Specifically, an
\r
3899 acknowledgement SHOULD be generated for at least every second packet
\r
3900 (not every second DATA chunk) received, and SHOULD be generated
\r
3901 within 200 ms of the arrival of any unacknowledged DATA chunk. In
\r
3902 some situations it may be beneficial for an SCTP transmitter to be
\r
3903 more conservative than the algorithms detailed in this document
\r
3904 allow. However, an SCTP transmitter MUST NOT be more aggressive than
\r
3905 the following algorithms allow.
\r
3907 A SCTP receiver MUST NOT generate more than one SACK for every
\r
3908 incoming packet, other than to update the offered window as the
\r
3909 receiving application consumes new data.
\r
3911 IMPLEMENTATION NOTE: The maximum delay for generating an
\r
3912 acknowledgement may be configured by the SCTP administrator, either
\r
3913 statically or dynamically, in order to meet the specific timing
\r
3914 requirement of the protocol being carried.
\r
3916 An implementation MUST NOT allow the maximum delay to be configured
\r
3917 to be more than 500 ms. In other words an implementation MAY lower
\r
3918 this value below 500ms but MUST NOT raise it above 500ms.
\r
3922 Stewart, et al. Standards Track [Page 70]
\r
3924 RFC 2960 Stream Control Transmission Protocol October 2000
\r
3927 Acknowledgements MUST be sent in SACK chunks unless shutdown was
\r
3928 requested by the ULP in which case an endpoint MAY send an
\r
3929 acknowledgement in the SHUTDOWN chunk. A SACK chunk can acknowledge
\r
3930 the reception of multiple DATA chunks. See Section 3.3.4 for SACK
\r
3931 chunk format. In particular, the SCTP endpoint MUST fill in the
\r
3932 Cumulative TSN Ack field to indicate the latest sequential TSN (of a
\r
3933 valid DATA chunk) it has received. Any received DATA chunks with TSN
\r
3934 greater than the value in the Cumulative TSN Ack field SHOULD also be
\r
3935 reported in the Gap Ack Block fields.
\r
3937 Note: The SHUTDOWN chunk does not contain Gap Ack Block fields.
\r
3938 Therefore, the endpoint should use a SACK instead of the SHUTDOWN
\r
3939 chunk to acknowledge DATA chunks received out of order .
\r
3941 When a packet arrives with duplicate DATA chunk(s) and with no new
\r
3942 DATA chunk(s), the endpoint MUST immediately send a SACK with no
\r
3943 delay. If a packet arrives with duplicate DATA chunk(s) bundled with
\r
3944 new DATA chunks, the endpoint MAY immediately send a SACK. Normally
\r
3945 receipt of duplicate DATA chunks will occur when the original SACK
\r
3946 chunk was lost and the peer's RTO has expired. The duplicate TSN
\r
3947 number(s) SHOULD be reported in the SACK as duplicate.
\r
3949 When an endpoint receives a SACK, it MAY use the Duplicate TSN
\r
3950 information to determine if SACK loss is occurring. Further use of
\r
3951 this data is for future study.
\r
3953 The data receiver is responsible for maintaining its receive buffers.
\r
3954 The data receiver SHOULD notify the data sender in a timely manner of
\r
3955 changes in its ability to receive data. How an implementation
\r
3956 manages its receive buffers is dependent on many factors (e.g.,
\r
3957 Operating System, memory management system, amount of memory, etc.).
\r
3958 However, the data sender strategy defined in Section 6.2.1 is based
\r
3959 on the assumption of receiver operation similar to the following:
\r
3961 A) At initialization of the association, the endpoint tells the
\r
3962 peer how much receive buffer space it has allocated to the
\r
3963 association in the INIT or INIT ACK. The endpoint sets a_rwnd
\r
3966 B) As DATA chunks are received and buffered, decrement a_rwnd by
\r
3967 the number of bytes received and buffered. This is, in effect,
\r
3968 closing rwnd at the data sender and restricting the amount of
\r
3969 data it can transmit.
\r
3971 C) As DATA chunks are delivered to the ULP and released from the
\r
3972 receive buffers, increment a_rwnd by the number of bytes
\r
3973 delivered to the upper layer. This is, in effect, opening up
\r
3974 rwnd on the data sender and allowing it to send more data. The
\r
3978 Stewart, et al. Standards Track [Page 71]
\r
3980 RFC 2960 Stream Control Transmission Protocol October 2000
\r
3983 data receiver SHOULD NOT increment a_rwnd unless it has
\r
3984 released bytes from its receive buffer. For example, if the
\r
3985 receiver is holding fragmented DATA chunks in a reassembly
\r
3986 queue, it should not increment a_rwnd.
\r
3988 D) When sending a SACK, the data receiver SHOULD place the current
\r
3989 value of a_rwnd into the a_rwnd field. The data receiver
\r
3990 SHOULD take into account that the data sender will not
\r
3991 retransmit DATA chunks that are acked via the Cumulative TSN
\r
3992 Ack (i.e., will drop from its retransmit queue).
\r
3994 Under certain circumstances, the data receiver may need to drop DATA
\r
3995 chunks that it has received but hasn't released from its receive
\r
3996 buffers (i.e., delivered to the ULP). These DATA chunks may have
\r
3997 been acked in Gap Ack Blocks. For example, the data receiver may be
\r
3998 holding data in its receive buffers while reassembling a fragmented
\r
3999 user message from its peer when it runs out of receive buffer space.
\r
4000 It may drop these DATA chunks even though it has acknowledged them in
\r
4001 Gap Ack Blocks. If a data receiver drops DATA chunks, it MUST NOT
\r
4002 include them in Gap Ack Blocks in subsequent SACKs until they are
\r
4003 received again via retransmission. In addition, the endpoint should
\r
4004 take into account the dropped data when calculating its a_rwnd.
\r
4006 An endpoint SHOULD NOT revoke a SACK and discard data. Only in
\r
4007 extreme circumstance should an endpoint use this procedure (such as
\r
4008 out of buffer space). The data receiver should take into account
\r
4009 that dropping data that has been acked in Gap Ack Blocks can result
\r
4010 in suboptimal retransmission strategies in the data sender and thus
\r
4011 in suboptimal performance.
\r
4013 The following example illustrates the use of delayed
\r
4034 Stewart, et al. Standards Track [Page 72]
\r
4036 RFC 2960 Stream Control Transmission Protocol October 2000
\r
4039 Endpoint A Endpoint Z
\r
4041 {App sends 3 messages; strm 0}
\r
4042 DATA [TSN=7,Strm=0,Seq=3] ------------> (ack delayed)
\r
4043 (Start T3-rtx timer)
\r
4045 DATA [TSN=8,Strm=0,Seq=4] ------------> (send ack)
\r
4046 /------- SACK [TSN Ack=8,block=0]
\r
4047 (cancel T3-rtx timer) <-----/
\r
4049 DATA [TSN=9,Strm=0,Seq=5] ------------> (ack delayed)
\r
4050 (Start T3-rtx timer)
\r
4052 {App sends 1 message; strm 1}
\r
4053 (bundle SACK with DATA)
\r
4054 /----- SACK [TSN Ack=9,block=0] \
\r
4055 / DATA [TSN=6,Strm=1,Seq=2]
\r
4056 (cancel T3-rtx timer) <------/ (Start T3-rtx timer)
\r
4060 SACK [TSN Ack=6,block=0] -------------> (cancel T3-rtx timer)
\r
4062 Figure 7: Delayed Acknowledgment Example
\r
4064 If an endpoint receives a DATA chunk with no user data (i.e., the
\r
4065 Length field is set to 16) it MUST send an ABORT with error cause set
\r
4066 to "No User Data".
\r
4068 An endpoint SHOULD NOT send a DATA chunk with no user data part.
\r
4070 6.2.1 Processing a Received SACK
\r
4072 Each SACK an endpoint receives contains an a_rwnd value. This value
\r
4073 represents the amount of buffer space the data receiver, at the time
\r
4074 of transmitting the SACK, has left of its total receive buffer space
\r
4075 (as specified in the INIT/INIT ACK). Using a_rwnd, Cumulative TSN
\r
4076 Ack and Gap Ack Blocks, the data sender can develop a representation
\r
4077 of the peer's receive buffer space.
\r
4079 One of the problems the data sender must take into account when
\r
4080 processing a SACK is that a SACK can be received out of order. That
\r
4081 is, a SACK sent by the data receiver can pass an earlier SACK and be
\r
4082 received first by the data sender. If a SACK is received out of
\r
4083 order, the data sender can develop an incorrect view of the peer's
\r
4084 receive buffer space.
\r
4090 Stewart, et al. Standards Track [Page 73]
\r
4092 RFC 2960 Stream Control Transmission Protocol October 2000
\r
4095 Since there is no explicit identifier that can be used to detect
\r
4096 out-of-order SACKs, the data sender must use heuristics to determine
\r
4099 An endpoint SHOULD use the following rules to calculate the rwnd,
\r
4100 using the a_rwnd value, the Cumulative TSN Ack and Gap Ack Blocks in
\r
4103 A) At the establishment of the association, the endpoint initializes
\r
4104 the rwnd to the Advertised Receiver Window Credit (a_rwnd) the
\r
4105 peer specified in the INIT or INIT ACK.
\r
4107 B) Any time a DATA chunk is transmitted (or retransmitted) to a peer,
\r
4108 the endpoint subtracts the data size of the chunk from the rwnd of
\r
4111 C) Any time a DATA chunk is marked for retransmission (via either
\r
4112 T3-rtx timer expiration (Section 6.3.3)or via fast retransmit
\r
4113 (Section 7.2.4)), add the data size of those chunks to the rwnd.
\r
4115 Note: If the implementation is maintaining a timer on each DATA
\r
4116 chunk then only DATA chunks whose timer expired would be marked
\r
4117 for retransmission.
\r
4119 D) Any time a SACK arrives, the endpoint performs the following:
\r
4121 i) If Cumulative TSN Ack is less than the Cumulative TSN Ack
\r
4122 Point, then drop the SACK. Since Cumulative TSN Ack is
\r
4123 monotonically increasing, a SACK whose Cumulative TSN Ack is
\r
4124 less than the Cumulative TSN Ack Point indicates an out-of-
\r
4127 ii) Set rwnd equal to the newly received a_rwnd minus the
\r
4128 number of bytes still outstanding after processing the
\r
4129 Cumulative TSN Ack and the Gap Ack Blocks.
\r
4131 iii) If the SACK is missing a TSN that was previously
\r
4132 acknowledged via a Gap Ack Block (e.g., the data receiver
\r
4133 reneged on the data), then mark the corresponding DATA chunk as
\r
4134 available for retransmit: Mark it as missing for fast
\r
4135 retransmit as described in Section 7.2.4 and if no retransmit
\r
4136 timer is running for the destination address to which the DATA
\r
4137 chunk was originally transmitted, then T3-rtx is started for
\r
4138 that destination address.
\r
4146 Stewart, et al. Standards Track [Page 74]
\r
4148 RFC 2960 Stream Control Transmission Protocol October 2000
\r
4151 6.3 Management of Retransmission Timer
\r
4153 An SCTP endpoint uses a retransmission timer T3-rtx to ensure data
\r
4154 delivery in the absence of any feedback from its peer. The duration
\r
4155 of this timer is referred to as RTO (retransmission timeout).
\r
4157 When an endpoint's peer is multi-homed, the endpoint will calculate a
\r
4158 separate RTO for each different destination transport address of its
\r
4161 The computation and management of RTO in SCTP follows closely how TCP
\r
4162 manages its retransmission timer. To compute the current RTO, an
\r
4163 endpoint maintains two state variables per destination transport
\r
4164 address: SRTT (smoothed round-trip time) and RTTVAR (round-trip time
\r
4167 6.3.1 RTO Calculation
\r
4169 The rules governing the computation of SRTT, RTTVAR, and RTO are as
\r
4172 C1) Until an RTT measurement has been made for a packet sent to the
\r
4173 given destination transport address, set RTO to the protocol
\r
4174 parameter 'RTO.Initial'.
\r
4176 C2) When the first RTT measurement R is made, set SRTT <- R, RTTVAR
\r
4177 <- R/2, and RTO <- SRTT + 4 * RTTVAR.
\r
4179 C3) When a new RTT measurement R' is made, set
\r
4181 RTTVAR <- (1 - RTO.Beta) * RTTVAR + RTO.Beta * |SRTT - R'| SRTT
\r
4182 <- (1 - RTO.Alpha) * SRTT + RTO.Alpha * R'
\r
4184 Note: The value of SRTT used in the update to RTTVAR is its value
\r
4185 before updating SRTT itself using the second assignment.
\r
4187 After the computation, update RTO <- SRTT + 4 * RTTVAR.
\r
4189 C4) When data is in flight and when allowed by rule C5 below, a new
\r
4190 RTT measurement MUST be made each round trip. Furthermore, new
\r
4191 RTT measurements SHOULD be made no more than once per round-trip
\r
4192 for a given destination transport address. There are two reasons
\r
4193 for this recommendation: First, it appears that measuring more
\r
4194 frequently often does not in practice yield any significant
\r
4195 benefit [ALLMAN99]; second, if measurements are made more often,
\r
4196 then the values of RTO.Alpha and RTO.Beta in rule C3 above should
\r
4197 be adjusted so that SRTT and RTTVAR still adjust to changes at
\r
4198 roughly the same rate (in terms of how many round trips it takes
\r
4202 Stewart, et al. Standards Track [Page 75]
\r
4204 RFC 2960 Stream Control Transmission Protocol October 2000
\r
4207 them to reflect new values) as they would if making only one
\r
4208 measurement per round-trip and using RTO.Alpha and RTO.Beta as
\r
4209 given in rule C3. However, the exact nature of these adjustments
\r
4210 remains a research issue.
\r
4212 C5) Karn's algorithm: RTT measurements MUST NOT be made using packets
\r
4213 that were retransmitted (and thus for which it is ambiguous
\r
4214 whether the reply was for the first instance of the packet or a
\r
4217 C6) Whenever RTO is computed, if it is less than RTO.Min seconds then
\r
4218 it is rounded up to RTO.Min seconds. The reason for this rule is
\r
4219 that RTOs that do not have a high minimum value are susceptible
\r
4220 to unnecessary timeouts [ALLMAN99].
\r
4222 C7) A maximum value may be placed on RTO provided it is at least
\r
4225 There is no requirement for the clock granularity G used for
\r
4226 computing RTT measurements and the different state variables, other
\r
4229 G1) Whenever RTTVAR is computed, if RTTVAR = 0, then adjust RTTVAR <-
\r
4232 Experience [ALLMAN99] has shown that finer clock granularities (<=
\r
4233 100 msec) perform somewhat better than more coarse granularities.
\r
4235 6.3.2 Retransmission Timer Rules
\r
4237 The rules for managing the retransmission timer are as follows:
\r
4239 R1) Every time a DATA chunk is sent to any address (including a
\r
4240 retransmission), if the T3-rtx timer of that address is not
\r
4241 running, start it running so that it will expire after the RTO of
\r
4242 that address. The RTO used here is that obtained after any
\r
4243 doubling due to previous T3-rtx timer expirations on the
\r
4244 corresponding destination address as discussed in rule E2 below.
\r
4246 R2) Whenever all outstanding data sent to an address have been
\r
4247 acknowledged, turn off the T3-rtx timer of that address.
\r
4249 R3) Whenever a SACK is received that acknowledges the DATA chunk with
\r
4250 the earliest outstanding TSN for that address, restart T3-rtx
\r
4251 timer for that address with its current RTO (if there is still
\r
4252 outstanding data on that address).
\r
4258 Stewart, et al. Standards Track [Page 76]
\r
4260 RFC 2960 Stream Control Transmission Protocol October 2000
\r
4263 R4) Whenever a SACK is received missing a TSN that was previously
\r
4264 acknowledged via a Gap Ack Block, start T3-rtx for the
\r
4265 destination address to which the DATA chunk was originally
\r
4266 transmitted if it is not already running.
\r
4268 The following example shows the use of various timer rules (assuming
\r
4269 the receiver uses delayed acks).
\r
4271 Endpoint A Endpoint Z
\r
4272 {App begins to send}
\r
4273 Data [TSN=7,Strm=0,Seq=3] ------------> (ack delayed)
\r
4274 (Start T3-rtx timer)
\r
4275 {App sends 1 message; strm 1}
\r
4276 (bundle ack with data)
\r
4277 DATA [TSN=8,Strm=0,Seq=4] ----\ /-- SACK [TSN Ack=7,Block=0]
\r
4278 \ / DATA [TSN=6,Strm=1,Seq=2]
\r
4279 \ / (Start T3-rtx timer)
\r
4282 (Re-start T3-rtx timer) <------/ \--> (ack delayed)
\r
4285 SACK [TSN Ack=6,Block=0] --------------> (Cancel T3-rtx timer)
\r
4288 (Cancel T3-rtx timer) <-------------- SACK [TSN Ack=8,Block=0]
\r
4290 Figure 8 - Timer Rule Examples
\r
4292 6.3.3 Handle T3-rtx Expiration
\r
4294 Whenever the retransmission timer T3-rtx expires for a destination
\r
4295 address, do the following:
\r
4297 E1) For the destination address for which the timer expires, adjust
\r
4298 its ssthresh with rules defined in Section 7.2.3 and set the cwnd
\r
4301 E2) For the destination address for which the timer expires, set RTO
\r
4302 <- RTO * 2 ("back off the timer"). The maximum value discussed
\r
4303 in rule C7 above (RTO.max) may be used to provide an upper bound
\r
4304 to this doubling operation.
\r
4306 E3) Determine how many of the earliest (i.e., lowest TSN) outstanding
\r
4307 DATA chunks for the address for which the T3-rtx has expired will
\r
4308 fit into a single packet, subject to the MTU constraint for the
\r
4309 path corresponding to the destination transport address to which
\r
4310 the retransmission is being sent (this may be different from the
\r
4314 Stewart, et al. Standards Track [Page 77]
\r
4316 RFC 2960 Stream Control Transmission Protocol October 2000
\r
4319 address for which the timer expires [see Section 6.4]). Call
\r
4320 this value K. Bundle and retransmit those K DATA chunks in a
\r
4321 single packet to the destination endpoint.
\r
4323 E4) Start the retransmission timer T3-rtx on the destination address
\r
4324 to which the retransmission is sent, if rule R1 above indicates
\r
4325 to do so. The RTO to be used for starting T3-rtx should be the
\r
4326 one for the destination address to which the retransmission is
\r
4327 sent, which, when the receiver is multi-homed, may be different
\r
4328 from the destination address for which the timer expired (see
\r
4329 Section 6.4 below).
\r
4331 After retransmitting, once a new RTT measurement is obtained (which
\r
4332 can happen only when new data has been sent and acknowledged, per
\r
4333 rule C5, or for a measurement made from a HEARTBEAT [see Section
\r
4334 8.3]), the computation in rule C3 is performed, including the
\r
4335 computation of RTO, which may result in "collapsing" RTO back down
\r
4336 after it has been subject to doubling (rule E2).
\r
4338 Note: Any DATA chunks that were sent to the address for which the
\r
4339 T3-rtx timer expired but did not fit in one MTU (rule E3 above),
\r
4340 should be marked for retransmission and sent as soon as cwnd allows
\r
4341 (normally when a SACK arrives).
\r
4343 The final rule for managing the retransmission timer concerns
\r
4344 failover (see Section 6.4.1):
\r
4346 F1) Whenever an endpoint switches from the current destination
\r
4347 transport address to a different one, the current retransmission
\r
4348 timers are left running. As soon as the endpoint transmits a
\r
4349 packet containing DATA chunk(s) to the new transport address,
\r
4350 start the timer on that transport address, using the RTO value of
\r
4351 the destination address to which the data is being sent, if rule
\r
4352 R1 indicates to do so.
\r
4354 6.4 Multi-homed SCTP Endpoints
\r
4356 An SCTP endpoint is considered multi-homed if there are more than one
\r
4357 transport address that can be used as a destination address to reach
\r
4360 Moreover, the ULP of an endpoint shall select one of the multiple
\r
4361 destination addresses of a multi-homed peer endpoint as the primary
\r
4362 path (see Sections 5.1.2 and 10.1 for details).
\r
4364 By default, an endpoint SHOULD always transmit to the primary path,
\r
4365 unless the SCTP user explicitly specifies the destination transport
\r
4366 address (and possibly source transport address) to use.
\r
4370 Stewart, et al. Standards Track [Page 78]
\r
4372 RFC 2960 Stream Control Transmission Protocol October 2000
\r
4375 An endpoint SHOULD transmit reply chunks (e.g., SACK, HEARTBEAT ACK,
\r
4376 etc.) to the same destination transport address from which it
\r
4377 received the DATA or control chunk to which it is replying. This
\r
4378 rule should also be followed if the endpoint is bundling DATA chunks
\r
4379 together with the reply chunk.
\r
4381 However, when acknowledging multiple DATA chunks received in packets
\r
4382 from different source addresses in a single SACK, the SACK chunk may
\r
4383 be transmitted to one of the destination transport addresses from
\r
4384 which the DATA or control chunks being acknowledged were received.
\r
4386 When a receiver of a duplicate DATA chunk sends a SACK to a multi-
\r
4387 homed endpoint it MAY be beneficial to vary the destination address
\r
4388 and not use the source address of the DATA chunk. The reason being
\r
4389 that receiving a duplicate from a multi-homed endpoint might indicate
\r
4390 that the return path (as specified in the source address of the DATA
\r
4391 chunk) for the SACK is broken.
\r
4393 Furthermore, when its peer is multi-homed, an endpoint SHOULD try to
\r
4394 retransmit a chunk to an active destination transport address that is
\r
4395 different from the last destination address to which the DATA chunk
\r
4398 Retransmissions do not affect the total outstanding data count.
\r
4399 However, if the DATA chunk is retransmitted onto a different
\r
4400 destination address, both the outstanding data counts on the new
\r
4401 destination address and the old destination address to which the data
\r
4402 chunk was last sent shall be adjusted accordingly.
\r
4404 6.4.1 Failover from Inactive Destination Address
\r
4406 Some of the transport addresses of a multi-homed SCTP endpoint may
\r
4407 become inactive due to either the occurrence of certain error
\r
4408 conditions (see Section 8.2) or adjustments from SCTP user.
\r
4410 When there is outbound data to send and the primary path becomes
\r
4411 inactive (e.g., due to failures), or where the SCTP user explicitly
\r
4412 requests to send data to an inactive destination transport address,
\r
4413 before reporting an error to its ULP, the SCTP endpoint should try to
\r
4414 send the data to an alternate active destination transport address if
\r
4417 When retransmitting data, if the endpoint is multi-homed, it should
\r
4418 consider each source-destination address pair in its retransmission
\r
4419 selection policy. When retransmitting the endpoint should attempt to
\r
4420 pick the most divergent source-destination pair from the original
\r
4421 source-destination pair to which the packet was transmitted.
\r
4426 Stewart, et al. Standards Track [Page 79]
\r
4428 RFC 2960 Stream Control Transmission Protocol October 2000
\r
4431 Note: Rules for picking the most divergent source-destination pair
\r
4432 are an implementation decision and is not specified within this
\r
4435 6.5 Stream Identifier and Stream Sequence Number
\r
4437 Every DATA chunk MUST carry a valid stream identifier. If an
\r
4438 endpoint receives a DATA chunk with an invalid stream identifier, it
\r
4439 shall acknowledge the reception of the DATA chunk following the
\r
4440 normal procedure, immediately send an ERROR chunk with cause set to
\r
4441 "Invalid Stream Identifier" (see Section 3.3.10) and discard the DATA
\r
4442 chunk. The endpoint may bundle the ERROR chunk in the same packet as
\r
4443 the SACK as long as the ERROR follows the SACK.
\r
4445 The stream sequence number in all the streams shall start from 0 when
\r
4446 the association is established. Also, when the stream sequence
\r
4447 number reaches the value 65535 the next stream sequence number shall
\r
4450 6.6 Ordered and Unordered Delivery
\r
4452 Within a stream, an endpoint MUST deliver DATA chunks received with
\r
4453 the U flag set to 0 to the upper layer according to the order of
\r
4454 their stream sequence number. If DATA chunks arrive out of order of
\r
4455 their stream sequence number, the endpoint MUST hold the received
\r
4456 DATA chunks from delivery to the ULP until they are re-ordered.
\r
4458 However, an SCTP endpoint can indicate that no ordered delivery is
\r
4459 required for a particular DATA chunk transmitted within the stream by
\r
4460 setting the U flag of the DATA chunk to 1.
\r
4462 When an endpoint receives a DATA chunk with the U flag set to 1, it
\r
4463 must bypass the ordering mechanism and immediately deliver the data
\r
4464 to the upper layer (after re-assembly if the user data is fragmented
\r
4465 by the data sender).
\r
4467 This provides an effective way of transmitting "out-of-band" data in
\r
4468 a given stream. Also, a stream can be used as an "unordered" stream
\r
4469 by simply setting the U flag to 1 in all DATA chunks sent through
\r
4472 IMPLEMENTATION NOTE: When sending an unordered DATA chunk, an
\r
4473 implementation may choose to place the DATA chunk in an outbound
\r
4474 packet that is at the head of the outbound transmission queue if
\r
4482 Stewart, et al. Standards Track [Page 80]
\r
4484 RFC 2960 Stream Control Transmission Protocol October 2000
\r
4487 The 'Stream Sequence Number' field in a DATA chunk with U flag set to
\r
4488 1 has no significance. The sender can fill it with arbitrary value,
\r
4489 but the receiver MUST ignore the field.
\r
4491 Note: When transmitting ordered and unordered data, an endpoint does
\r
4492 not increment its Stream Sequence Number when transmitting a DATA
\r
4493 chunk with U flag set to 1.
\r
4495 6.7 Report Gaps in Received DATA TSNs
\r
4497 Upon the reception of a new DATA chunk, an endpoint shall examine the
\r
4498 continuity of the TSNs received. If the endpoint detects a gap in
\r
4499 the received DATA chunk sequence, it SHOULD send a SACK with Gap Ack
\r
4500 Blocks immediately. The data receiver continues sending a SACK after
\r
4501 receipt of each SCTP packet that doesn't fill the gap.
\r
4503 Based on the Gap Ack Block from the received SACK, the endpoint can
\r
4504 calculate the missing DATA chunks and make decisions on whether to
\r
4505 retransmit them (see Section 6.2.1 for details).
\r
4507 Multiple gaps can be reported in one single SACK (see Section 3.3.4).
\r
4509 When its peer is multi-homed, the SCTP endpoint SHOULD always try to
\r
4510 send the SACK to the same destination address from which the last
\r
4511 DATA chunk was received.
\r
4513 Upon the reception of a SACK, the endpoint MUST remove all DATA
\r
4514 chunks which have been acknowledged by the SACK's Cumulative TSN Ack
\r
4515 from its transmit queue. The endpoint MUST also treat all the DATA
\r
4516 chunks with TSNs not included in the Gap Ack Blocks reported by the
\r
4517 SACK as "missing". The number of "missing" reports for each
\r
4518 outstanding DATA chunk MUST be recorded by the data sender in order
\r
4519 to make retransmission decisions. See Section 7.2.4 for details.
\r
4521 The following example shows the use of SACK to report a gap.
\r
4538 Stewart, et al. Standards Track [Page 81]
\r
4540 RFC 2960 Stream Control Transmission Protocol October 2000
\r
4543 Endpoint A Endpoint Z
\r
4544 {App sends 3 messages; strm 0}
\r
4545 DATA [TSN=6,Strm=0,Seq=2] ---------------> (ack delayed)
\r
4546 (Start T3-rtx timer)
\r
4548 DATA [TSN=7,Strm=0,Seq=3] --------> X (lost)
\r
4550 DATA [TSN=8,Strm=0,Seq=4] ---------------> (gap detected,
\r
4551 immediately send ack)
\r
4552 /----- SACK [TSN Ack=6,Block=1,
\r
4555 (remove 6 from out-queue,
\r
4556 and mark 7 as "1" missing report)
\r
4558 Figure 9 - Reporting a Gap using SACK
\r
4560 The maximum number of Gap Ack Blocks that can be reported within a
\r
4561 single SACK chunk is limited by the current path MTU. When a single
\r
4562 SACK can not cover all the Gap Ack Blocks needed to be reported due
\r
4563 to the MTU limitation, the endpoint MUST send only one SACK,
\r
4564 reporting the Gap Ack Blocks from the lowest to highest TSNs, within
\r
4565 the size limit set by the MTU, and leave the remaining highest TSN
\r
4566 numbers unacknowledged.
\r
4568 6.8 Adler-32 Checksum Calculation
\r
4570 When sending an SCTP packet, the endpoint MUST strengthen the data
\r
4571 integrity of the transmission by including the Adler-32 checksum
\r
4572 value calculated on the packet, as described below.
\r
4574 After the packet is constructed (containing the SCTP common header
\r
4575 and one or more control or DATA chunks), the transmitter shall:
\r
4577 1) Fill in the proper Verification Tag in the SCTP common header and
\r
4578 initialize the checksum field to 0's.
\r
4580 2) Calculate the Adler-32 checksum of the whole packet, including the
\r
4581 SCTP common header and all the chunks. Refer to appendix B for
\r
4582 details of the Adler-32 algorithm. And,
\r
4584 3) Put the resultant value into the checksum field in the common
\r
4585 header, and leave the rest of the bits unchanged.
\r
4587 When an SCTP packet is received, the receiver MUST first check the
\r
4588 Adler-32 checksum:
\r
4590 1) Store the received Adler-32 checksum value aside,
\r
4594 Stewart, et al. Standards Track [Page 82]
\r
4596 RFC 2960 Stream Control Transmission Protocol October 2000
\r
4599 2) Replace the 32 bits of the checksum field in the received SCTP
\r
4600 packet with all '0's and calculate an Adler-32 checksum value of
\r
4601 the whole received packet. And,
\r
4603 3) Verify that the calculated Adler-32 checksum is the same as the
\r
4604 received Adler-32 checksum. If not, the receiver MUST treat the
\r
4605 packet as an invalid SCTP packet.
\r
4607 The default procedure for handling invalid SCTP packets is to
\r
4608 silently discard them.
\r
4610 6.9 Fragmentation and Reassembly
\r
4612 An endpoint MAY support fragmentation when sending DATA chunks, but
\r
4613 MUST support reassembly when receiving DATA chunks. If an endpoint
\r
4614 supports fragmentation, it MUST fragment a user message if the size
\r
4615 of the user message to be sent causes the outbound SCTP packet size
\r
4616 to exceed the current MTU. If an implementation does not support
\r
4617 fragmentation of outbound user messages, the endpoint must return an
\r
4618 error to its upper layer and not attempt to send the user message.
\r
4620 IMPLEMENTATION NOTE: In this error case, the Send primitive
\r
4621 discussed in Section 10.1 would need to return an error to the upper
\r
4624 If its peer is multi-homed, the endpoint shall choose a size no
\r
4625 larger than the association Path MTU. The association Path MTU is
\r
4626 the smallest Path MTU of all destination addresses.
\r
4628 Note: Once a message is fragmented it cannot be re-fragmented.
\r
4629 Instead if the PMTU has been reduced, then IP fragmentation must be
\r
4630 used. Please see Section 7.3 for details of PMTU discovery.
\r
4632 When determining when to fragment, the SCTP implementation MUST take
\r
4633 into account the SCTP packet header as well as the DATA chunk
\r
4634 header(s). The implementation MUST also take into account the space
\r
4635 required for a SACK chunk if bundling a SACK chunk with the DATA
\r
4638 Fragmentation takes the following steps:
\r
4640 1) The data sender MUST break the user message into a series of DATA
\r
4641 chunks such that each chunk plus SCTP overhead fits into an IP
\r
4642 datagram smaller than or equal to the association Path MTU.
\r
4644 2) The transmitter MUST then assign, in sequence, a separate TSN to
\r
4645 each of the DATA chunks in the series. The transmitter assigns
\r
4646 the same SSN to each of the DATA chunks. If the user indicates
\r
4650 Stewart, et al. Standards Track [Page 83]
\r
4652 RFC 2960 Stream Control Transmission Protocol October 2000
\r
4655 that the user message is to be delivered using unordered delivery,
\r
4656 then the U flag of each DATA chunk of the user message MUST be set
\r
4659 3) The transmitter MUST also set the B/E bits of the first DATA chunk
\r
4660 in the series to '10', the B/E bits of the last DATA chunk in the
\r
4661 series to '01', and the B/E bits of all other DATA chunks in the
\r
4664 An endpoint MUST recognize fragmented DATA chunks by examining the
\r
4665 B/E bits in each of the received DATA chunks, and queue the
\r
4666 fragmented DATA chunks for re-assembly. Once the user message is
\r
4667 reassembled, SCTP shall pass the re-assembled user message to the
\r
4668 specific stream for possible re-ordering and final dispatching.
\r
4670 Note: If the data receiver runs out of buffer space while still
\r
4671 waiting for more fragments to complete the re-assembly of the
\r
4672 message, it should dispatch part of its inbound message through a
\r
4673 partial delivery API (see Section 10), freeing some of its receive
\r
4674 buffer space so that the rest of the message may be received.
\r
4678 An endpoint bundles chunks by simply including multiple chunks in one
\r
4679 outbound SCTP packet. The total size of the resultant IP datagram,
\r
4680 including the SCTP packet and IP headers, MUST be less or equal to
\r
4681 the current Path MTU.
\r
4683 If its peer endpoint is multi-homed, the sending endpoint shall
\r
4684 choose a size no larger than the latest MTU of the current primary
\r
4687 When bundling control chunks with DATA chunks, an endpoint MUST place
\r
4688 control chunks first in the outbound SCTP packet. The transmitter
\r
4689 MUST transmit DATA chunks within a SCTP packet in increasing order of
\r
4692 Note: Since control chunks must be placed first in a packet and
\r
4693 since DATA chunks must be transmitted before SHUTDOWN or SHUTDOWN ACK
\r
4694 chunks, DATA chunks cannot be bundled with SHUTDOWN or SHUTDOWN ACK
\r
4697 Partial chunks MUST NOT be placed in an SCTP packet.
\r
4706 Stewart, et al. Standards Track [Page 84]
\r
4708 RFC 2960 Stream Control Transmission Protocol October 2000
\r
4711 An endpoint MUST process received chunks in their order in the
\r
4712 packet. The receiver uses the chunk length field to determine the end
\r
4713 of a chunk and beginning of the next chunk taking account of the fact
\r
4714 that all chunks end on a 4 byte boundary. If the receiver detects a
\r
4715 partial chunk, it MUST drop the chunk.
\r
4717 An endpoint MUST NOT bundle INIT, INIT ACK or SHUTDOWN COMPLETE with
\r
4720 7. Congestion control
\r
4722 Congestion control is one of the basic functions in SCTP. For some
\r
4723 applications, it may be likely that adequate resources will be
\r
4724 allocated to SCTP traffic to assure prompt delivery of time-critical
\r
4725 data - thus it would appear to be unlikely, during normal operations,
\r
4726 that transmissions encounter severe congestion conditions. However
\r
4727 SCTP must operate under adverse operational conditions, which can
\r
4728 develop upon partial network failures or unexpected traffic surges.
\r
4729 In such situations SCTP must follow correct congestion control steps
\r
4730 to recover from congestion quickly in order to get data delivered as
\r
4731 soon as possible. In the absence of network congestion, these
\r
4732 preventive congestion control algorithms should show no impact on the
\r
4733 protocol performance.
\r
4735 IMPLEMENTATION NOTE: As far as its specific performance requirements
\r
4736 are met, an implementation is always allowed to adopt a more
\r
4737 conservative congestion control algorithm than the one defined below.
\r
4739 The congestion control algorithms used by SCTP are based on
\r
4740 [RFC2581]. This section describes how the algorithms defined in
\r
4741 RFC2581 are adapted for use in SCTP. We first list differences in
\r
4742 protocol designs between TCP and SCTP, and then describe SCTP's
\r
4743 congestion control scheme. The description will use the same
\r
4744 terminology as in TCP congestion control whenever appropriate.
\r
4746 SCTP congestion control is always applied to the entire association,
\r
4747 and not to individual streams.
\r
4749 7.1 SCTP Differences from TCP Congestion control
\r
4751 Gap Ack Blocks in the SCTP SACK carry the same semantic meaning as
\r
4752 the TCP SACK. TCP considers the information carried in the SACK as
\r
4753 advisory information only. SCTP considers the information carried in
\r
4754 the Gap Ack Blocks in the SACK chunk as advisory. In SCTP, any DATA
\r
4755 chunk that has been acknowledged by SACK, including DATA that arrived
\r
4756 at the receiving end out of order, are not considered fully delivered
\r
4757 until the Cumulative TSN Ack Point passes the TSN of the DATA chunk
\r
4758 (i.e., the DATA chunk has been acknowledged by the Cumulative TSN Ack
\r
4762 Stewart, et al. Standards Track [Page 85]
\r
4764 RFC 2960 Stream Control Transmission Protocol October 2000
\r
4767 field in the SACK). Consequently, the value of cwnd controls the
\r
4768 amount of outstanding data, rather than (as in the case of non-SACK
\r
4769 TCP) the upper bound between the highest acknowledged sequence number
\r
4770 and the latest DATA chunk that can be sent within the congestion
\r
4771 window. SCTP SACK leads to different implementations of fast-
\r
4772 retransmit and fast-recovery than non-SACK TCP. As an example see
\r
4775 The biggest difference between SCTP and TCP, however, is multi-
\r
4776 homing. SCTP is designed to establish robust communication
\r
4777 associations between two endpoints each of which may be reachable by
\r
4778 more than one transport address. Potentially different addresses may
\r
4779 lead to different data paths between the two endpoints, thus ideally
\r
4780 one may need a separate set of congestion control parameters for each
\r
4781 of the paths. The treatment here of congestion control for multi-
\r
4782 homed receivers is new with SCTP and may require refinement in the
\r
4783 future. The current algorithms make the following assumptions:
\r
4785 o The sender usually uses the same destination address until being
\r
4786 instructed by the upper layer otherwise; however, SCTP may change
\r
4787 to an alternate destination in the event an address is marked
\r
4788 inactive (see Section 8.2). Also, SCTP may retransmit to a
\r
4789 different transport address than the original transmission.
\r
4791 o The sender keeps a separate congestion control parameter set for
\r
4792 each of the destination addresses it can send to (not each
\r
4793 source-destination pair but for each destination). The parameters
\r
4794 should decay if the address is not used for a long enough time
\r
4797 o For each of the destination addresses, an endpoint does slow-start
\r
4798 upon the first transmission to that address.
\r
4800 Note: TCP guarantees in-sequence delivery of data to its upper-layer
\r
4801 protocol within a single TCP session. This means that when TCP
\r
4802 notices a gap in the received sequence number, it waits until the gap
\r
4803 is filled before delivering the data that was received with sequence
\r
4804 numbers higher than that of the missing data. On the other hand,
\r
4805 SCTP can deliver data to its upper-layer protocol even if there is a
\r
4806 gap in TSN if the Stream Sequence Numbers are in sequence for a
\r
4807 particular stream (i.e., the missing DATA chunks are for a different
\r
4808 stream) or if unordered delivery is indicated. Although this does
\r
4809 not affect cwnd, it might affect rwnd calculation.
\r
4818 Stewart, et al. Standards Track [Page 86]
\r
4820 RFC 2960 Stream Control Transmission Protocol October 2000
\r
4823 7.2 SCTP Slow-Start and Congestion Avoidance
\r
4825 The slow start and congestion avoidance algorithms MUST be used by an
\r
4826 endpoint to control the amount of data being injected into the
\r
4827 network. The congestion control in SCTP is employed in regard to the
\r
4828 association, not to an individual stream. In some situations it may
\r
4829 be beneficial for an SCTP sender to be more conservative than the
\r
4830 algorithms allow; however, an SCTP sender MUST NOT be more aggressive
\r
4831 than the following algorithms allow.
\r
4833 Like TCP, an SCTP endpoint uses the following three control variables
\r
4834 to regulate its transmission rate.
\r
4836 o Receiver advertised window size (rwnd, in bytes), which is set by
\r
4837 the receiver based on its available buffer space for incoming
\r
4840 Note: This variable is kept on the entire association.
\r
4842 o Congestion control window (cwnd, in bytes), which is adjusted by
\r
4843 the sender based on observed network conditions.
\r
4845 Note: This variable is maintained on a per-destination address
\r
4848 o Slow-start threshold (ssthresh, in bytes), which is used by the
\r
4849 sender to distinguish slow start and congestion avoidance phases.
\r
4851 Note: This variable is maintained on a per-destination address
\r
4854 SCTP also requires one additional control variable,
\r
4855 partial_bytes_acked, which is used during congestion avoidance phase
\r
4856 to facilitate cwnd adjustment.
\r
4858 Unlike TCP, an SCTP sender MUST keep a set of these control variables
\r
4859 cwnd, ssthresh and partial_bytes_acked for EACH destination address
\r
4860 of its peer (when its peer is multi-homed). Only one rwnd is kept
\r
4861 for the whole association (no matter if the peer is multi-homed or
\r
4862 has a single address).
\r
4866 Beginning data transmission into a network with unknown conditions or
\r
4867 after a sufficiently long idle period requires SCTP to probe the
\r
4868 network to determine the available capacity. The slow start
\r
4869 algorithm is used for this purpose at the beginning of a transfer, or
\r
4870 after repairing loss detected by the retransmission timer.
\r
4874 Stewart, et al. Standards Track [Page 87]
\r
4876 RFC 2960 Stream Control Transmission Protocol October 2000
\r
4879 o The initial cwnd before DATA transmission or after a sufficiently
\r
4880 long idle period MUST be <= 2*MTU.
\r
4882 o The initial cwnd after a retransmission timeout MUST be no more
\r
4885 o The initial value of ssthresh MAY be arbitrarily high (for
\r
4886 example, implementations MAY use the size of the receiver
\r
4887 advertised window).
\r
4889 o Whenever cwnd is greater than zero, the endpoint is allowed to
\r
4890 have cwnd bytes of data outstanding on that transport address.
\r
4892 o When cwnd is less than or equal to ssthresh an SCTP endpoint MUST
\r
4893 use the slow start algorithm to increase cwnd (assuming the
\r
4894 current congestion window is being fully utilized). If an
\r
4895 incoming SACK advances the Cumulative TSN Ack Point, cwnd MUST be
\r
4896 increased by at most the lesser of 1) the total size of the
\r
4897 previously outstanding DATA chunk(s) acknowledged, and 2) the
\r
4898 destination's path MTU. This protects against the ACK-Splitting
\r
4899 attack outlined in [SAVAGE99].
\r
4901 In instances where its peer endpoint is multi-homed, if an endpoint
\r
4902 receives a SACK that advances its Cumulative TSN Ack Point, then it
\r
4903 should update its cwnd (or cwnds) apportioned to the destination
\r
4904 addresses to which it transmitted the acknowledged data. However if
\r
4905 the received SACK does not advance the Cumulative TSN Ack Point, the
\r
4906 endpoint MUST NOT adjust the cwnd of any of the destination
\r
4909 Because an endpoint's cwnd is not tied to its Cumulative TSN Ack
\r
4910 Point, as duplicate SACKs come in, even though they may not advance
\r
4911 the Cumulative TSN Ack Point an endpoint can still use them to clock
\r
4912 out new data. That is, the data newly acknowledged by the SACK
\r
4913 diminishes the amount of data now in flight to less than cwnd; and so
\r
4914 the current, unchanged value of cwnd now allows new data to be sent.
\r
4915 On the other hand, the increase of cwnd must be tied to the
\r
4916 Cumulative TSN Ack Point advancement as specified above. Otherwise
\r
4917 the duplicate SACKs will not only clock out new data, but also will
\r
4918 adversely clock out more new data than what has just left the
\r
4919 network, during a time of possible congestion.
\r
4921 o When the endpoint does not transmit data on a given transport
\r
4922 address, the cwnd of the transport address should be adjusted to
\r
4923 max(cwnd/2, 2*MTU) per RTO.
\r
4930 Stewart, et al. Standards Track [Page 88]
\r
4932 RFC 2960 Stream Control Transmission Protocol October 2000
\r
4935 7.2.2 Congestion Avoidance
\r
4937 When cwnd is greater than ssthresh, cwnd should be incremented by
\r
4938 1*MTU per RTT if the sender has cwnd or more bytes of data
\r
4939 outstanding for the corresponding transport address.
\r
4941 In practice an implementation can achieve this goal in the following
\r
4944 o partial_bytes_acked is initialized to 0.
\r
4946 o Whenever cwnd is greater than ssthresh, upon each SACK arrival
\r
4947 that advances the Cumulative TSN Ack Point, increase
\r
4948 partial_bytes_acked by the total number of bytes of all new chunks
\r
4949 acknowledged in that SACK including chunks acknowledged by the new
\r
4950 Cumulative TSN Ack and by Gap Ack Blocks.
\r
4952 o When partial_bytes_acked is equal to or greater than cwnd and
\r
4953 before the arrival of the SACK the sender had cwnd or more bytes
\r
4954 of data outstanding (i.e., before arrival of the SACK, flightsize
\r
4955 was greater than or equal to cwnd), increase cwnd by MTU, and
\r
4956 reset partial_bytes_acked to (partial_bytes_acked - cwnd).
\r
4958 o Same as in the slow start, when the sender does not transmit DATA
\r
4959 on a given transport address, the cwnd of the transport address
\r
4960 should be adjusted to max(cwnd / 2, 2*MTU) per RTO.
\r
4962 o When all of the data transmitted by the sender has been
\r
4963 acknowledged by the receiver, partial_bytes_acked is initialized
\r
4966 7.2.3 Congestion Control
\r
4968 Upon detection of packet losses from SACK (see Section 7.2.4), An
\r
4969 endpoint should do the following:
\r
4971 ssthresh = max(cwnd/2, 2*MTU)
\r
4974 Basically, a packet loss causes cwnd to be cut in half.
\r
4976 When the T3-rtx timer expires on an address, SCTP should perform slow
\r
4979 ssthresh = max(cwnd/2, 2*MTU)
\r
4986 Stewart, et al. Standards Track [Page 89]
\r
4988 RFC 2960 Stream Control Transmission Protocol October 2000
\r
4991 and assure that no more than one SCTP packet will be in flight for
\r
4992 that address until the endpoint receives acknowledgement for
\r
4993 successful delivery of data to that address.
\r
4995 7.2.4 Fast Retransmit on Gap Reports
\r
4997 In the absence of data loss, an endpoint performs delayed
\r
4998 acknowledgement. However, whenever an endpoint notices a hole in the
\r
4999 arriving TSN sequence, it SHOULD start sending a SACK back every time
\r
5000 a packet arrives carrying data until the hole is filled.
\r
5002 Whenever an endpoint receives a SACK that indicates some TSN(s)
\r
5003 missing, it SHOULD wait for 3 further miss indications (via
\r
5004 subsequent SACK's) on the same TSN(s) before taking action with
\r
5005 regard to Fast Retransmit.
\r
5007 When the TSN(s) is reported as missing in the fourth consecutive
\r
5008 SACK, the data sender shall:
\r
5010 1) Mark the missing DATA chunk(s) for retransmission,
\r
5012 2) Adjust the ssthresh and cwnd of the destination address(es) to
\r
5013 which the missing DATA chunks were last sent, according to the
\r
5014 formula described in Section 7.2.3.
\r
5016 3) Determine how many of the earliest (i.e., lowest TSN) DATA chunks
\r
5017 marked for retransmission will fit into a single packet, subject
\r
5018 to constraint of the path MTU of the destination transport address
\r
5019 to which the packet is being sent. Call this value K. Retransmit
\r
5020 those K DATA chunks in a single packet.
\r
5022 4) Restart T3-rtx timer only if the last SACK acknowledged the lowest
\r
5023 outstanding TSN number sent to that address, or the endpoint is
\r
5024 retransmitting the first outstanding DATA chunk sent to that
\r
5027 Note: Before the above adjustments, if the received SACK also
\r
5028 acknowledges new DATA chunks and advances the Cumulative TSN Ack
\r
5029 Point, the cwnd adjustment rules defined in Sections 7.2.1 and 7.2.2
\r
5030 must be applied first.
\r
5032 A straightforward implementation of the above keeps a counter for
\r
5033 each TSN hole reported by a SACK. The counter increments for each
\r
5034 consecutive SACK reporting the TSN hole. After reaching 4 and
\r
5035 starting the fast retransmit procedure, the counter resets to 0.
\r
5042 Stewart, et al. Standards Track [Page 90]
\r
5044 RFC 2960 Stream Control Transmission Protocol October 2000
\r
5047 Because cwnd in SCTP indirectly bounds the number of outstanding
\r
5048 TSN's, the effect of TCP fast-recovery is achieved automatically with
\r
5049 no adjustment to the congestion control window size.
\r
5051 7.3 Path MTU Discovery
\r
5053 [RFC1191] specifies "Path MTU Discovery", whereby an endpoint
\r
5054 maintains an estimate of the maximum transmission unit (MTU) along a
\r
5055 given Internet path and refrains from sending packets along that path
\r
5056 which exceed the MTU, other than occasional attempts to probe for a
\r
5057 change in the Path MTU (PMTU). RFC 1191 is thorough in its
\r
5058 discussion of the MTU discovery mechanism and strategies for
\r
5059 determining the current end-to-end MTU setting as well as detecting
\r
5060 changes in this value. [RFC1981] specifies the same mechanisms for
\r
5061 IPv6. An SCTP sender using IPv6 MUST use Path MTU Discovery unless
\r
5062 all packets are less than the minimum IPv6 MTU [RFC2460].
\r
5064 An endpoint SHOULD apply these techniques, and SHOULD do so on a
\r
5065 per-destination-address basis.
\r
5067 There are 4 ways in which SCTP differs from the description in RFC
\r
5068 1191 of applying MTU discovery to TCP:
\r
5070 1) SCTP associations can span multiple addresses. An endpoint MUST
\r
5071 maintain separate MTU estimates for each destination address of
\r
5074 2) Elsewhere in this document, when the term "MTU" is discussed, it
\r
5075 refers to the MTU associated with the destination address
\r
5076 corresponding to the context of the discussion.
\r
5078 3) Unlike TCP, SCTP does not have a notion of "Maximum Segment Size".
\r
5079 Accordingly, the MTU for each destination address SHOULD be
\r
5080 initialized to a value no larger than the link MTU for the local
\r
5081 interface to which packets for that remote destination address
\r
5084 4) Since data transmission in SCTP is naturally structured in terms
\r
5085 of TSNs rather than bytes (as is the case for TCP), the discussion
\r
5086 in Section 6.5 of RFC 1191 applies: When retransmitting an IP
\r
5087 datagram to a remote address for which the IP datagram appears too
\r
5088 large for the path MTU to that address, the IP datagram SHOULD be
\r
5089 retransmitted without the DF bit set, allowing it to possibly be
\r
5090 fragmented. Transmissions of new IP datagrams MUST have DF set.
\r
5098 Stewart, et al. Standards Track [Page 91]
\r
5100 RFC 2960 Stream Control Transmission Protocol October 2000
\r
5103 5) The sender should track an association PMTU which will be the
\r
5104 smallest PMTU discovered for all of the peer's destination
\r
5105 addresses. When fragmenting messages into multiple parts this
\r
5106 association PMTU should be used to calculate the size of each
\r
5107 fragment. This will allow retransmissions to be seamlessly sent
\r
5108 to an alternate address without encountering IP fragmentation.
\r
5110 Other than these differences, the discussion of TCP's use of MTU
\r
5111 discovery in RFCs 1191 and 1981 applies to SCTP on a per-
\r
5112 destination-address basis.
\r
5114 Note: For IPv6 destination addresses the DF bit does not exist,
\r
5115 instead the IP datagram must be fragmented as described in [RFC2460].
\r
5117 8. Fault Management
\r
5119 8.1 Endpoint Failure Detection
\r
5121 An endpoint shall keep a counter on the total number of consecutive
\r
5122 retransmissions to its peer (including retransmissions to all the
\r
5123 destination transport addresses of the peer if it is multi-homed).
\r
5124 If the value of this counter exceeds the limit indicated in the
\r
5125 protocol parameter 'Association.Max.Retrans', the endpoint shall
\r
5126 consider the peer endpoint unreachable and shall stop transmitting
\r
5127 any more data to it (and thus the association enters the CLOSED
\r
5128 state). In addition, the endpoint shall report the failure to the
\r
5129 upper layer, and optionally report back all outstanding user data
\r
5130 remaining in its outbound queue. The association is automatically
\r
5131 closed when the peer endpoint becomes unreachable.
\r
5133 The counter shall be reset each time a DATA chunk sent to that peer
\r
5134 endpoint is acknowledged (by the reception of a SACK), or a
\r
5135 HEARTBEAT-ACK is received from the peer endpoint.
\r
5137 8.2 Path Failure Detection
\r
5139 When its peer endpoint is multi-homed, an endpoint should keep a
\r
5140 error counter for each of the destination transport addresses of the
\r
5143 Each time the T3-rtx timer expires on any address, or when a
\r
5144 HEARTBEAT sent to an idle address is not acknowledged within a RTO,
\r
5145 the error counter of that destination address will be incremented.
\r
5146 When the value in the error counter exceeds the protocol parameter
\r
5147 'Path.Max.Retrans' of that destination address, the endpoint should
\r
5148 mark the destination transport address as inactive, and a
\r
5149 notification SHOULD be sent to the upper layer.
\r
5154 Stewart, et al. Standards Track [Page 92]
\r
5156 RFC 2960 Stream Control Transmission Protocol October 2000
\r
5159 When an outstanding TSN is acknowledged or a HEARTBEAT sent to that
\r
5160 address is acknowledged with a HEARTBEAT ACK, the endpoint shall
\r
5161 clear the error counter of the destination transport address to which
\r
5162 the DATA chunk was last sent (or HEARTBEAT was sent). When the peer
\r
5163 endpoint is multi-homed and the last chunk sent to it was a
\r
5164 retransmission to an alternate address, there exists an ambiguity as
\r
5165 to whether or not the acknowledgement should be credited to the
\r
5166 address of the last chunk sent. However, this ambiguity does not
\r
5167 seem to bear any significant consequence to SCTP behavior. If this
\r
5168 ambiguity is undesirable, the transmitter may choose not to clear the
\r
5169 error counter if the last chunk sent was a retransmission.
\r
5171 Note: When configuring the SCTP endpoint, the user should avoid
\r
5172 having the value of 'Association.Max.Retrans' larger than the
\r
5173 summation of the 'Path.Max.Retrans' of all the destination addresses
\r
5174 for the remote endpoint. Otherwise, all the destination addresses
\r
5175 may become inactive while the endpoint still considers the peer
\r
5176 endpoint reachable. When this condition occurs, how the SCTP chooses
\r
5177 to function is implementation specific.
\r
5179 When the primary path is marked inactive (due to excessive
\r
5180 retransmissions, for instance), the sender MAY automatically transmit
\r
5181 new packets to an alternate destination address if one exists and is
\r
5182 active. If more than one alternate address is active when the
\r
5183 primary path is marked inactive only ONE transport address SHOULD be
\r
5184 chosen and used as the new destination transport address.
\r
5186 8.3 Path Heartbeat
\r
5188 By default, an SCTP endpoint shall monitor the reachability of the
\r
5189 idle destination transport address(es) of its peer by sending a
\r
5190 HEARTBEAT chunk periodically to the destination transport
\r
5193 A destination transport address is considered "idle" if no new chunk
\r
5194 which can be used for updating path RTT (usually including first
\r
5195 transmission DATA, INIT, COOKIE ECHO, HEARTBEAT etc.) and no
\r
5196 HEARTBEAT has been sent to it within the current heartbeat period of
\r
5197 that address. This applies to both active and inactive destination
\r
5200 The upper layer can optionally initiate the following functions:
\r
5202 A) Disable heartbeat on a specific destination transport address of a
\r
5203 given association,
\r
5205 B) Change the HB.interval,
\r
5210 Stewart, et al. Standards Track [Page 93]
\r
5212 RFC 2960 Stream Control Transmission Protocol October 2000
\r
5215 C) Re-enable heartbeat on a specific destination transport address of
\r
5216 a given association, and,
\r
5218 D) Request an on-demand HEARTBEAT on a specific destination transport
\r
5219 address of a given association.
\r
5221 The endpoint should increment the respective error counter of the
\r
5222 destination transport address each time a HEARTBEAT is sent to that
\r
5223 address and not acknowledged within one RTO.
\r
5225 When the value of this counter reaches the protocol parameter '
\r
5226 Path.Max.Retrans', the endpoint should mark the corresponding
\r
5227 destination address as inactive if it is not so marked, and may also
\r
5228 optionally report to the upper layer the change of reachability of
\r
5229 this destination address. After this, the endpoint should continue
\r
5230 HEARTBEAT on this destination address but should stop increasing the
\r
5233 The sender of the HEARTBEAT chunk should include in the Heartbeat
\r
5234 Information field of the chunk the current time when the packet is
\r
5235 sent out and the destination address to which the packet is sent.
\r
5237 IMPLEMENTATION NOTE: An alternative implementation of the heartbeat
\r
5238 mechanism that can be used is to increment the error counter variable
\r
5239 every time a HEARTBEAT is sent to a destination. Whenever a
\r
5240 HEARTBEAT ACK arrives, the sender SHOULD clear the error counter of
\r
5241 the destination that the HEARTBEAT was sent to. This in effect would
\r
5242 clear the previously stroked error (and any other error counts as
\r
5245 The receiver of the HEARTBEAT should immediately respond with a
\r
5246 HEARTBEAT ACK that contains the Heartbeat Information field copied
\r
5247 from the received HEARTBEAT chunk.
\r
5249 Upon the receipt of the HEARTBEAT ACK, the sender of the HEARTBEAT
\r
5250 should clear the error counter of the destination transport address
\r
5251 to which the HEARTBEAT was sent, and mark the destination transport
\r
5252 address as active if it is not so marked. The endpoint may
\r
5253 optionally report to the upper layer when an inactive destination
\r
5254 address is marked as active due to the reception of the latest
\r
5255 HEARTBEAT ACK. The receiver of the HEARTBEAT ACK must also clear the
\r
5256 association overall error count as well (as defined in section 8.1).
\r
5258 The receiver of the HEARTBEAT ACK should also perform an RTT
\r
5259 measurement for that destination transport address using the time
\r
5260 value carried in the HEARTBEAT ACK chunk.
\r
5266 Stewart, et al. Standards Track [Page 94]
\r
5268 RFC 2960 Stream Control Transmission Protocol October 2000
\r
5271 On an idle destination address that is allowed to heartbeat, a
\r
5272 HEARTBEAT chunk is RECOMMENDED to be sent once per RTO of that
\r
5273 destination address plus the protocol parameter 'HB.interval' , with
\r
5274 jittering of +/- 50%, and exponential back-off of the RTO if the
\r
5275 previous HEARTBEAT is unanswered.
\r
5277 A primitive is provided for the SCTP user to change the HB.interval
\r
5278 and turn on or off the heartbeat on a given destination address. The
\r
5279 heartbeat interval set by the SCTP user is added to the RTO of that
\r
5280 destination (including any exponential backoff). Only one heartbeat
\r
5281 should be sent each time the heartbeat timer expires (if multiple
\r
5282 destinations are idle). It is a implementation decision on how to
\r
5283 choose which of the candidate idle destinations to heartbeat to (if
\r
5284 more than one destination is idle).
\r
5286 Note: When tuning the heartbeat interval, there is a side effect that
\r
5287 SHOULD be taken into account. When this value is increased, i.e.
\r
5288 the HEARTBEAT takes longer, the detection of lost ABORT messages
\r
5289 takes longer as well. If a peer endpoint ABORTs the association for
\r
5290 any reason and the ABORT chunk is lost, the local endpoint will only
\r
5291 discover the lost ABORT by sending a DATA chunk or HEARTBEAT chunk
\r
5292 (thus causing the peer to send another ABORT). This must be
\r
5293 considered when tuning the HEARTBEAT timer. If the HEARTBEAT is
\r
5294 disabled only sending DATA to the association will discover a lost
\r
5295 ABORT from the peer.
\r
5297 8.4 Handle "Out of the blue" Packets
\r
5299 An SCTP packet is called an "out of the blue" (OOTB) packet if it is
\r
5300 correctly formed, i.e., passed the receiver's Adler-32 check (see
\r
5301 Section 6.8), but the receiver is not able to identify the
\r
5302 association to which this packet belongs.
\r
5304 The receiver of an OOTB packet MUST do the following:
\r
5306 1) If the OOTB packet is to or from a non-unicast address, silently
\r
5307 discard the packet. Otherwise,
\r
5309 2) If the OOTB packet contains an ABORT chunk, the receiver MUST
\r
5310 silently discard the OOTB packet and take no further action.
\r
5313 3) If the packet contains an INIT chunk with a Verification Tag set
\r
5314 to '0', process it as described in Section 5.1. Otherwise,
\r
5316 4) If the packet contains a COOKIE ECHO in the first chunk, process
\r
5317 it as described in Section 5.1. Otherwise,
\r
5322 Stewart, et al. Standards Track [Page 95]
\r
5324 RFC 2960 Stream Control Transmission Protocol October 2000
\r
5327 5) If the packet contains a SHUTDOWN ACK chunk, the receiver should
\r
5328 respond to the sender of the OOTB packet with a SHUTDOWN COMPLETE.
\r
5329 When sending the SHUTDOWN COMPLETE, the receiver of the OOTB
\r
5330 packet must fill in the Verification Tag field of the outbound
\r
5331 packet with the Verification Tag received in the SHUTDOWN ACK and
\r
5332 set the T-bit in the Chunk Flags to indicate that no TCB was
\r
5335 6) If the packet contains a SHUTDOWN COMPLETE chunk, the receiver
\r
5336 should silently discard the packet and take no further action.
\r
5339 7) If the packet contains a "Stale cookie" ERROR or a COOKIE ACK the
\r
5340 SCTP Packet should be silently discarded. Otherwise,
\r
5342 8) The receiver should respond to the sender of the OOTB packet with
\r
5343 an ABORT. When sending the ABORT, the receiver of the OOTB packet
\r
5344 MUST fill in the Verification Tag field of the outbound packet
\r
5345 with the value found in the Verification Tag field of the OOTB
\r
5346 packet and set the T-bit in the Chunk Flags to indicate that no
\r
5347 TCB was found. After sending this ABORT, the receiver of the OOTB
\r
5348 packet shall discard the OOTB packet and take no further action.
\r
5350 8.5 Verification Tag
\r
5352 The Verification Tag rules defined in this section apply when sending
\r
5353 or receiving SCTP packets which do not contain an INIT, SHUTDOWN
\r
5354 COMPLETE, COOKIE ECHO (see Section 5.1), ABORT or SHUTDOWN ACK chunk.
\r
5355 The rules for sending and receiving SCTP packets containing one of
\r
5356 these chunk types are discussed separately in Section 8.5.1.
\r
5358 When sending an SCTP packet, the endpoint MUST fill in the
\r
5359 Verification Tag field of the outbound packet with the tag value in
\r
5360 the Initiate Tag parameter of the INIT or INIT ACK received from its
\r
5363 When receiving an SCTP packet, the endpoint MUST ensure that the
\r
5364 value in the Verification Tag field of the received SCTP packet
\r
5365 matches its own Tag. If the received Verification Tag value does not
\r
5366 match the receiver's own tag value, the receiver shall silently
\r
5367 discard the packet and shall not process it any further except for
\r
5368 those cases listed in Section 8.5.1 below.
\r
5378 Stewart, et al. Standards Track [Page 96]
\r
5380 RFC 2960 Stream Control Transmission Protocol October 2000
\r
5383 8.5.1 Exceptions in Verification Tag Rules
\r
5385 A) Rules for packet carrying INIT:
\r
5387 - The sender MUST set the Verification Tag of the packet to 0.
\r
5389 - When an endpoint receives an SCTP packet with the Verification
\r
5390 Tag set to 0, it should verify that the packet contains only an
\r
5391 INIT chunk. Otherwise, the receiver MUST silently discard the
\r
5394 B) Rules for packet carrying ABORT:
\r
5396 - The endpoint shall always fill in the Verification Tag field of
\r
5397 the outbound packet with the destination endpoint's tag value
\r
5400 - If the ABORT is sent in response to an OOTB packet, the
\r
5401 endpoint MUST follow the procedure described in Section 8.4.
\r
5403 - The receiver MUST accept the packet if the Verification Tag
\r
5404 matches either its own tag, OR the tag of its peer. Otherwise,
\r
5405 the receiver MUST silently discard the packet and take no
\r
5408 C) Rules for packet carrying SHUTDOWN COMPLETE:
\r
5410 - When sending a SHUTDOWN COMPLETE, if the receiver of the
\r
5411 SHUTDOWN ACK has a TCB then the destination endpoint's tag MUST
\r
5412 be used. Only where no TCB exists should the sender use the
\r
5413 Verification Tag from the SHUTDOWN ACK.
\r
5415 - The receiver of a SHUTDOWN COMPLETE shall accept the packet if
\r
5416 the Verification Tag field of the packet matches its own tag OR
\r
5417 it is set to its peer's tag and the T bit is set in the Chunk
\r
5418 Flags. Otherwise, the receiver MUST silently discard the packet
\r
5419 and take no further action. An endpoint MUST ignore the
\r
5420 SHUTDOWN COMPLETE if it is not in the SHUTDOWN-ACK-SENT state.
\r
5422 D) Rules for packet carrying a COOKIE ECHO
\r
5424 - When sending a COOKIE ECHO, the endpoint MUST use the value of
\r
5425 the Initial Tag received in the INIT ACK.
\r
5427 - The receiver of a COOKIE ECHO follows the procedures in Section
\r
5434 Stewart, et al. Standards Track [Page 97]
\r
5436 RFC 2960 Stream Control Transmission Protocol October 2000
\r
5439 E) Rules for packet carrying a SHUTDOWN ACK
\r
5441 - If the receiver is in COOKIE-ECHOED or COOKIE-WAIT state the
\r
5442 procedures in section 8.4 SHOULD be followed, in other words it
\r
5443 should be treated as an Out Of The Blue packet.
\r
5445 9. Termination of Association
\r
5447 An endpoint should terminate its association when it exits from
\r
5448 service. An association can be terminated by either abort or
\r
5449 shutdown. An abort of an association is abortive by definition in
\r
5450 that any data pending on either end of the association is discarded
\r
5451 and not delivered to the peer. A shutdown of an association is
\r
5452 considered a graceful close where all data in queue by either
\r
5453 endpoint is delivered to the respective peers. However, in the case
\r
5454 of a shutdown, SCTP does not support a half-open state (like TCP)
\r
5455 wherein one side may continue sending data while the other end is
\r
5456 closed. When either endpoint performs a shutdown, the association on
\r
5457 each peer will stop accepting new data from its user and only deliver
\r
5458 data in queue at the time of sending or receiving the SHUTDOWN chunk.
\r
5460 9.1 Abort of an Association
\r
5462 When an endpoint decides to abort an existing association, it shall
\r
5463 send an ABORT chunk to its peer endpoint. The sender MUST fill in
\r
5464 the peer's Verification Tag in the outbound packet and MUST NOT
\r
5465 bundle any DATA chunk with the ABORT.
\r
5467 An endpoint MUST NOT respond to any received packet that contains an
\r
5468 ABORT chunk (also see Section 8.4).
\r
5470 An endpoint receiving an ABORT shall apply the special Verification
\r
5471 Tag check rules described in Section 8.5.1.
\r
5473 After checking the Verification Tag, the receiving endpoint shall
\r
5474 remove the association from its record, and shall report the
\r
5475 termination to its upper layer.
\r
5477 9.2 Shutdown of an Association
\r
5479 Using the SHUTDOWN primitive (see Section 10.1), the upper layer of
\r
5480 an endpoint in an association can gracefully close the association.
\r
5481 This will allow all outstanding DATA chunks from the peer of the
\r
5482 shutdown initiator to be delivered before the association terminates.
\r
5484 Upon receipt of the SHUTDOWN primitive from its upper layer, the
\r
5485 endpoint enters SHUTDOWN-PENDING state and remains there until all
\r
5486 outstanding data has been acknowledged by its peer. The endpoint
\r
5490 Stewart, et al. Standards Track [Page 98]
\r
5492 RFC 2960 Stream Control Transmission Protocol October 2000
\r
5495 accepts no new data from its upper layer, but retransmits data to the
\r
5496 far end if necessary to fill gaps.
\r
5498 Once all its outstanding data has been acknowledged, the endpoint
\r
5499 shall send a SHUTDOWN chunk to its peer including in the Cumulative
\r
5500 TSN Ack field the last sequential TSN it has received from the peer.
\r
5501 It shall then start the T2-shutdown timer and enter the SHUTDOWN-SENT
\r
5502 state. If the timer expires, the endpoint must re-send the SHUTDOWN
\r
5503 with the updated last sequential TSN received from its peer.
\r
5505 The rules in Section 6.3 MUST be followed to determine the proper
\r
5506 timer value for T2-shutdown. To indicate any gaps in TSN, the
\r
5507 endpoint may also bundle a SACK with the SHUTDOWN chunk in the same
\r
5510 An endpoint should limit the number of retransmissions of the
\r
5511 SHUTDOWN chunk to the protocol parameter 'Association.Max.Retrans'.
\r
5512 If this threshold is exceeded the endpoint should destroy the TCB and
\r
5513 MUST report the peer endpoint unreachable to the upper layer (and
\r
5514 thus the association enters the CLOSED state). The reception of any
\r
5515 packet from its peer (i.e. as the peer sends all of its queued DATA
\r
5516 chunks) should clear the endpoint's retransmission count and restart
\r
5517 the T2-Shutdown timer, giving its peer ample opportunity to transmit
\r
5518 all of its queued DATA chunks that have not yet been sent.
\r
5520 Upon the reception of the SHUTDOWN, the peer endpoint shall
\r
5522 - enter the SHUTDOWN-RECEIVED state,
\r
5524 - stop accepting new data from its SCTP user
\r
5526 - verify, by checking the Cumulative TSN Ack field of the chunk,
\r
5527 that all its outstanding DATA chunks have been received by the
\r
5530 Once an endpoint as reached the SHUTDOWN-RECEIVED state it MUST NOT
\r
5531 send a SHUTDOWN in response to a ULP request, and should discard
\r
5532 subsequent SHUTDOWN chunks.
\r
5534 If there are still outstanding DATA chunks left, the SHUTDOWN
\r
5535 receiver shall continue to follow normal data transmission procedures
\r
5536 defined in Section 6 until all outstanding DATA chunks are
\r
5537 acknowledged; however, the SHUTDOWN receiver MUST NOT accept new data
\r
5538 from its SCTP user.
\r
5540 While in SHUTDOWN-SENT state, the SHUTDOWN sender MUST immediately
\r
5541 respond to each received packet containing one or more DATA chunk(s)
\r
5542 with a SACK, a SHUTDOWN chunk, and restart the T2-shutdown timer. If
\r
5546 Stewart, et al. Standards Track [Page 99]
\r
5548 RFC 2960 Stream Control Transmission Protocol October 2000
\r
5551 it has no more outstanding DATA chunks, the SHUTDOWN receiver shall
\r
5552 send a SHUTDOWN ACK and start a T2-shutdown timer of its own,
\r
5553 entering the SHUTDOWN-ACK-SENT state. If the timer expires, the
\r
5554 endpoint must re-send the SHUTDOWN ACK.
\r
5556 The sender of the SHUTDOWN ACK should limit the number of
\r
5557 retransmissions of the SHUTDOWN ACK chunk to the protocol parameter '
\r
5558 Association.Max.Retrans'. If this threshold is exceeded the endpoint
\r
5559 should destroy the TCB and may report the peer endpoint unreachable
\r
5560 to the upper layer (and thus the association enters the CLOSED
\r
5563 Upon the receipt of the SHUTDOWN ACK, the SHUTDOWN sender shall stop
\r
5564 the T2-shutdown timer, send a SHUTDOWN COMPLETE chunk to its peer,
\r
5565 and remove all record of the association.
\r
5567 Upon reception of the SHUTDOWN COMPLETE chunk the endpoint will
\r
5568 verify that it is in SHUTDOWN-ACK-SENT state, if it is not the chunk
\r
5569 should be discarded. If the endpoint is in the SHUTDOWN-ACK-SENT
\r
5570 state the endpoint should stop the T2-shutdown timer and remove all
\r
5571 knowledge of the association (and thus the association enters the
\r
5574 An endpoint SHOULD assure that all its outstanding DATA chunks have
\r
5575 been acknowledged before initiating the shutdown procedure.
\r
5577 An endpoint should reject any new data request from its upper layer
\r
5578 if it is in SHUTDOWN-PENDING, SHUTDOWN-SENT, SHUTDOWN-RECEIVED, or
\r
5579 SHUTDOWN-ACK-SENT state.
\r
5581 If an endpoint is in SHUTDOWN-ACK-SENT state and receives an INIT
\r
5582 chunk (e.g., if the SHUTDOWN COMPLETE was lost) with source and
\r
5583 destination transport addresses (either in the IP addresses or in the
\r
5584 INIT chunk) that belong to this association, it should discard the
\r
5585 INIT chunk and retransmit the SHUTDOWN ACK chunk.
\r
5587 Note: Receipt of an INIT with the same source and destination IP
\r
5588 addresses as used in transport addresses assigned to an endpoint but
\r
5589 with a different port number indicates the initialization of a
\r
5590 separate association.
\r
5592 The sender of the INIT or COOKIE ECHO should respond to the receipt
\r
5593 of a SHUTDOWN-ACK with a stand-alone SHUTDOWN COMPLETE in an SCTP
\r
5594 packet with the Verification Tag field of its common header set to
\r
5595 the same tag that was received in the SHUTDOWN ACK packet. This is
\r
5596 considered an Out of the Blue packet as defined in Section 8.4. The
\r
5597 sender of the INIT lets T1-init continue running and remains in the
\r
5602 Stewart, et al. Standards Track [Page 100]
\r
5604 RFC 2960 Stream Control Transmission Protocol October 2000
\r
5607 COOKIE-WAIT or COOKIE-ECHOED state. Normal T1-init timer expiration
\r
5608 will cause the INIT or COOKIE chunk to be retransmitted and thus
\r
5609 start a new association.
\r
5611 If a SHUTDOWN is received in COOKIE WAIT or COOKIE ECHOED states the
\r
5612 SHUTDOWN chunk SHOULD be silently discarded.
\r
5614 If an endpoint is in SHUTDOWN-SENT state and receives a SHUTDOWN
\r
5615 chunk from its peer, the endpoint shall respond immediately with a
\r
5616 SHUTDOWN ACK to its peer, and move into a SHUTDOWN-ACK-SENT state
\r
5617 restarting its T2-shutdown timer.
\r
5619 If an endpoint is in the SHUTDOWN-ACK-SENT state and receives a
\r
5620 SHUTDOWN ACK, it shall stop the T2-shutdown timer, send a SHUTDOWN
\r
5621 COMPLETE chunk to its peer, and remove all record of the association.
\r
5623 10. Interface with Upper Layer
\r
5625 The Upper Layer Protocols (ULP) shall request for services by passing
\r
5626 primitives to SCTP and shall receive notifications from SCTP for
\r
5629 The primitives and notifications described in this section should be
\r
5630 used as a guideline for implementing SCTP. The following functional
\r
5631 description of ULP interface primitives is shown for illustrative
\r
5632 purposes. Different SCTP implementations may have different ULP
\r
5633 interfaces. However, all SCTPs must provide a certain minimum set of
\r
5634 services to guarantee that all SCTP implementations can support the
\r
5635 same protocol hierarchy.
\r
5639 The following sections functionally characterize a ULP/SCTP
\r
5640 interface. The notation used is similar to most procedure or
\r
5641 function calls in high level languages.
\r
5643 The ULP primitives described below specify the basic functions the
\r
5644 SCTP must perform to support inter-process communication. Individual
\r
5645 implementations must define their own exact format, and may provide
\r
5646 combinations or subsets of the basic functions in single calls.
\r
5650 Format: INITIALIZE ([local port], [local eligible address list]) ->
\r
5651 local SCTP instance name
\r
5658 Stewart, et al. Standards Track [Page 101]
\r
5660 RFC 2960 Stream Control Transmission Protocol October 2000
\r
5663 This primitive allows SCTP to initialize its internal data structures
\r
5664 and allocate necessary resources for setting up its operation
\r
5665 environment. Once SCTP is initialized, ULP can communicate directly
\r
5666 with other endpoints without re-invoking this primitive.
\r
5668 SCTP will return a local SCTP instance name to the ULP.
\r
5670 Mandatory attributes:
\r
5674 Optional attributes:
\r
5676 The following types of attributes may be passed along with the
\r
5679 o local port - SCTP port number, if ULP wants it to be specified;
\r
5681 o local eligible address list - An address list that the local SCTP
\r
5682 endpoint should bind. By default, if an address list is not
\r
5683 included, all IP addresses assigned to the host should be used by
\r
5684 the local endpoint.
\r
5686 IMPLEMENTATION NOTE: If this optional attribute is supported by an
\r
5687 implementation, it will be the responsibility of the implementation
\r
5688 to enforce that the IP source address field of any SCTP packets sent
\r
5689 out by this endpoint contains one of the IP addresses indicated in
\r
5690 the local eligible address list.
\r
5694 Format: ASSOCIATE(local SCTP instance name, destination transport addr,
\r
5695 outbound stream count)
\r
5696 -> association id [,destination transport addr list] [,outbound stream
\r
5699 This primitive allows the upper layer to initiate an association to a
\r
5700 specific peer endpoint.
\r
5702 The peer endpoint shall be specified by one of the transport
\r
5703 addresses which defines the endpoint (see Section 1.4). If the local
\r
5704 SCTP instance has not been initialized, the ASSOCIATE is considered
\r
5707 An association id, which is a local handle to the SCTP association,
\r
5708 will be returned on successful establishment of the association. If
\r
5709 SCTP is not able to open an SCTP association with the peer endpoint,
\r
5710 an error is returned.
\r
5714 Stewart, et al. Standards Track [Page 102]
\r
5716 RFC 2960 Stream Control Transmission Protocol October 2000
\r
5719 Other association parameters may be returned, including the complete
\r
5720 destination transport addresses of the peer as well as the outbound
\r
5721 stream count of the local endpoint. One of the transport address
\r
5722 from the returned destination addresses will be selected by the local
\r
5723 endpoint as default primary path for sending SCTP packets to this
\r
5724 peer. The returned "destination transport addr list" can be used by
\r
5725 the ULP to change the default primary path or to force sending a
\r
5726 packet to a specific transport address.
\r
5728 IMPLEMENTATION NOTE: If ASSOCIATE primitive is implemented as a
\r
5729 blocking function call, the ASSOCIATE primitive can return
\r
5730 association parameters in addition to the association id upon
\r
5731 successful establishment. If ASSOCIATE primitive is implemented as a
\r
5732 non-blocking call, only the association id shall be returned and
\r
5733 association parameters shall be passed using the COMMUNICATION UP
\r
5736 Mandatory attributes:
\r
5738 o local SCTP instance name - obtained from the INITIALIZE operation.
\r
5740 o destination transport addr - specified as one of the transport
\r
5741 addresses of the peer endpoint with which the association is to be
\r
5744 o outbound stream count - the number of outbound streams the ULP
\r
5745 would like to open towards this peer endpoint.
\r
5747 Optional attributes:
\r
5753 Format: SHUTDOWN(association id)
\r
5756 Gracefully closes an association. Any locally queued user data will
\r
5757 be delivered to the peer. The association will be terminated only
\r
5758 after the peer acknowledges all the SCTP packets sent. A success
\r
5759 code will be returned on successful termination of the association.
\r
5760 If attempting to terminate the association results in a failure, an
\r
5761 error code shall be returned.
\r
5763 Mandatory attributes:
\r
5765 o association id - local handle to the SCTP association
\r
5770 Stewart, et al. Standards Track [Page 103]
\r
5772 RFC 2960 Stream Control Transmission Protocol October 2000
\r
5775 Optional attributes:
\r
5781 Format: ABORT(association id [, cause code])
\r
5784 Ungracefully closes an association. Any locally queued user data
\r
5785 will be discarded and an ABORT chunk is sent to the peer. A success
\r
5786 code will be returned on successful abortion of the association. If
\r
5787 attempting to abort the association results in a failure, an error
\r
5788 code shall be returned.
\r
5790 Mandatory attributes:
\r
5792 o association id - local handle to the SCTP association
\r
5794 Optional attributes:
\r
5796 o cause code - reason of the abort to be passed to the peer.
\r
5802 Format: SEND(association id, buffer address, byte count [,context]
\r
5803 [,stream id] [,life time] [,destination transport address]
\r
5804 [,unorder flag] [,no-bundle flag] [,payload protocol-id] )
\r
5807 This is the main method to send user data via SCTP.
\r
5809 Mandatory attributes:
\r
5811 o association id - local handle to the SCTP association
\r
5813 o buffer address - the location where the user message to be
\r
5814 transmitted is stored;
\r
5816 o byte count - The size of the user data in number of bytes;
\r
5818 Optional attributes:
\r
5820 o context - an optional 32 bit integer that will be carried in the
\r
5821 sending failure notification to the ULP if the transportation of
\r
5822 this User Message fails.
\r
5826 Stewart, et al. Standards Track [Page 104]
\r
5828 RFC 2960 Stream Control Transmission Protocol October 2000
\r
5831 o stream id - to indicate which stream to send the data on. If not
\r
5832 specified, stream 0 will be used.
\r
5834 o life time - specifies the life time of the user data. The user
\r
5835 data will not be sent by SCTP after the life time expires. This
\r
5836 parameter can be used to avoid efforts to transmit stale user
\r
5837 messages. SCTP notifies the ULP if the data cannot be initiated
\r
5838 to transport (i.e. sent to the destination via SCTP's send
\r
5839 primitive) within the life time variable. However, the user data
\r
5840 will be transmitted if SCTP has attempted to transmit a chunk
\r
5841 before the life time expired.
\r
5843 IMPLEMENTATION NOTE: In order to better support the data lifetime
\r
5844 option, the transmitter may hold back the assigning of the TSN number
\r
5845 to an outbound DATA chunk to the last moment. And, for
\r
5846 implementation simplicity, once a TSN number has been assigned the
\r
5847 sender should consider the send of this DATA chunk as committed,
\r
5848 overriding any lifetime option attached to the DATA chunk.
\r
5850 o destination transport address - specified as one of the
\r
5851 destination transport addresses of the peer endpoint to which this
\r
5852 packet should be sent. Whenever possible, SCTP should use this
\r
5853 destination transport address for sending the packets, instead of
\r
5854 the current primary path.
\r
5856 o unorder flag - this flag, if present, indicates that the user
\r
5857 would like the data delivered in an unordered fashion to the peer
\r
5858 (i.e., the U flag is set to 1 on all DATA chunks carrying this
\r
5861 o no-bundle flag - instructs SCTP not to bundle this user data with
\r
5862 other outbound DATA chunks. SCTP MAY still bundle even when this
\r
5863 flag is present, when faced with network congestion.
\r
5865 o payload protocol-id - A 32 bit unsigned integer that is to be
\r
5866 passed to the peer indicating the type of payload protocol data
\r
5867 being transmitted. This value is passed as opaque data by SCTP.
\r
5871 Format: SETPRIMARY(association id, destination transport address,
\r
5872 [source transport address] )
\r
5875 Instructs the local SCTP to use the specified destination transport
\r
5876 address as primary path for sending packets.
\r
5882 Stewart, et al. Standards Track [Page 105]
\r
5884 RFC 2960 Stream Control Transmission Protocol October 2000
\r
5887 The result of attempting this operation shall be returned. If the
\r
5888 specified destination transport address is not present in the
\r
5889 "destination transport address list" returned earlier in an associate
\r
5890 command or communication up notification, an error shall be returned.
\r
5892 Mandatory attributes:
\r
5894 o association id - local handle to the SCTP association
\r
5896 o destination transport address - specified as one of the transport
\r
5897 addresses of the peer endpoint, which should be used as primary
\r
5898 address for sending packets. This overrides the current primary
\r
5899 address information maintained by the local SCTP endpoint.
\r
5901 Optional attributes:
\r
5903 o source transport address - optionally, some implementations may
\r
5904 allow you to set the default source address placed in all outgoing
\r
5909 Format: RECEIVE(association id, buffer address, buffer size
\r
5911 -> byte count [,transport address] [,stream id] [,stream sequence
\r
5912 number] [,partial flag] [,delivery number] [,payload protocol-id]
\r
5914 This primitive shall read the first user message in the SCTP in-queue
\r
5915 into the buffer specified by ULP, if there is one available. The
\r
5916 size of the message read, in bytes, will be returned. It may,
\r
5917 depending on the specific implementation, also return other
\r
5918 information such as the sender's address, the stream id on which it
\r
5919 is received, whether there are more messages available for retrieval,
\r
5920 etc. For ordered messages, their stream sequence number may also be
\r
5923 Depending upon the implementation, if this primitive is invoked when
\r
5924 no message is available the implementation should return an
\r
5925 indication of this condition or should block the invoking process
\r
5926 until data does become available.
\r
5928 Mandatory attributes:
\r
5930 o association id - local handle to the SCTP association
\r
5932 o buffer address - the memory location indicated by the ULP to store
\r
5933 the received message.
\r
5938 Stewart, et al. Standards Track [Page 106]
\r
5940 RFC 2960 Stream Control Transmission Protocol October 2000
\r
5943 o buffer size - the maximum size of data to be received, in bytes.
\r
5945 Optional attributes:
\r
5947 o stream id - to indicate which stream to receive the data on.
\r
5949 o stream sequence number - the stream sequence number assigned by
\r
5950 the sending SCTP peer.
\r
5952 o partial flag - if this returned flag is set to 1, then this
\r
5953 Receive contains a partial delivery of the whole message. When
\r
5954 this flag is set, the stream id and stream sequence number MUST
\r
5955 accompany this receive. When this flag is set to 0, it indicates
\r
5956 that no more deliveries will be received for this stream sequence
\r
5959 o payload protocol-id - A 32 bit unsigned integer that is received
\r
5960 from the peer indicating the type of payload protocol of the
\r
5961 received data. This value is passed as opaque data by SCTP.
\r
5965 Format: STATUS(association id)
\r
5968 This primitive should return a data block containing the following
\r
5970 association connection state,
\r
5971 destination transport address list,
\r
5972 destination transport address reachability states,
\r
5973 current receiver window size,
\r
5974 current congestion window sizes,
\r
5975 number of unacknowledged DATA chunks,
\r
5976 number of DATA chunks pending receipt,
\r
5978 most recent SRTT on primary path,
\r
5979 RTO on primary path,
\r
5980 SRTT and RTO on other destination addresses, etc.
\r
5982 Mandatory attributes:
\r
5984 o association id - local handle to the SCTP association
\r
5986 Optional attributes:
\r
5994 Stewart, et al. Standards Track [Page 107]
\r
5996 RFC 2960 Stream Control Transmission Protocol October 2000
\r
5999 I) Change Heartbeat
\r
6001 Format: CHANGEHEARTBEAT(association id, destination transport address,
\r
6002 new state [,interval])
\r
6005 Instructs the local endpoint to enable or disable heartbeat on the
\r
6006 specified destination transport address.
\r
6008 The result of attempting this operation shall be returned.
\r
6010 Note: Even when enabled, heartbeat will not take place if the
\r
6011 destination transport address is not idle.
\r
6013 Mandatory attributes:
\r
6015 o association id - local handle to the SCTP association
\r
6017 o destination transport address - specified as one of the transport
\r
6018 addresses of the peer endpoint.
\r
6020 o new state - the new state of heartbeat for this destination
\r
6021 transport address (either enabled or disabled).
\r
6023 Optional attributes:
\r
6025 o interval - if present, indicates the frequency of the heartbeat if
\r
6026 this is to enable heartbeat on a destination transport address.
\r
6027 This value is added to the RTO of the destination transport
\r
6028 address. This value, if present, effects all destinations.
\r
6030 J) Request HeartBeat
\r
6032 Format: REQUESTHEARTBEAT(association id, destination transport
\r
6036 Instructs the local endpoint to perform a HeartBeat on the specified
\r
6037 destination transport address of the given association. The returned
\r
6038 result should indicate whether the transmission of the HEARTBEAT
\r
6039 chunk to the destination address is successful.
\r
6041 Mandatory attributes:
\r
6043 o association id - local handle to the SCTP association
\r
6045 o destination transport address - the transport address of the
\r
6046 association on which a heartbeat should be issued.
\r
6050 Stewart, et al. Standards Track [Page 108]
\r
6052 RFC 2960 Stream Control Transmission Protocol October 2000
\r
6055 K) Get SRTT Report
\r
6057 Format: GETSRTTREPORT(association id, destination transport address)
\r
6060 Instructs the local SCTP to report the current SRTT measurement on
\r
6061 the specified destination transport address of the given association.
\r
6062 The returned result can be an integer containing the most recent SRTT
\r
6065 Mandatory attributes:
\r
6067 o association id - local handle to the SCTP association
\r
6069 o destination transport address - the transport address of the
\r
6070 association on which the SRTT measurement is to be reported.
\r
6072 L) Set Failure Threshold
\r
6074 Format: SETFAILURETHRESHOLD(association id, destination transport
\r
6075 address, failure threshold)
\r
6078 This primitive allows the local SCTP to customize the reachability
\r
6079 failure detection threshold 'Path.Max.Retrans' for the specified
\r
6080 destination address.
\r
6082 Mandatory attributes:
\r
6084 o association id - local handle to the SCTP association
\r
6086 o destination transport address - the transport address of the
\r
6087 association on which the failure detection threshold is to be set.
\r
6089 o failure threshold - the new value of 'Path.Max.Retrans' for the
\r
6090 destination address.
\r
6092 M) Set Protocol Parameters
\r
6094 Format: SETPROTOCOLPARAMETERS(association id, [,destination transport
\r
6095 address,] protocol parameter list)
\r
6098 This primitive allows the local SCTP to customize the protocol
\r
6106 Stewart, et al. Standards Track [Page 109]
\r
6108 RFC 2960 Stream Control Transmission Protocol October 2000
\r
6111 Mandatory attributes:
\r
6113 o association id - local handle to the SCTP association
\r
6115 o protocol parameter list - The specific names and values of the
\r
6116 protocol parameters (e.g., Association.Max.Retrans [see Section
\r
6117 14]) that the SCTP user wishes to customize.
\r
6119 Optional attributes:
\r
6121 o destination transport address - some of the protocol parameters
\r
6122 may be set on a per destination transport address basis.
\r
6124 N) Receive unsent message
\r
6126 Format: RECEIVE_UNSENT(data retrieval id, buffer address, buffer size
\r
6127 [,stream id] [, stream sequence number] [,partial flag]
\r
6128 [,payload protocol-id])
\r
6130 o data retrieval id - The identification passed to the ULP in the
\r
6131 failure notification.
\r
6133 o buffer address - the memory location indicated by the ULP to store
\r
6134 the received message.
\r
6136 o buffer size - the maximum size of data to be received, in bytes.
\r
6138 Optional attributes:
\r
6140 o stream id - this is a return value that is set to indicate
\r
6141 which stream the data was sent to.
\r
6143 o stream sequence number - this value is returned indicating
\r
6144 the stream sequence number that was associated with the message.
\r
6146 o partial flag - if this returned flag is set to 1, then this
\r
6147 message is a partial delivery of the whole message. When
\r
6148 this flag is set, the stream id and stream sequence number MUST
\r
6149 accompany this receive. When this flag is set to 0, it indicates
\r
6150 that no more deliveries will be received for this stream sequence
\r
6153 o payload protocol-id - The 32 bit unsigned integer that was sent to
\r
6154 be sent to the peer indicating the type of payload protocol of the
\r
6162 Stewart, et al. Standards Track [Page 110]
\r
6164 RFC 2960 Stream Control Transmission Protocol October 2000
\r
6167 O) Receive unacknowledged message
\r
6169 Format: RECEIVE_UNACKED(data retrieval id, buffer address, buffer size,
\r
6170 [,stream id] [, stream sequence number] [,partial flag]
\r
6171 [,payload protocol-id])
\r
6173 o data retrieval id - The identification passed to the ULP in the
\r
6174 failure notification.
\r
6176 o buffer address - the memory location indicated by the ULP to store
\r
6177 the received message.
\r
6179 o buffer size - the maximum size of data to be received, in bytes.
\r
6181 Optional attributes:
\r
6183 o stream id - this is a return value that is set to indicate which
\r
6184 stream the data was sent to.
\r
6186 o stream sequence number - this value is returned indicating the
\r
6187 stream sequence number that was associated with the message.
\r
6189 o partial flag - if this returned flag is set to 1, then this
\r
6190 message is a partial delivery of the whole message. When this
\r
6191 flag is set, the stream id and stream sequence number MUST
\r
6192 accompany this receive. When this flag is set to 0, it indicates
\r
6193 that no more deliveries will be received for this stream sequence
\r
6196 o payload protocol-id - The 32 bit unsigned integer that was sent to
\r
6197 be sent to the peer indicating the type of payload protocol of the
\r
6200 P) Destroy SCTP instance
\r
6202 Format: DESTROY(local SCTP instance name)
\r
6204 o local SCTP instance name - this is the value that was passed to
\r
6205 the application in the initialize primitive and it indicates which
\r
6206 SCTP instance to be destroyed.
\r
6210 It is assumed that the operating system or application environment
\r
6211 provides a means for the SCTP to asynchronously signal the ULP
\r
6212 process. When SCTP does signal an ULP process, certain information
\r
6213 is passed to the ULP.
\r
6218 Stewart, et al. Standards Track [Page 111]
\r
6220 RFC 2960 Stream Control Transmission Protocol October 2000
\r
6223 IMPLEMENTATION NOTE: In some cases this may be done through a
\r
6224 separate socket or error channel.
\r
6226 A) DATA ARRIVE notification
\r
6228 SCTP shall invoke this notification on the ULP when a user message is
\r
6229 successfully received and ready for retrieval.
\r
6231 The following may be optionally be passed with the notification:
\r
6233 o association id - local handle to the SCTP association
\r
6235 o stream id - to indicate which stream the data is received on.
\r
6237 B) SEND FAILURE notification
\r
6239 If a message can not be delivered SCTP shall invoke this notification
\r
6242 The following may be optionally be passed with the notification:
\r
6244 o association id - local handle to the SCTP association
\r
6246 o data retrieval id - an identification used to retrieve unsent and
\r
6247 unacknowledged data.
\r
6249 o cause code - indicating the reason of the failure, e.g., size too
\r
6250 large, message life-time expiration, etc.
\r
6252 o context - optional information associated with this message (see D
\r
6255 C) NETWORK STATUS CHANGE notification
\r
6257 When a destination transport address is marked inactive (e.g., when
\r
6258 SCTP detects a failure), or marked active (e.g., when SCTP detects a
\r
6259 recovery), SCTP shall invoke this notification on the ULP.
\r
6261 The following shall be passed with the notification:
\r
6263 o association id - local handle to the SCTP association
\r
6265 o destination transport address - This indicates the destination
\r
6266 transport address of the peer endpoint affected by the change;
\r
6268 o new-status - This indicates the new status.
\r
6274 Stewart, et al. Standards Track [Page 112]
\r
6276 RFC 2960 Stream Control Transmission Protocol October 2000
\r
6279 D) COMMUNICATION UP notification
\r
6281 This notification is used when SCTP becomes ready to send or receive
\r
6282 user messages, or when a lost communication to an endpoint is
\r
6285 IMPLEMENTATION NOTE: If ASSOCIATE primitive is implemented as a
\r
6286 blocking function call, the association parameters are returned as a
\r
6287 result of the ASSOCIATE primitive itself. In that case,
\r
6288 COMMUNICATION UP notification is optional at the association
\r
6291 The following shall be passed with the notification:
\r
6293 o association id - local handle to the SCTP association
\r
6295 o status - This indicates what type of event has occurred
\r
6297 o destination transport address list - the complete set of transport
\r
6298 addresses of the peer
\r
6300 o outbound stream count - the maximum number of streams allowed to
\r
6301 be used in this association by the ULP
\r
6303 o inbound stream count - the number of streams the peer endpoint has
\r
6304 requested with this association (this may not be the same number
\r
6305 as 'outbound stream count').
\r
6307 E) COMMUNICATION LOST notification
\r
6309 When SCTP loses communication to an endpoint completely (e.g., via
\r
6310 Heartbeats) or detects that the endpoint has performed an abort
\r
6311 operation, it shall invoke this notification on the ULP.
\r
6313 The following shall be passed with the notification:
\r
6315 o association id - local handle to the SCTP association
\r
6317 o status - This indicates what type of event has occurred; The status
\r
6318 may indicate a failure OR a normal termination event
\r
6319 occurred in response to a shutdown or abort request.
\r
6321 The following may be passed with the notification:
\r
6323 o data retrieval id - an identification used to retrieve unsent and
\r
6324 unacknowledged data.
\r
6326 o last-acked - the TSN last acked by that peer endpoint;
\r
6330 Stewart, et al. Standards Track [Page 113]
\r
6332 RFC 2960 Stream Control Transmission Protocol October 2000
\r
6335 o last-sent - the TSN last sent to that peer endpoint;
\r
6337 F) COMMUNICATION ERROR notification
\r
6339 When SCTP receives an ERROR chunk from its peer and decides to notify
\r
6340 its ULP, it can invoke this notification on the ULP.
\r
6342 The following can be passed with the notification:
\r
6344 o association id - local handle to the SCTP association
\r
6346 o error info - this indicates the type of error and optionally some
\r
6347 additional information received through the ERROR chunk.
\r
6349 G) RESTART notification
\r
6351 When SCTP detects that the peer has restarted, it may send this
\r
6352 notification to its ULP.
\r
6354 The following can be passed with the notification:
\r
6356 o association id - local handle to the SCTP association
\r
6358 H) SHUTDOWN COMPLETE notification
\r
6360 When SCTP completes the shutdown procedures (section 9.2) this
\r
6361 notification is passed to the upper layer.
\r
6363 The following can be passed with the notification:
\r
6365 o association id - local handle to the SCTP association
\r
6367 11. Security Considerations
\r
6369 11.1 Security Objectives
\r
6371 As a common transport protocol designed to reliably carry time-
\r
6372 sensitive user messages, such as billing or signaling messages for
\r
6373 telephony services, between two networked endpoints, SCTP has the
\r
6374 following security objectives.
\r
6376 - availability of reliable and timely data transport services
\r
6377 - integrity of the user-to-user information carried by SCTP
\r
6386 Stewart, et al. Standards Track [Page 114]
\r
6388 RFC 2960 Stream Control Transmission Protocol October 2000
\r
6391 11.2 SCTP Responses To Potential Threats
\r
6393 SCTP may potentially be used in a wide variety of risk situations.
\r
6394 It is important for operator(s) of systems running SCTP to analyze
\r
6395 their particular situations and decide on the appropriate counter-
\r
6398 Operators of systems running SCTP should consult [RFC2196] for
\r
6399 guidance in securing their site.
\r
6401 11.2.1 Countering Insider Attacks
\r
6403 The principles of [RFC2196] should be applied to minimize the risk of
\r
6404 theft of information or sabotage by insiders. Such procedures
\r
6405 include publication of security policies, control of access at the
\r
6406 physical, software, and network levels, and separation of services.
\r
6408 11.2.2 Protecting against Data Corruption in the Network
\r
6410 Where the risk of undetected errors in datagrams delivered by the
\r
6411 lower layer transport services is considered to be too great,
\r
6412 additional integrity protection is required. If this additional
\r
6413 protection were provided in the application-layer, the SCTP header
\r
6414 would remain vulnerable to deliberate integrity attacks. While the
\r
6415 existing SCTP mechanisms for detection of packet replays are
\r
6416 considered sufficient for normal operation, stronger protections are
\r
6417 needed to protect SCTP when the operating environment contains
\r
6418 significant risk of deliberate attacks from a sophisticated
\r
6421 In order to promote software code-reuse, to avoid re-inventing the
\r
6422 wheel, and to avoid gratuitous complexity to SCTP, the IP
\r
6423 Authentication Header [RFC2402] SHOULD be used when the threat
\r
6424 environment requires stronger integrity protections, but does not
\r
6425 require confidentiality.
\r
6427 A widely implemented BSD Sockets API extension exists for
\r
6428 applications to request IP security services, such as AH or ESP from
\r
6429 an operating system kernel. Applications can use such an API to
\r
6430 request AH whenever AH use is appropriate.
\r
6432 11.2.3 Protecting Confidentiality
\r
6434 In most cases, the risk of breach of confidentiality applies to the
\r
6435 signaling data payload, not to the SCTP or lower-layer protocol
\r
6436 overheads. If that is true, encryption of the SCTP user data only
\r
6437 might be considered. As with the supplementary checksum service,
\r
6438 user data encryption MAY be performed by the SCTP user application.
\r
6442 Stewart, et al. Standards Track [Page 115]
\r
6444 RFC 2960 Stream Control Transmission Protocol October 2000
\r
6447 Alternately, the user application MAY use an implementation-specific
\r
6448 API to request that the IP Encapsulating Security Payload (ESP)
\r
6449 [RFC2406] be used to provide confidentiality and integrity.
\r
6451 Particularly for mobile users, the requirement for confidentiality
\r
6452 might include the masking of IP addresses and ports. In this case
\r
6453 ESP SHOULD be used instead of application-level confidentiality. If
\r
6454 ESP is used to protect confidentiality of SCTP traffic, an ESP
\r
6455 cryptographic transform that includes cryptographic integrity
\r
6456 protection MUST be used, because if there is a confidentiality threat
\r
6457 there will also be a strong integrity threat.
\r
6459 Whenever ESP is in use, application-level encryption is not generally
\r
6462 Regardless of where confidentiality is provided, the ISAKMP [RFC2408]
\r
6463 and the Internet Key Exchange (IKE) [RFC2409] SHOULD be used for key
\r
6466 Operators should consult [RFC2401] for more information on the
\r
6467 security services available at and immediately above the Internet
\r
6470 11.2.4 Protecting against Blind Denial of Service Attacks
\r
6472 A blind attack is one where the attacker is unable to intercept or
\r
6473 otherwise see the content of data flows passing to and from the
\r
6474 target SCTP node. Blind denial of service attacks may take the form
\r
6475 of flooding, masquerade, or improper monopolization of services.
\r
6479 The objective of flooding is to cause loss of service and incorrect
\r
6480 behavior at target systems through resource exhaustion, interference
\r
6481 with legitimate transactions, and exploitation of buffer-related
\r
6482 software bugs. Flooding may be directed either at the SCTP node or
\r
6483 at resources in the intervening IP Access Links or the Internet.
\r
6484 Where the latter entities are the target, flooding will manifest
\r
6485 itself as loss of network services, including potentially the breach
\r
6486 of any firewalls in place.
\r
6488 In general, protection against flooding begins at the equipment
\r
6489 design level, where it includes measures such as:
\r
6491 - avoiding commitment of limited resources before determining that
\r
6492 the request for service is legitimate
\r
6498 Stewart, et al. Standards Track [Page 116]
\r
6500 RFC 2960 Stream Control Transmission Protocol October 2000
\r
6503 - giving priority to completion of processing in progress over the
\r
6504 acceptance of new work
\r
6506 - identification and removal of duplicate or stale queued requests
\r
6509 - not responding to unexpected packets sent to non-unicast
\r
6512 Network equipment should be capable of generating an alarm and log if
\r
6513 a suspicious increase in traffic occurs. The log should provide
\r
6514 information such as the identity of the incoming link and source
\r
6515 address(es) used which will help the network or SCTP system operator
\r
6516 to take protective measures. Procedures should be in place for the
\r
6517 operator to act on such alarms if a clear pattern of abuse emerges.
\r
6519 The design of SCTP is resistant to flooding attacks, particularly in
\r
6520 its use of a four-way start-up handshake, its use of a cookie to
\r
6521 defer commitment of resources at the responding SCTP node until the
\r
6522 handshake is completed, and its use of a Verification Tag to prevent
\r
6523 insertion of extraneous packets into the flow of an established
\r
6526 The IP Authentication Header and Encapsulating Security Payload might
\r
6527 be useful in reducing the risk of certain kinds of denial of service
\r
6530 The use of the Host Name feature in the INIT chunk could be used to
\r
6531 flood a target DNS server. A large backlog of DNS queries, resolving
\r
6532 the Host Name received in the INIT chunk to IP addresses, could be
\r
6533 accomplished by sending INIT's to multiple hosts in a given domain.
\r
6534 In addition, an attacker could use the Host Name feature in an
\r
6535 indirect attack on a third party by sending large numbers of INITs to
\r
6536 random hosts containing the host name of the target. In addition to
\r
6537 the strain on DNS resources, this could also result in large numbers
\r
6538 of INIT ACKs being sent to the target. One method to protect against
\r
6539 this type of attack is to verify that the IP addresses received from
\r
6540 DNS include the source IP address of the original INIT. If the list
\r
6541 of IP addresses received from DNS does not include the source IP
\r
6542 address of the INIT, the endpoint MAY silently discard the INIT.
\r
6543 This last option will not protect against the attack against the DNS.
\r
6554 Stewart, et al. Standards Track [Page 117]
\r
6556 RFC 2960 Stream Control Transmission Protocol October 2000
\r
6559 11.2.4.2 Blind Masquerade
\r
6561 Masquerade can be used to deny service in several ways:
\r
6563 - by tying up resources at the target SCTP node to which the
\r
6564 impersonated node has limited access. For example, the target
\r
6565 node may by policy permit a maximum of one SCTP association with
\r
6566 the impersonated SCTP node. The masquerading attacker may attempt
\r
6567 to establish an association purporting to come from the
\r
6568 impersonated node so that the latter cannot do so when it requires
\r
6571 - by deliberately allowing the impersonation to be detected, thereby
\r
6572 provoking counter-measures which cause the impersonated node to be
\r
6573 locked out of the target SCTP node.
\r
6575 - by interfering with an established association by inserting
\r
6576 extraneous content such as a SHUTDOWN request.
\r
6578 SCTP reduces the risk of blind masquerade attacks through IP spoofing
\r
6579 by use of the four-way startup handshake. Man-in-the-middle
\r
6580 masquerade attacks are discussed in Section 11.3 below. Because the
\r
6581 initial exchange is memoryless, no lockout mechanism is triggered by
\r
6582 blind masquerade attacks. In addition, the INIT ACK containing the
\r
6583 State Cookie is transmitted back to the IP address from which it
\r
6584 received the INIT. Thus the attacker would not receive the INIT ACK
\r
6585 containing the State Cookie. SCTP protects against insertion of
\r
6586 extraneous packets into the flow of an established association by use
\r
6587 of the Verification Tag.
\r
6589 Logging of received INIT requests and abnormalities such as
\r
6590 unexpected INIT ACKs might be considered as a way to detect patterns
\r
6591 of hostile activity. However, the potential usefulness of such
\r
6592 logging must be weighed against the increased SCTP startup processing
\r
6593 it implies, rendering the SCTP node more vulnerable to flooding
\r
6594 attacks. Logging is pointless without the establishment of operating
\r
6595 procedures to review and analyze the logs on a routine basis.
\r
6597 11.2.4.3 Improper Monopolization of Services
\r
6599 Attacks under this heading are performed openly and legitimately by
\r
6600 the attacker. They are directed against fellow users of the target
\r
6601 SCTP node or of the shared resources between the attacker and the
\r
6602 target node. Possible attacks include the opening of a large number
\r
6603 of associations between the attacker's node and the target, or
\r
6604 transfer of large volumes of information within a legitimately-
\r
6605 established association.
\r
6610 Stewart, et al. Standards Track [Page 118]
\r
6612 RFC 2960 Stream Control Transmission Protocol October 2000
\r
6615 Policy limits should be placed on the number of associations per
\r
6616 adjoining SCTP node. SCTP user applications should be capable of
\r
6617 detecting large volumes of illegitimate or "no-op" messages within a
\r
6618 given association and either logging or terminating the association
\r
6619 as a result, based on local policy.
\r
6621 11.3 Protection against Fraud and Repudiation
\r
6623 The objective of fraud is to obtain services without authorization
\r
6624 and specifically without paying for them. In order to achieve this
\r
6625 objective, the attacker must induce the SCTP user application at the
\r
6626 target SCTP node to provide the desired service while accepting
\r
6627 invalid billing data or failing to collect it. Repudiation is a
\r
6628 related problem, since it may occur as a deliberate act of fraud or
\r
6629 simply because the repudiating party kept inadequate records of
\r
6632 Potential fraudulent attacks include interception and misuse of
\r
6633 authorizing information such as credit card numbers, blind masquerade
\r
6634 and replay, and man-in-the middle attacks which modify the packets
\r
6635 passing through a target SCTP association in real time.
\r
6637 The interception attack is countered by the confidentiality measures
\r
6638 discussed in Section 11.2.3 above.
\r
6640 Section 11.2.4.2 describes how SCTP is resistant to blind masquerade
\r
6641 attacks, as a result of the four-way startup handshake and the
\r
6642 Verification Tag. The Verification Tag and TSN together are
\r
6643 protections against blind replay attacks, where the replay is into an
\r
6644 existing association.
\r
6646 However, SCTP does not protect against man-in-the-middle attacks
\r
6647 where the attacker is able to intercept and alter the packets sent
\r
6648 and received in an association. For example, the INIT ACK will have
\r
6649 sufficient information sent on the wire for an adversary in the
\r
6650 middle to hijack an existing SCTP association. Where a significant
\r
6651 possibility of such attacks is seen to exist, or where possible
\r
6652 repudiation is an issue, the use of the IPSEC AH service is
\r
6653 recommended to ensure both the integrity and the authenticity of the
\r
6654 SCTP packets passed.
\r
6656 SCTP also provides no protection against attacks originating at or
\r
6657 beyond the SCTP node and taking place within the context of an
\r
6658 existing association. Prevention of such attacks should be covered
\r
6659 by appropriate security policies at the host site, as discussed in
\r
6666 Stewart, et al. Standards Track [Page 119]
\r
6668 RFC 2960 Stream Control Transmission Protocol October 2000
\r
6671 12. Recommended Transmission Control Block (TCB) Parameters
\r
6673 This section details a recommended set of parameters that should be
\r
6674 contained within the TCB for an implementation. This section is for
\r
6675 illustrative purposes and should not be deemed as requirements on an
\r
6676 implementation or as an exhaustive list of all parameters inside an
\r
6677 SCTP TCB. Each implementation may need its own additional parameters
\r
6680 12.1 Parameters necessary for the SCTP instance
\r
6682 Associations: A list of current associations and mappings to the data
\r
6683 consumers for each association. This may be in the
\r
6684 form of a hash table or other implementation dependent
\r
6685 structure. The data consumers may be process
\r
6686 identification information such as file descriptors,
\r
6687 named pipe pointer, or table pointers dependent on how
\r
6688 SCTP is implemented.
\r
6690 Secret Key: A secret key used by this endpoint to compute the MAC.
\r
6691 This SHOULD be a cryptographic quality random number
\r
6692 with a sufficient length. Discussion in [RFC1750] can
\r
6693 be helpful in selection of the key.
\r
6695 Address List: The list of IP addresses that this instance has bound.
\r
6696 This information is passed to one's peer(s) in INIT and
\r
6699 SCTP Port: The local SCTP port number the endpoint is bound to.
\r
6701 12.2 Parameters necessary per association (i.e. the TCB)
\r
6703 Peer : Tag value to be sent in every packet and is received
\r
6704 Verification: in the INIT or INIT ACK chunk.
\r
6707 My : Tag expected in every inbound packet and sent in the
\r
6708 Verification: INIT or INIT ACK chunk.
\r
6711 State : A state variable indicating what state the association
\r
6712 : is in, i.e. COOKIE-WAIT, COOKIE-ECHOED, ESTABLISHED,
\r
6713 : SHUTDOWN-PENDING, SHUTDOWN-SENT, SHUTDOWN-RECEIVED,
\r
6714 : SHUTDOWN-ACK-SENT.
\r
6716 Note: No "CLOSED" state is illustrated since if a
\r
6717 association is "CLOSED" its TCB SHOULD be removed.
\r
6722 Stewart, et al. Standards Track [Page 120]
\r
6724 RFC 2960 Stream Control Transmission Protocol October 2000
\r
6727 Peer : A list of SCTP transport addresses that the peer is
\r
6728 Transport : bound to. This information is derived from the INIT or
\r
6729 Address : INIT ACK and is used to associate an inbound packet
\r
6730 List : with a given association. Normally this information is
\r
6731 : hashed or keyed for quick lookup and access of the TCB.
\r
6733 Primary : This is the current primary destination transport
\r
6734 Path : address of the peer endpoint. It may also specify a
\r
6735 : source transport address on this endpoint.
\r
6737 Overall : The overall association error count.
\r
6740 Overall : The threshold for this association that if the Overall
\r
6741 Error : Error Count reaches will cause this association to be
\r
6742 Threshold : torn down.
\r
6744 Peer Rwnd : Current calculated value of the peer's rwnd.
\r
6746 Next TSN : The next TSN number to be assigned to a new DATA chunk.
\r
6747 : This is sent in the INIT or INIT ACK chunk to the peer
\r
6748 : and incremented each time a DATA chunk is assigned a
\r
6749 : TSN (normally just prior to transmit or during
\r
6752 Last Rcvd : This is the last TSN received in sequence. This value
\r
6753 TSN : is set initially by taking the peer's Initial TSN,
\r
6754 : received in the INIT or INIT ACK chunk, and
\r
6755 : subtracting one from it.
\r
6757 Mapping : An array of bits or bytes indicating which out of
\r
6758 Array : order TSN's have been received (relative to the
\r
6759 : Last Rcvd TSN). If no gaps exist, i.e. no out of order
\r
6760 : packets have been received, this array will be set to
\r
6761 : all zero. This structure may be in the form of a
\r
6762 : circular buffer or bit array.
\r
6764 Ack State : This flag indicates if the next received packet
\r
6765 : is to be responded to with a SACK. This is initialized
\r
6766 : to 0. When a packet is received it is incremented.
\r
6767 : If this value reaches 2 or more, a SACK is sent and the
\r
6768 : value is reset to 0. Note: This is used only when no
\r
6769 : DATA chunks are received out of order. When DATA chunks
\r
6770 : are out of order, SACK's are not delayed (see Section
\r
6778 Stewart, et al. Standards Track [Page 121]
\r
6780 RFC 2960 Stream Control Transmission Protocol October 2000
\r
6783 Inbound : An array of structures to track the inbound streams.
\r
6784 Streams : Normally including the next sequence number expected
\r
6785 : and possibly the stream number.
\r
6787 Outbound : An array of structures to track the outbound streams.
\r
6788 Streams : Normally including the next sequence number to
\r
6789 : be sent on the stream.
\r
6791 Reasm Queue : A re-assembly queue.
\r
6793 Local : The list of local IP addresses bound in to this
\r
6794 Transport : association.
\r
6798 Association : The smallest PMTU discovered for all of the
\r
6799 PMTU : peer's transport addresses.
\r
6801 12.3 Per Transport Address Data
\r
6803 For each destination transport address in the peer's address list
\r
6804 derived from the INIT or INIT ACK chunk, a number of data elements
\r
6805 needs to be maintained including:
\r
6807 Error count : The current error count for this destination.
\r
6809 Error : Current error threshold for this destination i.e.
\r
6810 Threshold : what value marks the destination down if Error count
\r
6811 : reaches this value.
\r
6813 cwnd : The current congestion window.
\r
6815 ssthresh : The current ssthresh value.
\r
6817 RTO : The current retransmission timeout value.
\r
6819 SRTT : The current smoothed round trip time.
\r
6821 RTTVAR : The current RTT variation.
\r
6823 partial : The tracking method for increase of cwnd when in
\r
6824 bytes acked : congestion avoidance mode (see Section 6.2.2)
\r
6826 state : The current state of this destination, i.e. DOWN, UP,
\r
6827 : ALLOW-HB, NO-HEARTBEAT, etc.
\r
6829 PMTU : The current known path MTU.
\r
6834 Stewart, et al. Standards Track [Page 122]
\r
6836 RFC 2960 Stream Control Transmission Protocol October 2000
\r
6839 Per : A timer used by each destination.
\r
6843 RTO-Pending : A flag used to track if one of the DATA chunks sent to
\r
6844 this address is currently being used to compute a
\r
6845 RTT. If this flag is 0, the next DATA chunk sent to this
\r
6846 destination should be used to compute a RTT and this
\r
6847 flag should be set. Every time the RTT calculation
\r
6848 completes (i.e. the DATA chunk is SACK'd) clear this
\r
6851 last-time : The time this destination was last sent to. This can be
\r
6852 used : used to determine if a HEARTBEAT is needed.
\r
6854 12.4 General Parameters Needed
\r
6856 Out Queue : A queue of outbound DATA chunks.
\r
6858 In Queue : A queue of inbound DATA chunks.
\r
6860 13. IANA Considerations
\r
6862 This protocol will require port reservation like TCP for the use of
\r
6863 "well known" servers within the Internet. All current TCP ports
\r
6864 shall be automatically reserved in the SCTP port address space. New
\r
6865 requests should follow IANA's current mechanisms for TCP.
\r
6867 This protocol may also be extended through IANA in three ways:
\r
6869 -- through definition of additional chunk types,
\r
6870 -- through definition of additional parameter types, or
\r
6871 -- through definition of additional cause codes within
\r
6874 In the case where a particular ULP using SCTP desires to have its own
\r
6875 ports, the ULP should be responsible for registering with IANA for
\r
6876 getting its ports assigned.
\r
6878 13.1 IETF-defined Chunk Extension
\r
6880 The definition and use of new chunk types is an integral part of
\r
6881 SCTP. Thus, new chunk types are assigned by IANA through an IETF
\r
6882 Consensus action as defined in [RFC2434].
\r
6884 The documentation for a new chunk code type must include the
\r
6885 following information:
\r
6890 Stewart, et al. Standards Track [Page 123]
\r
6892 RFC 2960 Stream Control Transmission Protocol October 2000
\r
6895 a) A long and short name for the new chunk type;
\r
6897 b) A detailed description of the structure of the chunk, which MUST
\r
6898 conform to the basic structure defined in Section 3.2;
\r
6900 c) A detailed definition and description of intended use of each
\r
6901 field within the chunk, including the chunk flags if any;
\r
6903 d) A detailed procedural description of the use of the new chunk type
\r
6904 within the operation of the protocol.
\r
6906 The last chunk type (255) is reserved for future extension if
\r
6909 13.2 IETF-defined Chunk Parameter Extension
\r
6911 The assignment of new chunk parameter type codes is done through an
\r
6912 IETF Consensus action as defined in [RFC2434]. Documentation of the
\r
6913 chunk parameter MUST contain the following information:
\r
6915 a) Name of the parameter type.
\r
6917 b) Detailed description of the structure of the parameter field.
\r
6918 This structure MUST conform to the general type-length-value
\r
6919 format described in Section 3.2.1.
\r
6921 c) Detailed definition of each component of the parameter value.
\r
6923 d) Detailed description of the intended use of this parameter type,
\r
6924 and an indication of whether and under what circumstances multiple
\r
6925 instances of this parameter type may be found within the same
\r
6928 13.3 IETF-defined Additional Error Causes
\r
6930 Additional cause codes may be allocated in the range 11 to 65535
\r
6931 through a Specification Required action as defined in [RFC2434].
\r
6932 Provided documentation must include the following information:
\r
6934 a) Name of the error condition.
\r
6936 b) Detailed description of the conditions under which an SCTP
\r
6937 endpoint should issue an ERROR (or ABORT) with this cause code.
\r
6939 c) Expected action by the SCTP endpoint which receives an ERROR (or
\r
6940 ABORT) chunk containing this cause code.
\r
6946 Stewart, et al. Standards Track [Page 124]
\r
6948 RFC 2960 Stream Control Transmission Protocol October 2000
\r
6951 d) Detailed description of the structure and content of data fields
\r
6952 which accompany this cause code.
\r
6954 The initial word (32 bits) of a cause code parameter MUST conform to
\r
6955 the format shown in Section 3.3.10, i.e.:
\r
6957 -- first two bytes contain the cause code value
\r
6958 -- last two bytes contain length of the Cause Parameter.
\r
6960 13.4 Payload Protocol Identifiers
\r
6962 Except for value 0 which is reserved by SCTP to indicate an
\r
6963 unspecified payload protocol identifier in a DATA chunk, SCTP will
\r
6964 not be responsible for standardizing or verifying any payload
\r
6965 protocol identifiers; SCTP simply receives the identifier from the
\r
6966 upper layer and carries it with the corresponding payload data.
\r
6968 The upper layer, i.e., the SCTP user, SHOULD standardize any specific
\r
6969 protocol identifier with IANA if it is so desired. The use of any
\r
6970 specific payload protocol identifier is out of the scope of SCTP.
\r
6972 14. Suggested SCTP Protocol Parameter Values
\r
6974 The following protocol parameters are RECOMMENDED:
\r
6976 RTO.Initial - 3 seconds
\r
6977 RTO.Min - 1 second
\r
6978 RTO.Max - 60 seconds
\r
6981 Valid.Cookie.Life - 60 seconds
\r
6982 Association.Max.Retrans - 10 attempts
\r
6983 Path.Max.Retrans - 5 attempts (per destination address)
\r
6984 Max.Init.Retransmits - 8 attempts
\r
6985 HB.interval - 30 seconds
\r
6987 IMPLEMENTATION NOTE: The SCTP implementation may allow ULP to
\r
6988 customize some of these protocol parameters (see Section 10).
\r
6990 Note: RTO.Min SHOULD be set as recommended above.
\r
7002 Stewart, et al. Standards Track [Page 125]
\r
7004 RFC 2960 Stream Control Transmission Protocol October 2000
\r
7007 15. Acknowledgements
\r
7009 The authors wish to thank Mark Allman, R.J. Atkinson, Richard Band,
\r
7010 Scott Bradner, Steve Bellovin, Peter Butler, Ram Dantu, R.
\r
7011 Ezhirpavai, Mike Fisk, Sally Floyd, Atsushi Fukumoto, Matt Holdrege,
\r
7012 Henry Houh, Christian Huitema, Gary Lehecka, Jonathan Lee, David
\r
7013 Lehmann, John Loughney, Daniel Luan, Barry Nagelberg, Thomas Narten,
\r
7014 Erik Nordmark, Lyndon Ong, Shyamal Prasad, Kelvin Porter, Heinz
\r
7015 Prantner, Jarno Rajahalme, Raymond E. Reeves, Renee Revis, Ivan Arias
\r
7016 Rodriguez, A. Sankar, Greg Sidebottom, Brian Wyld, La Monte Yarroll,
\r
7017 and many others for their invaluable comments.
\r
7019 16. Authors' Addresses
\r
7021 Randall R. Stewart
\r
7022 24 Burning Bush Trail.
\r
7023 Crystal Lake, IL 60012
\r
7026 Phone: +1-815-477-2127
\r
7027 EMail: rrs@cisco.com
\r
7032 1501 W. Shure Drive, #2309
\r
7033 Arlington Heights, IL 60004
\r
7036 Phone: +1-847-632-3028
\r
7037 EMail: qxie1@email.mot.com
\r
7041 Cisco Systems Inc.
\r
7042 13615 Dulles Technology Drive
\r
7043 Herndon, VA. 20171
\r
7046 Phone: +1-703-484-3323
\r
7047 EMail: kmorneau@cisco.com
\r
7058 Stewart, et al. Standards Track [Page 126]
\r
7060 RFC 2960 Stream Control Transmission Protocol October 2000
\r
7064 Cisco Systems Inc.
\r
7065 7025 Kit Creek Road
\r
7066 Research Triangle Park, NC 27709
\r
7069 Phone: +1-919-392-3121
\r
7070 EMail: chsharp@cisco.com
\r
7073 Hanns Juergen Schwarzbauer
\r
7079 Phone: +49-89-722-24236
\r
7080 EMail: HannsJuergen.Schwarzbauer@icn.siemens.de
\r
7085 1852 Lorraine Ave.
\r
7089 Phone: +1-613-736-0961
\r
7090 EMail: taylor@nortelnetworks.com
\r
7094 Ericsson Australia
\r
7095 37/360 Elizabeth Street
\r
7096 Melbourne, Victoria 3000
\r
7099 Phone: +61-3-9301-6164
\r
7100 EMail: ian.rytina@ericsson.com
\r
7114 Stewart, et al. Standards Track [Page 127]
\r
7116 RFC 2960 Stream Control Transmission Protocol October 2000
\r
7120 Telcordia Technologies
\r
7123 Piscataway, NJ 08854
\r
7126 Phone: +1-732-699-3728
\r
7127 EMail: mkalla@telcordia.com
\r
7130 UCLA Computer Science Department
\r
7131 4531G Boelter Hall
\r
7132 Los Angeles, CA 90095-1596
\r
7135 Phone: +1-310-825-2695
\r
7136 EMail: lixia@cs.ucla.edu
\r
7140 1947 Center St., Suite 600,
\r
7141 Berkeley, CA 94704-1198
\r
7144 Phone: +1-510-666-2882
\r
7145 EMail: vern@aciri.org
\r
7149 [RFC768] Postel, J. (ed.), "User Datagram Protocol", STD 6, RFC
\r
7152 [RFC793] Postel, J. (ed.), "Transmission Control Protocol", STD 7,
\r
7153 RFC 793, September 1981.
\r
7155 [RFC1123] Braden, R., "Requirements for Internet hosts - application
\r
7156 and support", STD 3, RFC 1123, October 1989.
\r
7158 [RFC1191] Mogul, J. and S. Deering, "Path MTU Discovery", RFC 1191,
\r
7161 [RFC1700] Reynolds, J. and J. Postel, "Assigned Numbers", STD 2, RFC
\r
7162 1700, October 1994.
\r
7164 [RFC1981] McCann, J., Deering, S. and J. Mogul, "Path MTU Discovery
\r
7165 for IP version 6", RFC 1981, August 1996.
\r
7170 Stewart, et al. Standards Track [Page 128]
\r
7172 RFC 2960 Stream Control Transmission Protocol October 2000
\r
7175 [RFC1982] Elz, R. and R. Bush, "Serial Number Arithmetic", RFC 1982,
\r
7178 [RFC2026] Bradner, S., "The Internet Standards Process -- Revision
\r
7179 3", BCP 9, RFC 2026, October 1996.
\r
7181 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
\r
7182 Requirement Levels", BCP 14, RFC 2119, March 1997.
\r
7184 [RFC2401] Kent, S. and R. Atkinson, "Security Architecture for the
\r
7185 Internet Protocol", RFC 2401, November 1998.
\r
7187 [RFC2402] Kent, S. and R. Atkinson, "IP Authentication Header", RFC
\r
7188 2402, November 1998.
\r
7190 [RFC2406] Kent, S. and R. Atkinson, "IP Encapsulating Security
\r
7191 Payload (ESP)", RFC 2406, November 1998.
\r
7193 [RFC2408] Maughan, D., Schertler, M., Schneider, M. and J. Turner,
\r
7194 "Internet Security Association and Key Management
\r
7195 Protocol", RFC 2408, November 1998.
\r
7197 [RFC2409] Harkins, D. and D. Carrel, "The Internet Key Exchange
\r
7198 (IKE)", RFC 2409, November 1998.
\r
7200 [RFC2434] Narten, T. and H. Alvestrand, "Guidelines for Writing an
\r
7201 IANA Considerations Section in RFCs", BCP 26, RFC 2434,
\r
7204 [RFC2460] Deering, S. and R. Hinden, "Internet Protocol, Version 6
\r
7205 (IPv6) Specification", RFC 2460, December 1998.
\r
7207 [RFC2581] Allman, M., Paxson, V. and W. Stevens, "TCP Congestion
\r
7208 Control", RFC 2581, April 1999.
\r
7212 [ALLMAN99] Allman, M. and Paxson, V., "On Estimating End-to-End
\r
7213 Network Path Properties", Proc. SIGCOMM'99, 1999.
\r
7215 [FALL96] Fall, K. and Floyd, S., Simulation-based Comparisons of
\r
7216 Tahoe, Reno, and SACK TCP, Computer Communications Review,
\r
7217 V. 26 N. 3, July 1996, pp. 5-21.
\r
7219 [RFC1750] Eastlake, D. (ed.), "Randomness Recommendations for
\r
7220 Security", RFC 1750, December 1994.
\r
7226 Stewart, et al. Standards Track [Page 129]
\r
7228 RFC 2960 Stream Control Transmission Protocol October 2000
\r
7231 [RFC1950] Deutsch P. and J. Gailly, "ZLIB Compressed Data Format
\r
7232 Specification version 3.3", RFC 1950, May 1996.
\r
7234 [RFC2104] Krawczyk, H., Bellare, M. and R. Canetti, "HMAC: Keyed-
\r
7235 Hashing for Message Authentication", RFC 2104, March 1997.
\r
7237 [RFC2196] Fraser, B., "Site Security Handbook", FYI 8, RFC 2196,
\r
7240 [RFC2522] Karn, P. and W. Simpson, "Photuris: Session-Key Management
\r
7241 Protocol", RFC 2522, March 1999.
\r
7243 [SAVAGE99] Savage, S., Cardwell, N., Wetherall, D., and Anderson, T.,
\r
7244 "TCP Congestion Control with a Misbehaving Receiver", ACM
\r
7245 Computer Communication Review, 29(5), October 1999.
\r
7282 Stewart, et al. Standards Track [Page 130]
\r
7284 RFC 2960 Stream Control Transmission Protocol October 2000
\r
7287 Appendix A: Explicit Congestion Notification
\r
7289 ECN (Ramakrishnan, K., Floyd, S., "Explicit Congestion Notification",
\r
7290 RFC 2481, January 1999) describes a proposed extension to IP that
\r
7291 details a method to become aware of congestion outside of datagram
\r
7292 loss. This is an optional feature that an implementation MAY choose
\r
7293 to add to SCTP. This appendix details the minor differences
\r
7294 implementers will need to be aware of if they choose to implement
\r
7295 this feature. In general RFC 2481 should be followed with the
\r
7296 following exceptions.
\r
7300 RFC2481 details negotiation of ECN during the SYN and SYN-ACK stages
\r
7301 of a TCP connection. The sender of the SYN sets two bits in the TCP
\r
7302 flags, and the sender of the SYN-ACK sets only 1 bit. The reasoning
\r
7303 behind this is to assure both sides are truly ECN capable. For SCTP
\r
7304 this is not necessary. To indicate that an endpoint is ECN capable
\r
7305 an endpoint SHOULD add to the INIT and or INIT ACK chunk the TLV
\r
7306 reserved for ECN. This TLV contains no parameters, and thus has the
\r
7310 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
\r
7311 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
7312 | Parameter Type = 32768 | Parameter Length = 4 |
\r
7313 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
7317 RFC 2481 details a specific bit for a receiver to send back in its
\r
7318 TCP acknowledgements to notify the sender of the Congestion
\r
7319 Experienced (CE) bit having arrived from the network. For SCTP this
\r
7320 same indication is made by including the ECNE chunk. This chunk
\r
7321 contains one data element, i.e. the lowest TSN associated with the IP
\r
7322 datagram marked with the CE bit, and looks as follows:
\r
7325 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
\r
7326 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
7327 | Chunk Type=12 | Flags=00000000| Chunk Length = 8 |
\r
7328 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
7329 | Lowest TSN Number |
\r
7330 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
7332 Note: The ECNE is considered a Control chunk.
\r
7338 Stewart, et al. Standards Track [Page 131]
\r
7340 RFC 2960 Stream Control Transmission Protocol October 2000
\r
7345 RFC 2481 details a specific bit for a sender to send in the header of
\r
7346 its next outbound TCP segment to indicate to its peer that it has
\r
7347 reduced its congestion window. This is termed the CWR bit. For
\r
7348 SCTP the same indication is made by including the CWR chunk.
\r
7349 This chunk contains one data element, i.e. the TSN number that
\r
7350 was sent in the ECNE chunk. This element represents the lowest
\r
7351 TSN number in the datagram that was originally marked with the
\r
7355 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
\r
7356 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
7357 | Chunk Type=13 | Flags=00000000| Chunk Length = 8 |
\r
7358 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
7359 | Lowest TSN Number |
\r
7360 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\r
7362 Note: The CWR is considered a Control chunk.
\r
7364 Appendix B Alder 32 bit checksum calculation
\r
7366 The Adler-32 checksum calculation given in this appendix is copied from
\r
7369 Adler-32 is composed of two sums accumulated per byte: s1 is the sum
\r
7370 of all bytes, s2 is the sum of all s1 values. Both sums are done
\r
7371 modulo 65521. s1 is initialized to 1, s2 to zero. The Adler-32
\r
7372 checksum is stored as s2*65536 + s1 in network byte order.
\r
7374 The following C code computes the Adler-32 checksum of a data buffer.
\r
7375 It is written for clarity, not for speed. The sample code is in the
\r
7376 ANSI C programming language. Non C users may find it easier to read
\r
7394 Stewart, et al. Standards Track [Page 132]
\r
7396 RFC 2960 Stream Control Transmission Protocol October 2000
\r
7399 & Bitwise AND operator.
\r
7400 >> Bitwise right shift operator. When applied to an
\r
7401 unsigned quantity, as here, right shift inserts zero bit(s)
\r
7403 << Bitwise left shift operator. Left shift inserts zero
\r
7404 bit(s) at the right.
\r
7405 ++ "n++" increments the variable n.
\r
7406 % modulo operator: a % b is the remainder of a divided by b.
\r
7407 #define BASE 65521 /* largest prime smaller than 65536 */
\r
7409 Update a running Adler-32 checksum with the bytes buf[0..len-1]
\r
7410 and return the updated checksum. The Adler-32 checksum should be
\r
7415 unsigned long adler = 1L;
\r
7417 while (read_buffer(buffer, length) != EOF) {
\r
7418 adler = update_adler32(adler, buffer, length);
\r
7420 if (adler != original_adler) error();
\r
7422 unsigned long update_adler32(unsigned long adler,
\r
7423 unsigned char *buf, int len)
\r
7425 unsigned long s1 = adler & 0xffff;
\r
7426 unsigned long s2 = (adler >> 16) & 0xffff;
\r
7429 for (n = 0; n < len; n++) {
\r
7430 s1 = (s1 + buf[n]) % BASE;
\r
7431 s2 = (s2 + s1) % BASE;
\r
7433 return (s2 << 16) + s1;
\r
7436 /* Return the adler32 of the bytes buf[0..len-1] */
\r
7437 unsigned long adler32(unsigned char *buf, int len)
\r
7439 return update_adler32(1L, buf, len);
\r
7450 Stewart, et al. Standards Track [Page 133]
\r
7452 RFC 2960 Stream Control Transmission Protocol October 2000
\r
7455 Full Copyright Statement
\r
7457 Copyright (C) The Internet Society (2000). All Rights Reserved.
\r
7459 This document and translations of it may be copied and furnished to
\r
7460 others, and derivative works that comment on or otherwise explain it
\r
7461 or assist in its implementation may be prepared, copied, published
\r
7462 and distributed, in whole or in part, without restriction of any
\r
7463 kind, provided that the above copyright notice and this paragraph are
\r
7464 included on all such copies and derivative works. However, this
\r
7465 document itself may not be modified in any way, such as by removing
\r
7466 the copyright notice or references to the Internet Society or other
\r
7467 Internet organizations, except as needed for the purpose of
\r
7468 developing Internet standards in which case the procedures for
\r
7469 copyrights defined in the Internet Standards process must be
\r
7470 followed, or as required to translate it into languages other than
\r
7473 The limited permissions granted above are perpetual and will not be
\r
7474 revoked by the Internet Society or its successors or assigns.
\r
7476 This document and the information contained herein is provided on an
\r
7477 "AS IS" basis and THE INTERNET SOCIETY AND THE INTERNET ENGINEERING
\r
7478 TASK FORCE DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING
\r
7479 BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION
\r
7480 HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF
\r
7481 MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
\r
7485 Funding for the RFC Editor function is currently provided by the
\r
7506 Stewart, et al. Standards Track [Page 134]
\r