draft-ietf-tsvwg-2960bis-05.txt   rfc4960.txt 
Network Working Group R. Stewart Network Working Group R. Stewart, Ed.
Internet-Draft Editor Request for Comments: 4960 September 2007
Obsoletes: 2960,3309 June 12, 2007 Obsoletes: 2960, 3309
(if approved) Category: Standards Track
Intended status: Standards Track
Expires: December 14, 2007
Stream Control Transmission Protocol Stream Control Transmission Protocol
draft-ietf-tsvwg-2960bis-05.txt
Status of this Memo
By submitting this Internet-Draft, each author represents that any
applicable patent or other IPR claims of which he or she is aware
have been or will be disclosed, and any of which he or she becomes
aware will be disclosed, in accordance with Section 6 of BCP 79.
Internet-Drafts are working documents of the Internet Engineering
Task Force (IETF), its areas, and its working groups. Note that
other groups may also distribute working documents as Internet-
Drafts.
Internet-Drafts are draft documents valid for a maximum of six months
and may be updated, replaced, or obsoleted by other documents at any
time. It is inappropriate to use Internet-Drafts as reference
material or to cite them other than as "work in progress."
The list of current Internet-Drafts can be accessed at
http://www.ietf.org/ietf/1id-abstracts.txt.
The list of Internet-Draft Shadow Directories can be accessed at
http://www.ietf.org/shadow.html.
This Internet-Draft will expire on December 14, 2007.
Copyright Notice Status of This Memo
Copyright (C) The IETF Trust (2007). This document specifies an Internet standards track protocol for the
Internet community, and requests discussion and suggestions for
improvements. Please refer to the current edition of the "Internet
Official Protocol Standards" (STD 1) for the standardization state
and status of this protocol. Distribution of this memo is unlimited.
Abstract Abstract
This document obsoletes RFC2960 [RFC2960] and RFC3309 [RFC3309] it This document obsoletes RFC 2960 and RFC 3309. It describes the
describes the Stream Control Transmission Protocol (SCTP). SCTP is Stream Control Transmission Protocol (SCTP). SCTP is designed to
designed to transport PSTN signaling messages over IP networks, but transport Public Switched Telephone Network (PSTN) signaling messages
is capable of broader applications. over IP networks, but is capable of broader applications.
SCTP is a reliable transport protocol operating on top of a SCTP is a reliable transport protocol operating on top of a
connectionless packet network such as IP. It offers the following connectionless packet network such as IP. It offers the following
services to its users: services to its users:
-- acknowledged error-free non-duplicated transfer of user data, -- acknowledged error-free non-duplicated transfer of user data,
-- data fragmentation to conform to discovered path MTU size, -- data fragmentation to conform to discovered path MTU size,
-- sequenced delivery of user messages within multiple streams, with -- sequenced delivery of user messages within multiple streams, with
an option for order-of-arrival delivery of individual user an option for order-of-arrival delivery of individual user
messages, messages,
-- optional bundling of multiple user messages into a single SCTP -- optional bundling of multiple user messages into a single SCTP
packet, and packet, and
-- network-level fault tolerance through supporting of multi- homing -- network-level fault tolerance through supporting of multi- homing
at either or both ends of an association. at either or both ends of an association.
The design of SCTP includes appropriate congestion avoidance behavior The design of SCTP includes appropriate congestion avoidance behavior
and resistance to flooding and masquerade attacks. and resistance to flooding and masquerade attacks.
Table of Contents Table of Contents
1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 6 1. Introduction ....................................................5
1.1. Motivation . . . . . . . . . . . . . . . . . . . . . . . 6 1.1. Motivation .................................................5
1.2. Architectural View of SCTP . . . . . . . . . . . . . . . 6 1.2. Architectural View of SCTP .................................6
1.3. Key Terms . . . . . . . . . . . . . . . . . . . . . . . . 7 1.3. Key Terms ..................................................6
1.4. Abbreviations . . . . . . . . . . . . . . . . . . . . . . 11 1.4. Abbreviations .............................................10
1.5. Functional View of SCTP . . . . . . . . . . . . . . . . . 11 1.5. Functional View of SCTP ...................................10
1.5.1. Association Startup and Takedown . . . . . . . . . . 12 1.5.1. Association Startup and Takedown ...................11
1.5.2. Sequenced Delivery within Streams . . . . . . . . . . 13 1.5.2. Sequenced Delivery within Streams ..................12
1.5.3. User Data Fragmentation . . . . . . . . . . . . . . . 13 1.5.3. User Data Fragmentation ............................12
1.5.4. Acknowledgement and Congestion Avoidance . . . . . . 13 1.5.4. Acknowledgement and Congestion Avoidance ...........12
1.5.5. Chunk Bundling . . . . . . . . . . . . . . . . . . . 14 1.5.5. Chunk Bundling .....................................13
1.5.6. Packet Validation . . . . . . . . . . . . . . . . . . 14 1.5.6. Packet Validation ..................................13
1.5.7. Path Management . . . . . . . . . . . . . . . . . . . 14 1.5.7. Path Management ....................................13
1.6. Serial Number Arithmetic . . . . . . . . . . . . . . . . 15 1.6. Serial Number Arithmetic ..................................14
1.7. Changes from RFC2960 . . . . . . . . . . . . . . . . . . 16 1.7. Changes from RFC 2960 .....................................15
2. Conventions . . . . . . . . . . . . . . . . . . . . . . . . . 16 2. Conventions ....................................................15
3. SCTP packet Format . . . . . . . . . . . . . . . . . . . . . 16 3. SCTP Packet Format .............................................15
3.1. SCTP Common Header Field Descriptions . . . . . . . . . . 17 3.1. SCTP Common Header Field Descriptions .....................16
3.2. Chunk Field Descriptions . . . . . . . . . . . . . . . . 18 3.2. Chunk Field Descriptions ..................................17
3.2.1. Optional/Variable-length Parameter Format . . . . . . 20 3.2.1. Optional/Variable-Length Parameter Format ..........19
3.2.2. Reporting of Unrecognized Parameters . . . . . . . . 22 3.2.2. Reporting of Unrecognized Parameters ...............21
3.3. SCTP Chunk Definitions . . . . . . . . . . . . . . . . . 23 3.3. SCTP Chunk Definitions ....................................21
3.3.1. Payload Data (DATA) (0) . . . . . . . . . . . . . . . 23 3.3.1. Payload Data (DATA) (0) ............................22
3.3.2. Initiation (INIT) (1) . . . . . . . . . . . . . . . . 25 3.3.2. Initiation (INIT) (1) ..............................24
3.3.3. Initiation Acknowledgement (INIT ACK) (2): . . . . . 31 3.3.2.1. Optional/Variable-Length
3.3.4. Selective Acknowledgement (SACK) (3): . . . . . . . . 35 Parameters in INIT ........................27
3.3.5. Heartbeat Request (HEARTBEAT) (4): . . . . . . . . . 39 3.3.3. Initiation Acknowledgement (INIT ACK) (2) ..........30
3.3.6. Heartbeat Acknowledgement (HEARTBEAT ACK) (5): . . . 40 3.3.3.1. Optional or Variable-Length Parameters ....33
3.3.7. Abort Association (ABORT) (6): . . . . . . . . . . . 41 3.3.4. Selective Acknowledgement (SACK) (3) ...............34
3.3.8. Shutdown Association (SHUTDOWN) (7): . . . . . . . . 42 3.3.5. Heartbeat Request (HEARTBEAT) (4) ..................38
3.3.9. Shutdown Acknowledgement (SHUTDOWN ACK) (8): . . . . 42 3.3.6. Heartbeat Acknowledgement (HEARTBEAT ACK) (5) ......39
3.3.10. Operation Error (ERROR) (9): . . . . . . . . . . . . 43 3.3.7. Abort Association (ABORT) (6) ......................40
3.3.10.1. Invalid Stream Identifier (1) . . . . . . . . . 45 3.3.8. Shutdown Association (SHUTDOWN) (7) ................41
3.3.10.2. Missing Mandatory Parameter (2) . . . . . . . . 45 3.3.9. Shutdown Acknowledgement (SHUTDOWN ACK) (8) ........41
3.3.10.3. Stale Cookie Error (3) . . . . . . . . . . . . . 46 3.3.10. Operation Error (ERROR) (9) .......................42
3.3.10.4. Out of Resource (4) . . . . . . . . . . . . . . 46 3.3.10.1. Invalid Stream Identifier (1) ............44
3.3.10.5. Unresolvable Address (5) . . . . . . . . . . . . 47 3.3.10.2. Missing Mandatory Parameter (2) ..........44
3.3.10.6. Unrecognized Chunk Type (6) . . . . . . . . . . 47 3.3.10.3. Stale Cookie Error (3) ...................45
3.3.10.7. Invalid Mandatory Parameter (7) . . . . . . . . 48 3.3.10.4. Out of Resource (4) ......................45
3.3.10.8. Unrecognized Parameters (8) . . . . . . . . . . 48 3.3.10.5. Unresolvable Address (5) .................46
3.3.10.9. No User Data (9) . . . . . . . . . . . . . . . . 48 3.3.10.6. Unrecognized Chunk Type (6) ..............46
3.3.10.10. Cookie Received While Shutting Down (10) . . . . 49 3.3.10.7. Invalid Mandatory Parameter (7) ..........47
3.3.10.11. Restart of an Association with New Addresses 3.3.10.8. Unrecognized Parameters (8) ..............47
(11) . . . . . . . . . . . . . . . . . . . . . . 49 3.3.10.9. No User Data (9) .........................48
3.3.10.12. User-Initiated Abort (12) . . . . . . . . . . . 50 3.3.10.10. Cookie Received While Shutting
3.3.10.13. Protocol Violation (13) . . . . . . . . . . . . 50 Down (10) ...............................48
3.3.11. Cookie Echo (COOKIE ECHO) (10): . . . . . . . . . . . 51 3.3.10.11. Restart of an Association with
3.3.12. Cookie Acknowledgement (COOKIE ACK) (11): . . . . . . 52 New Addresses (11) ......................49
3.3.13. Shutdown Complete (SHUTDOWN COMPLETE) (14): . . . . . 52 3.3.10.12. User-Initiated Abort (12) ...............49
4. SCTP Association State Diagram . . . . . . . . . . . . . . . 53 3.3.10.13. Protocol Violation (13) .................50
5. Association Initialization . . . . . . . . . . . . . . . . . 56 3.3.11. Cookie Echo (COOKIE ECHO) (10) ....................50
5.1. Normal Establishment of an Association . . . . . . . . . 57 3.3.12. Cookie Acknowledgement (COOKIE ACK) (11) ..........51
5.1.1. Handle Stream Parameters . . . . . . . . . . . . . . 58 3.3.13. Shutdown Complete (SHUTDOWN COMPLETE) (14) ........51
5.1.2. Handle Address Parameters . . . . . . . . . . . . . . 59 4. SCTP Association State Diagram .................................52
5.1.3. Generating State Cookie . . . . . . . . . . . . . . . 61 5. Association Initialization .....................................56
5.1.4. State Cookie Processing . . . . . . . . . . . . . . . 62 5.1. Normal Establishment of an Association ....................56
5.1.5. State Cookie Authentication . . . . . . . . . . . . . 62 5.1.1. Handle Stream Parameters ...........................58
5.1.6. An Example of Normal Association Establishment . . . 63 5.1.2. Handle Address Parameters ..........................58
5.2. Handle Duplicate or Unexpected INIT, INIT ACK, COOKIE 5.1.3. Generating State Cookie ............................61
ECHO, and COOKIE ACK . . . . . . . . . . . . . . . . . . 65 5.1.4. State Cookie Processing ............................62
5.2.1. INIT received in COOKIE-WAIT or COOKIE-ECHOED 5.1.5. State Cookie Authentication ........................62
State (Item B) . . . . . . . . . . . . . . . . . . . 65 5.1.6. An Example of Normal Association Establishment .....64
5.2.2. Unexpected INIT in States Other than CLOSED, 5.2. Handle Duplicate or Unexpected INIT, INIT ACK,
COOKIE-ECHOED,COOKIE-WAIT and SHUTDOWN-ACK-SENT . . . 66 COOKIE ECHO, and ..........................................65
5.2.3. Unexpected INIT ACK . . . . . . . . . . . . . . . . . 67 5.2.1. INIT Received in COOKIE-WAIT or
5.2.4. Handle a COOKIE ECHO when a TCB exists . . . . . . . 67 COOKIE-ECHOED State (Item B) .......................66
5.2.5. Handle Duplicate COOKIE-ACK. . . . . . . . . . . . . 71 5.2.2. Unexpected INIT in States Other than
5.2.6. Handle Stale COOKIE Error . . . . . . . . . . . . . . 71 CLOSED, COOKIE-ECHOED, .............................66
5.3. Other Initialization Issues . . . . . . . . . . . . . . . 71 5.2.3. Unexpected INIT ACK ................................67
5.3.1. Selection of Tag Value . . . . . . . . . . . . . . . 71 5.2.4. Handle a COOKIE ECHO when a TCB Exists .............67
5.4. Path Verification . . . . . . . . . . . . . . . . . . . . 72 5.2.4.1. An Example of a Association Restart .......69
6. User Data Transfer . . . . . . . . . . . . . . . . . . . . . 73 5.2.5. Handle Duplicate COOKIE-ACK. .......................71
6.1. Transmission of DATA Chunks . . . . . . . . . . . . . . . 75 5.2.6. Handle Stale COOKIE Error ..........................71
6.2. Acknowledgement on Reception of DATA Chunks . . . . . . . 77 5.3. Other Initialization Issues ...............................72
6.2.1. Processing a Received SACK . . . . . . . . . . . . . 80 5.3.1. Selection of Tag Value .............................72
6.3. Management of Retransmission Timer . . . . . . . . . . . 82 5.4. Path Verification .........................................72
6.3.1. RTO Calculation . . . . . . . . . . . . . . . . . . . 82 6. User Data Transfer .............................................73
6.3.2. Retransmission Timer Rules . . . . . . . . . . . . . 83 6.1. Transmission of DATA Chunks ...............................75
6.3.3. Handle T3-rtx Expiration . . . . . . . . . . . . . . 85 6.2. Acknowledgement on Reception of DATA Chunks ...............78
6.4. Multi-homed SCTP Endpoints . . . . . . . . . . . . . . . 86 6.2.1. Processing a Received SACK .........................81
6.4.1. Failover from Inactive Destination Address . . . . . 87 6.3. Management of Retransmission Timer ........................83
6.5. Stream Identifier and Stream Sequence Number . . . . . . 87 6.3.1. RTO Calculation ....................................83
6.6. Ordered and Unordered Delivery . . . . . . . . . . . . . 87 6.3.2. Retransmission Timer Rules .........................85
6.7. Report Gaps in Received DATA TSNs . . . . . . . . . . . . 88 6.3.3. Handle T3-rtx Expiration ...........................86
6.8. CRC32c Checksum Calculation . . . . . . . . . . . . . . . 89 6.4. Multi-Homed SCTP Endpoints ................................87
6.9. Fragmentation and Reassembly . . . . . . . . . . . . . . 90 6.4.1. Failover from an Inactive Destination Address ......88
6.10. Bundling . . . . . . . . . . . . . . . . . . . . . . . . 91 6.5. Stream Identifier and Stream Sequence Number ..............88
7. Congestion control . . . . . . . . . . . . . . . . . . . . . 92 6.6. Ordered and Unordered Delivery ............................88
7.1. SCTP Differences from TCP Congestion control . . . . . . 93 6.7. Report Gaps in Received DATA TSNs .........................89
7.2. SCTP Slow-Start and Congestion Avoidance . . . . . . . . 94 6.8. CRC32c Checksum Calculation ...............................90
7.2.1. Slow-Start . . . . . . . . . . . . . . . . . . . . . 95 6.9. Fragmentation and Reassembly ..............................91
7.2.2. Congestion Avoidance . . . . . . . . . . . . . . . . 96 6.10. Bundling .................................................92
7.2.3. Congestion Control . . . . . . . . . . . . . . . . . 97 7. Congestion Control .............................................93
7.2.4. Fast Retransmit on Gap Reports . . . . . . . . . . . 97 7.1. SCTP Differences from TCP Congestion Control ..............94
7.3. Path MTU Discovery . . . . . . . . . . . . . . . . . . . 99 7.2. SCTP Slow-Start and Congestion Avoidance ..................95
8. Fault Management . . . . . . . . . . . . . . . . . . . . . . 99 7.2.1. Slow-Start .........................................96
8.1. Endpoint Failure Detection . . . . . . . . . . . . . . . 99 7.2.2. Congestion Avoidance ...............................97
8.2. Path Failure Detection . . . . . . . . . . . . . . . . . 100 7.2.3. Congestion Control .................................98
8.3. Path Heartbeat . . . . . . . . . . . . . . . . . . . . . 101 7.2.4. Fast Retransmit on Gap Reports .....................98
8.4. Handle "Out of the blue" Packets . . . . . . . . . . . . 103 7.3. Path MTU Discovery .......................................100
8.5. Verification Tag . . . . . . . . . . . . . . . . . . . . 104 8. Fault Management ..............................................100
8.5.1. Exceptions in Verification Tag Rules . . . . . . . . 104 8.1. Endpoint Failure Detection ...............................100
9. Termination of Association . . . . . . . . . . . . . . . . . 105 8.2. Path Failure Detection ...................................101
9.1. Abort of an Association . . . . . . . . . . . . . . . . . 106 8.3. Path Heartbeat ...........................................102
9.2. Shutdown of an Association . . . . . . . . . . . . . . . 106 8.4. Handle "Out of the Blue" Packets .........................104
10. Interface with Upper Layer . . . . . . . . . . . . . . . . . 109 8.5. Verification Tag .........................................105
10.1. ULP-to-SCTP . . . . . . . . . . . . . . . . . . . . . . . 109 8.5.1. Exceptions in Verification Tag Rules ..............105
10.2. SCTP-to-ULP . . . . . . . . . . . . . . . . . . . . . . . 120 9. Termination of Association ....................................106
11. Security Considerations . . . . . . . . . . . . . . . . . . . 123 9.1. Abort of an Association ..................................107
11.1. Security Objectives . . . . . . . . . . . . . . . . . . . 123 9.2. Shutdown of an Association ...............................107
11.2. SCTP Responses To Potential Threats . . . . . . . . . . . 123 10. Interface with Upper Layer ...................................110
11.2.1. Countering Insider Attacks . . . . . . . . . . . . . 124 10.1. ULP-to-SCTP .............................................110
11.2.2. Protecting against Data Corruption in the Network . . 124 10.2. SCTP-to-ULP .............................................120
11.2.3. Protecting Confidentiality . . . . . . . . . . . . . 124 11. Security Considerations ......................................123
11.2.4. Protecting against Blind Denial of Service Attacks . 125 11.1. Security Objectives .....................................123
11.2.4.1. Flooding . . . . . . . . . . . . . . . . . . . . 125 11.2. SCTP Responses to Potential Threats .....................124
11.2.4.2. Blind Masquerade . . . . . . . . . . . . . . . . 126 11.2.1. Countering Insider Attacks .......................124
11.2.4.3. Improper Monopolization of Services . . . . . . 127 11.2.2. Protecting against Data Corruption in the
11.3. SCTP Interactions with Firewalls . . . . . . . . . . . . 127 Network ..........................................124
11.4. Protection of Non-SCTP Capable Hosts. . . . . . . . . . . 127 11.2.3. Protecting Confidentiality .......................124
12. Network Management Considerations . . . . . . . . . . . . . . 128 11.2.4. Protecting against Blind
13. Recommended Transmission Control Block (TCB) Parameters . . . 128 Denial-of-Service Attacks ........................125
13.1. Parameters necessary for the SCTP instance . . . . . . . 129 11.2.4.1. Flooding ................................125
13.2. Parameters necessary per association (i.e. the TCB) . . . 129 11.2.4.2. Blind Masquerade ........................126
13.3. Per Transport Address Data . . . . . . . . . . . . . . . 131 11.2.4.3. Improper Monopolization of Services .....127
13.4. General Parameters Needed . . . . . . . . . . . . . . . . 132 11.3. SCTP Interactions with Firewalls ........................127
14. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 133 11.4. Protection of Non-SCTP-Capable Hosts ....................128
14.1. IETF-defined Chunk Extension . . . . . . . . . . . . . . 133 12. Network Management Considerations ............................128
14.2. IETF-defined Chunk Parameter Extension . . . . . . . . . 133 13. Recommended Transmission Control Block (TCB) Parameters ......129
14.3. IETF-defined Additional Error Causes . . . . . . . . . . 134 13.1. Parameters Necessary for the SCTP Instance ..............129
14.4. Payload Protocol Identifiers . . . . . . . . . . . . . . 134 13.2. Parameters Necessary per Association (i.e., the TCB) ....129
15. Suggested SCTP Protocol Parameter Values . . . . . . . . . . 135 13.3. Per Transport Address Data ..............................131
16. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 135 13.4. General Parameters Needed ...............................132
Appendix A. Explicit Congestion Notification . . . . . . . . . . 136 14. IANA Considerations ..........................................132
Appendix B. CRC32c Checksum Calculation . . . . . . . . . . . . 138 14.1. IETF-defined Chunk Extension ............................132
Appendix C. ICMP Handling . . . . . . . . . . . . . . . . . . . 140 14.2. IETF-Defined Chunk Parameter Extension ..................133
17. References . . . . . . . . . . . . . . . . . . . . . . . . . 146 14.3. IETF-Defined Additional Error Causes ....................133
17.1. Normative references . . . . . . . . . . . . . . . . . . 146 14.4. Payload Protocol Identifiers ............................134
17.2. Informative References . . . . . . . . . . . . . . . . . 147 14.5. Port Numbers Registry ...................................134
Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 148 15. Suggested SCTP Protocol Parameter Values .....................136
Intellectual Property and Copyright Statements . . . . . . . . . 150 16. Acknowledgements .............................................137
Appendix A. Explicit Congestion Notification .....................139
Appendix B. CRC32c Checksum Calculation ..........................140
Appendix C. ICMP Handling ........................................142
References .......................................................149
Normative References ..........................................149
Informative References ........................................150
1. Introduction 1. Introduction
This section explains the reasoning behind the development of the This section explains the reasoning behind the development of the
Stream Control Transmission Protocol (SCTP), the services it offers, Stream Control Transmission Protocol (SCTP), the services it offers,
and the basic concepts needed to understand the detailed description and the basic concepts needed to understand the detailed description
of the protocol. of the protocol.
This document obsoletes [RFC2960] and [RFC3309].
1.1. Motivation 1.1. Motivation
TCP [RFC0793] has performed immense service as the primary means of TCP [RFC0793] has performed immense service as the primary means of
reliable data transfer in IP networks. However, an increasing number reliable data transfer in IP networks. However, an increasing number
of recent applications have found TCP too limiting, and have of recent applications have found TCP too limiting, and have
incorporated their own reliable data transfer protocol on top of UDP incorporated their own reliable data transfer protocol on top of UDP
[RFC0768]. The limitations which users have wished to bypass include [RFC0768]. The limitations that users have wished to bypass include
the following: the following:
-- TCP provides both reliable data transfer and strict order-of- -- TCP provides both reliable data transfer and strict order-of-
transmission delivery of data. Some applications need reliable transmission delivery of data. Some applications need reliable
transfer without sequence maintenance, while others would be transfer without sequence maintenance, while others would be
satisfied with partial ordering of the data. In both of these satisfied with partial ordering of the data. In both of these
cases the head-of-line blocking offered by TCP causes unnecessary cases, the head-of-line blocking offered by TCP causes unnecessary
delay. delay.
-- The stream-oriented nature of TCP is often an inconvenience. -- The stream-oriented nature of TCP is often an inconvenience.
Applications must add their own record marking to delineate their Applications must add their own record marking to delineate their
messages, and must make explicit use of the push facility to messages, and must make explicit use of the push facility to
ensure that a complete message is transferred in a reasonable ensure that a complete message is transferred in a reasonable
time. time.
-- The limited scope of TCP sockets complicates the task of -- The limited scope of TCP sockets complicates the task of providing
providing highly-available data transfer capability using multi- highly-available data transfer capability using multi-homed hosts.
homed hosts.
-- TCP is relatively vulnerable to denial of service attacks, such -- TCP is relatively vulnerable to denial-of-service attacks, such as
as SYN attacks. SYN attacks.
Transport of PSTN signaling across the IP network is an application Transport of PSTN signaling across the IP network is an application
for which all of these limitations of TCP are relevant. While this for which all of these limitations of TCP are relevant. While this
application directly motivated the development of SCTP, other application directly motivated the development of SCTP, other
applications may find SCTP a good match to their requirements. applications may find SCTP a good match to their requirements.
1.2. Architectural View of SCTP 1.2. Architectural View of SCTP
SCTP is viewed as a layer between the SCTP user application ("SCTP SCTP is viewed as a layer between the SCTP user application ("SCTP
user" for short) and a connectionless packet network service such as user" for short) and a connectionless packet network service such as
IP. The remainder of this document assumes SCTP runs on top of IP. IP. The remainder of this document assumes SCTP runs on top of IP.
The basic service offered by SCTP is the reliable transfer of user The basic service offered by SCTP is the reliable transfer of user
messages between peer SCTP users. It performs this service within messages between peer SCTP users. It performs this service within
the context of an association between two SCTP endpoints. Section 10 the context of an association between two SCTP endpoints. Section 10
of this document sketches the API which should exist at the boundary of this document sketches the API that should exist at the boundary
between the SCTP and the SCTP user layers. between the SCTP and the SCTP user layers.
SCTP is connection-oriented in nature, but the SCTP association is a SCTP is connection-oriented in nature, but the SCTP association is a
broader concept than the TCP connection. SCTP provides the means for broader concept than the TCP connection. SCTP provides the means for
each SCTP endpoint (Section 1.3) to provide the other endpoint each SCTP endpoint (Section 1.3) to provide the other endpoint
(during association startup) with a list of transport addresses (during association startup) with a list of transport addresses
(i.e., multiple IP addresses in combination with an SCTP port) (i.e., multiple IP addresses in combination with an SCTP port)
through which that endpoint can be reached and from which it will through which that endpoint can be reached and from which it will
originate SCTP packets. The association spans transfers over all of originate SCTP packets. The association spans transfers over all of
the possible source/destination combinations which may be generated the possible source/destination combinations that may be generated
from each endpoint's lists. from each endpoint's lists.
_____________ _____________ _____________ _____________
| SCTP User | | SCTP User | | SCTP User | | SCTP User |
| Application | | Application | | Application | | Application |
|-------------| |-------------| |-------------| |-------------|
| SCTP | | SCTP | | SCTP | | SCTP |
| Transport | | Transport | | Transport | | Transport |
| Service | | Service | | Service | | Service |
|-------------| |-------------| |-------------| |-------------|
skipping to change at page 7, line 43 skipping to change at page 6, line 50
Figure 1: An SCTP Association Figure 1: An SCTP Association
1.3. Key Terms 1.3. Key Terms
Some of the language used to describe SCTP has been introduced in the Some of the language used to describe SCTP has been introduced in the
previous sections. This section provides a consolidated list of the previous sections. This section provides a consolidated list of the
key terms and their definitions. key terms and their definitions.
o Active destination transport address: A transport address on a o Active destination transport address: A transport address on a
peer endpoint which a transmitting endpoint considers available peer endpoint that a transmitting endpoint considers available for
for receiving user messages. receiving user messages.
o Bundling: An optional multiplexing operation, whereby more than o Bundling: An optional multiplexing operation, whereby more than
one user message may be carried in the same SCTP packet. Each one user message may be carried in the same SCTP packet. Each
user message occupies its own DATA chunk. user message occupies its own DATA chunk.
o Chunk: A unit of information within an SCTP packet, consisting of o Chunk: A unit of information within an SCTP packet, consisting of
a chunk header and chunk-specific content. a chunk header and chunk-specific content.
o Congestion Window (cwnd): An SCTP variable that limits the data, o Congestion window (cwnd): An SCTP variable that limits the data,
in number of bytes, a sender can send to a particular destination in number of bytes, a sender can send to a particular destination
transport address before receiving an acknowledgement. transport address before receiving an acknowledgement.
o Cumulative TSN Ack Point: The TSN of the last DATA chunk o Cumulative TSN Ack Point: The TSN of the last DATA chunk
acknowledged via the Cumulative TSN Ack field of a SACK. acknowledged via the Cumulative TSN Ack field of a SACK.
o Idle destination address: An address that has not had user o Idle destination address: An address that has not had user
messages sent to it within some length of time, normally the messages sent to it within some length of time, normally the
HEARTBEAT interval or greater. HEARTBEAT interval or greater.
o Inactive destination transport address: An address which is o Inactive destination transport address: An address that is
considered inactive due to errors and unavailable to transport considered inactive due to errors and unavailable to transport
user messages. user messages.
o Message = user message: Data submitted to SCTP by the Upper Layer o Message = user message: Data submitted to SCTP by the Upper Layer
Protocol (ULP). Protocol (ULP).
o Message Authentication Code (MAC): An integrity check mechanism o Message Authentication Code (MAC): An integrity check mechanism
based on cryptographic hash functions using a secret key. based on cryptographic hash functions using a secret key.
Typically, message authentication codes are used between two Typically, message authentication codes are used between two
parties that share a secret key in order to validate information parties that share a secret key in order to validate information
transmitted between these parties. In SCTP it is used by an transmitted between these parties. In SCTP, it is used by an
endpoint to validate the State Cookie information that is returned endpoint to validate the State Cookie information that is returned
from the peer in the COOKIE ECHO chunk. The term "MAC" has from the peer in the COOKIE ECHO chunk. The term "MAC" has
different meanings in different contexts. SCTP uses this term different meanings in different contexts. SCTP uses this term
with the same meaning as in [RFC2104]. with the same meaning as in [RFC2104].
o Network Byte Order: Most significant byte first, a.k.a., Big o Network Byte Order: Most significant byte first, a.k.a., big
Endian. endian.
o Ordered Message: A user message that is delivered in order with o Ordered Message: A user message that is delivered in order with
respect to all previous user messages sent within the stream the respect to all previous user messages sent within the stream on
message was sent on. which the message was sent.
o Outstanding TSN (at an SCTP endpoint): A TSN (and the associated o Outstanding TSN (at an SCTP endpoint): A TSN (and the associated
DATA chunk) that has been sent by the endpoint but for which it DATA chunk) that has been sent by the endpoint but for which it
has not yet received an acknowledgement. has not yet received an acknowledgement.
o Path: The route taken by the SCTP packets sent by one SCTP o Path: The route taken by the SCTP packets sent by one SCTP
endpoint to a specific destination transport address of its peer endpoint to a specific destination transport address of its peer
SCTP endpoint. Sending to different destination transport SCTP endpoint. Sending to different destination transport
addresses does not necessarily guarantee getting separate paths. addresses does not necessarily guarantee getting separate paths.
skipping to change at page 9, line 45 skipping to change at page 8, line 50
SCTP endpoint. SCTP endpoint.
o SCTP packet (or packet): The unit of data delivery across the o SCTP packet (or packet): The unit of data delivery across the
interface between SCTP and the connectionless packet network interface between SCTP and the connectionless packet network
(e.g., IP). An SCTP packet includes the common SCTP header, (e.g., IP). An SCTP packet includes the common SCTP header,
possible SCTP control chunks, and user data encapsulated within possible SCTP control chunks, and user data encapsulated within
SCTP DATA chunks. SCTP DATA chunks.
o SCTP user application (SCTP user): The logical higher-layer o SCTP user application (SCTP user): The logical higher-layer
application entity which uses the services of SCTP, also called application entity which uses the services of SCTP, also called
the Upper-layer Protocol (ULP). the Upper-Layer Protocol (ULP).
o Slow Start Threshold (ssthresh): An SCTP variable. This is the o Slow-Start Threshold (ssthresh): An SCTP variable. This is the
threshold which the endpoint will use to determine whether to threshold that the endpoint will use to determine whether to
perform slow start or congestion avoidance on a particular perform slow start or congestion avoidance on a particular
destination transport address. Ssthresh is in number of bytes. destination transport address. Ssthresh is in number of bytes.
o Stream: A uni-directional logical channel established from one to o Stream: A unidirectional logical channel established from one to
another associated SCTP endpoint, within which all user messages another associated SCTP endpoint, within which all user messages
are delivered in sequence except for those submitted to the are delivered in sequence except for those submitted to the
unordered delivery service. unordered delivery service.
Note: The relationship between stream numbers in opposite directions Note: The relationship between stream numbers in opposite directions
is strictly a matter of how the applications use them. It is the is strictly a matter of how the applications use them. It is the
responsibility of the SCTP user to create and manage these responsibility of the SCTP user to create and manage these
correlations if they are so desired. correlations if they are so desired.
o Stream Sequence Number: A 16-bit sequence number used internally o Stream Sequence Number: A 16-bit sequence number used internally
by SCTP to assure sequenced delivery of the user messages within a by SCTP to ensure sequenced delivery of the user messages within a
given stream. One stream sequence number is attached to each user given stream. One Stream Sequence Number is attached to each user
message. message.
o Tie-Tags: Two 32-bit random numbers that together make a 64- bit o Tie-Tags: Two 32-bit random numbers that together make a 64- bit
nonce. These Tags are used within a State Cookie and TCB so that nonce. These tags are used within a State Cookie and TCB so that
a newly restarting association can be linked to the original a newly restarting association can be linked to the original
association within the endpoint that did not restart and yet not association within the endpoint that did not restart and yet not
reveal the true Verification Tags of an existing association. reveal the true Verification Tags of an existing association.
o Transmission Control Block (TCB): An internal data structure o Transmission Control Block (TCB): An internal data structure
created by an SCTP endpoint for each of its existing SCTP created by an SCTP endpoint for each of its existing SCTP
associations to other SCTP endpoints. TCB contains all the status associations to other SCTP endpoints. TCB contains all the status
and operational information for the endpoint to maintain and and operational information for the endpoint to maintain and
manage the corresponding association. manage the corresponding association.
o Transmission Sequence Number (TSN): A 32-bit sequence number used o Transmission Sequence Number (TSN): A 32-bit sequence number used
internally by SCTP. One TSN is attached to each chunk containing internally by SCTP. One TSN is attached to each chunk containing
user data to permit the receiving SCTP endpoint to acknowledge its user data to permit the receiving SCTP endpoint to acknowledge its
receipt and detect duplicate deliveries. receipt and detect duplicate deliveries.
o Transport address: A Transport Address is traditionally defined by o Transport address: A transport address is traditionally defined by
Network Layer address, Transport Layer protocol and Transport a network-layer address, a transport-layer protocol, and a
Layer port number. In the case of SCTP running over IP, a transport-layer port number. In the case of SCTP running over IP,
transport address is defined by the combination of an IP address a transport address is defined by the combination of an IP address
and an SCTP port number (where SCTP is the Transport protocol). and an SCTP port number (where SCTP is the transport protocol).
o Unacknowledged TSN (at an SCTP endpoint): A TSN (and the o Unacknowledged TSN (at an SCTP endpoint): A TSN (and the
associated DATA chunk) which has been received by the endpoint but associated DATA chunk) that has been received by the endpoint but
for which an acknowledgement has not yet been sent. Or in the for which an acknowledgement has not yet been sent. Or in the
opposite case, for a packet that has been sent but no opposite case, for a packet that has been sent but no
acknowledgement has been received. acknowledgement has been received.
o Unordered Message: Unordered messages are "unordered" with respect o Unordered Message: Unordered messages are "unordered" with respect
to any other message, this includes both other unordered messages to any other message; this includes both other unordered messages
as well as other ordered messages. An unordered message might be as well as other ordered messages. An unordered message might be
delivered prior to or later than ordered messages sent on the same delivered prior to or later than ordered messages sent on the same
stream. stream.
o User message: The unit of data delivery across the interface o User message: The unit of data delivery across the interface
between SCTP and its user. between SCTP and its user.
o Verification Tag: A 32 bit unsigned integer that is randomly o Verification Tag: A 32-bit unsigned integer that is randomly
generated. The Verification Tag provides a key that allows a generated. The Verification Tag provides a key that allows a
receiver to verify that the SCTP packet belongs to the current receiver to verify that the SCTP packet belongs to the current
association and is not an old or stale packet from a previous association and is not an old or stale packet from a previous
association. association.
1.4. Abbreviations 1.4. Abbreviations
MAC - Message Authentication Code [RFC2104] MAC - Message Authentication Code [RFC2104]
RTO - Retransmission Time-out RTO - Retransmission Timeout
RTT - Round-trip Time RTT - Round-Trip Time
RTTVAR - Round-trip Time Variation RTTVAR - Round-Trip Time Variation
SCTP - Stream Control Transmission Protocol SCTP - Stream Control Transmission Protocol
SRTT - Smoothed RTT SRTT - Smoothed RTT
TCB - Transmission Control Block TCB - Transmission Control Block
TLV - Type-Length-Value Coding Format TLV - Type-Length-Value coding format
TSN - Transmission Sequence Number TSN - Transmission Sequence Number
ULP - Upper-layer Protocol ULP - Upper-Layer Protocol
1.5. Functional View of SCTP 1.5. Functional View of SCTP
The SCTP transport service can be decomposed into a number of The SCTP transport service can be decomposed into a number of
functions. These are depicted in Figure 2 and explained in the functions. These are depicted in Figure 2 and explained in the
remainder of this section. remainder of this section.
SCTP User Application SCTP User Application
----------------------------------------------------- -----------------------------------------------------
_____________ ____________________ _____________ ____________________
| | | Sequenced delivery | | | | Sequenced Delivery |
| Association | | within streams | | Association | | within Streams |
| | |____________________| | | |____________________|
| startup | | Startup |
| | ____________________________ | | ____________________________
| and | | User Data Fragmentation | | and | | User Data Fragmentation |
| | |____________________________| | | |____________________________|
| takedown | | Takedown |
| | ____________________________ | | ____________________________
| | | Acknowledgement | | | | Acknowledgement |
| | | and | | | | and |
| | | Congestion Avoidance | | | | Congestion Avoidance |
| | |____________________________| | | |____________________________|
| | | |
| | ____________________________ | | ____________________________
| | | Chunk Bundling | | | | Chunk Bundling |
| | |____________________________| | | |____________________________|
| | | |
skipping to change at page 13, line 20 skipping to change at page 12, line 20
endpoint performs a shutdown, the association on each peer will stop endpoint performs a shutdown, the association on each peer will stop
accepting new data from its user and only deliver data in queue at accepting new data from its user and only deliver data in queue at
the time of the graceful close (see Section 9 ). the time of the graceful close (see Section 9 ).
1.5.2. Sequenced Delivery within Streams 1.5.2. Sequenced Delivery within Streams
The term "stream" is used in SCTP to refer to a sequence of user The term "stream" is used in SCTP to refer to a sequence of user
messages that are to be delivered to the upper-layer protocol in messages that are to be delivered to the upper-layer protocol in
order with respect to other messages within the same stream. This is order with respect to other messages within the same stream. This is
in contrast to its usage in TCP, where it refers to a sequence of in contrast to its usage in TCP, where it refers to a sequence of
bytes (in this document a byte is assumed to be eight bits). bytes (in this document, a byte is assumed to be 8 bits).
The SCTP user can specify at association startup time the number of The SCTP user can specify at association startup time the number of
streams to be supported by the association. This number is streams to be supported by the association. This number is
negotiated with the remote end (see Section 5.1.1). User messages negotiated with the remote end (see Section 5.1.1). User messages
are associated with stream numbers (SEND, RECEIVE primitives, are associated with stream numbers (SEND, RECEIVE primitives, Section
Section 10). Internally, SCTP assigns a stream sequence number to 10). Internally, SCTP assigns a Stream Sequence Number to each
each message passed to it by the SCTP user. On the receiving side, message passed to it by the SCTP user. On the receiving side, SCTP
SCTP ensures that messages are delivered to the SCTP user in sequence ensures that messages are delivered to the SCTP user in sequence
within a given stream. However, while one stream may be blocked within a given stream. However, while one stream may be blocked
waiting for the next in-sequence user message, delivery from other waiting for the next in-sequence user message, delivery from other
streams may proceed. streams may proceed.
SCTP provides a mechanism for bypassing the sequenced delivery SCTP provides a mechanism for bypassing the sequenced delivery
service. User messages sent using this mechanism are delivered to service. User messages sent using this mechanism are delivered to
the SCTP user as soon as they are received. the SCTP user as soon as they are received.
1.5.3. User Data Fragmentation 1.5.3. User Data Fragmentation
When needed, SCTP fragments user messages to ensure that the SCTP When needed, SCTP fragments user messages to ensure that the SCTP
packet passed to the lower layer conforms to the path MTU. On packet passed to the lower layer conforms to the path MTU. On
receipt, fragments are reassembled into complete messages before receipt, fragments are reassembled into complete messages before
being passed to the SCTP user. being passed to the SCTP user.
1.5.4. Acknowledgement and Congestion Avoidance 1.5.4. Acknowledgement and Congestion Avoidance
SCTP assigns a Transmission Sequence Number (TSN) to each user data SCTP assigns a Transmission Sequence Number (TSN) to each user data
fragment or unfragmented message. The TSN is independent of any fragment or unfragmented message. The TSN is independent of any
stream sequence number assigned at the stream level. The receiving Stream Sequence Number assigned at the stream level. The receiving
end acknowledges all TSNs received, even if there are gaps in the end acknowledges all TSNs received, even if there are gaps in the
sequence. In this way, reliable delivery is kept functionally sequence. In this way, reliable delivery is kept functionally
separate from sequenced stream delivery. separate from sequenced stream delivery.
The acknowledgement and congestion avoidance function is responsible The acknowledgement and congestion avoidance function is responsible
for packet retransmission when timely acknowledgement has not been for packet retransmission when timely acknowledgement has not been
received. Packet retransmission is conditioned by congestion received. Packet retransmission is conditioned by congestion
avoidance procedures similar to those used for TCP. See Section 6 avoidance procedures similar to those used for TCP. See Section 6
and Section 7 for a detailed description of the protocol procedures and Section 7 for a detailed description of the protocol procedures
associated with this function. associated with this function.
1.5.5. Chunk Bundling 1.5.5. Chunk Bundling
As described in Section 3, the SCTP packet as delivered to the lower As described in Section 3, the SCTP packet as delivered to the lower
layer consists of a common header followed by one or more chunks. layer consists of a common header followed by one or more chunks.
Each chunk may contain either user data or SCTP control information. Each chunk may contain either user data or SCTP control information.
The SCTP user has the option to request bundling of more than one The SCTP user has the option to request bundling of more than one
user messages into a single SCTP packet. The chunk bundling function user message into a single SCTP packet. The chunk bundling function
of SCTP is responsible for assembly of the complete SCTP packet and of SCTP is responsible for assembly of the complete SCTP packet and
its disassembly at the receiving end. its disassembly at the receiving end.
During times of congestion an SCTP implementation MAY still perform During times of congestion, an SCTP implementation MAY still perform
bundling even if the user has requested that SCTP not bundle. The bundling even if the user has requested that SCTP not bundle. The
user's disabling of bundling only affects SCTP implementations that user's disabling of bundling only affects SCTP implementations that
may delay a small period of time before transmission (to attempt to may delay a small period of time before transmission (to attempt to
encourage bundling). When the user layer disables bundling, this encourage bundling). When the user layer disables bundling, this
small delay is prohibited but not bundling that is performed during small delay is prohibited but not bundling that is performed during
congestion or retransmission. congestion or retransmission.
1.5.6. Packet Validation 1.5.6. Packet Validation
A mandatory Verification Tag field and a 32 bit checksum field (see A mandatory Verification Tag field and a 32-bit checksum field (see
Appendix B for a description of the CRC32c checksum) are included in Appendix B for a description of the CRC32c checksum) are included in
the SCTP common header. The Verification Tag value is chosen by each the SCTP common header. The Verification Tag value is chosen by each
end of the association during association startup. Packets received end of the association during association startup. Packets received
without the expected Verification Tag value are discarded, as a without the expected Verification Tag value are discarded, as a
protection against blind masquerade attacks and against stale SCTP protection against blind masquerade attacks and against stale SCTP
packets from a previous association. The CRC32c checksum should be packets from a previous association. The CRC32c checksum should be
set by the sender of each SCTP packet to provide additional set by the sender of each SCTP packet to provide additional
protection against data corruption in the network. The receiver of protection against data corruption in the network. The receiver of
an SCTP packet with an invalid CRC32c checksum silently discards the an SCTP packet with an invalid CRC32c checksum silently discards the
packet. packet.
skipping to change at page 15, line 11 skipping to change at page 14, line 11
SCTP packet based on the SCTP user's instructions and the currently SCTP packet based on the SCTP user's instructions and the currently
perceived reachability status of the eligible destination set. The perceived reachability status of the eligible destination set. The
path management function monitors reachability through heartbeats path management function monitors reachability through heartbeats
when other packet traffic is inadequate to provide this information when other packet traffic is inadequate to provide this information
and advises the SCTP user when reachability of any far-end transport and advises the SCTP user when reachability of any far-end transport
address changes. The path management function is also responsible address changes. The path management function is also responsible
for reporting the eligible set of local transport addresses to the for reporting the eligible set of local transport addresses to the
far end during association startup, and for reporting the transport far end during association startup, and for reporting the transport
addresses returned from the far end to the SCTP user. addresses returned from the far end to the SCTP user.
At association start-up, a primary path is defined for each SCTP At association startup, a primary path is defined for each SCTP
endpoint, and is used for normal sending of SCTP packets. endpoint, and is used for normal sending of SCTP packets.
On the receiving end, the path management is responsible for On the receiving end, the path management is responsible for
verifying the existence of a valid SCTP association to which the verifying the existence of a valid SCTP association to which the
inbound SCTP packet belongs before passing it for further processing. inbound SCTP packet belongs before passing it for further processing.
Note: Path Management and Packet Validation are done at the same Note: Path Management and Packet Validation are done at the same
time, so although described separately above, in reality they cannot time, so although described separately above, in reality they cannot
be performed as separate items. be performed as separate items.
skipping to change at page 15, line 47 skipping to change at page 14, line 47
An endpoint SHOULD NOT transmit a DATA chunk with a TSN that is more An endpoint SHOULD NOT transmit a DATA chunk with a TSN that is more
than 2**31 - 1 above the beginning TSN of its current send window. than 2**31 - 1 above the beginning TSN of its current send window.
Doing so will cause problems in comparing TSNs. Doing so will cause problems in comparing TSNs.
Transmission Sequence Numbers wrap around when they reach 2**32 - 1. Transmission Sequence Numbers wrap around when they reach 2**32 - 1.
That is, the next TSN a DATA chunk MUST use after transmitting TSN = That is, the next TSN a DATA chunk MUST use after transmitting TSN =
2*32 - 1 is TSN = 0. 2*32 - 1 is TSN = 0.
Any arithmetic done on Stream Sequence Numbers SHOULD use Serial Any arithmetic done on Stream Sequence Numbers SHOULD use Serial
Number Arithmetic as defined in [RFC1982] where SERIAL_BITS = 16. Number Arithmetic as defined in [RFC1982] where SERIAL_BITS = 16.
All other arithmetic and comparisons in this document uses normal All other arithmetic and comparisons in this document use normal
arithmetic. arithmetic.
1.7. Changes from RFC2960 1.7. Changes from RFC2960
SCTP was originally defined in [RFC2960] which this document SCTP was originally defined in [RFC2960], which this document
obsoletes. Readers interested in the details of the various changes obsoletes. Readers interested in the details of the various changes
that this document incorporates are asked to consult [RFC4460]. that this document incorporates are asked to consult [RFC4460].
2. Conventions 2. Conventions
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
"SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
document are to be interpreted as described in RFC2119 [RFC2119]. document are to be interpreted as described in RFC2119 [RFC2119].
3. SCTP packet Format 3. SCTP Packet Format
An SCTP packet is composed of a common header and chunks. A chunk An SCTP packet is composed of a common header and chunks. A chunk
contains either control information or user data. contains either control information or user data.
The SCTP packet format is shown below: The SCTP packet format is shown below:
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Common Header | | Common Header |
skipping to change at page 17, line 23 skipping to change at page 16, line 23
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Verification Tag | | Verification Tag |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Checksum | | Checksum |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Source Port Number: 16 bits (unsigned integer) Source Port Number: 16 bits (unsigned integer)
This is the SCTP sender's port number. It can be used by the This is the SCTP sender's port number. It can be used by the
receiver in combination with the source IP address, the SCTP receiver in combination with the source IP address, the SCTP
destination port and possibly the destination IP address to destination port, and possibly the destination IP address to
identify the association to which this packet belongs. The port identify the association to which this packet belongs. The port
number 0 MUST NOT be used. number 0 MUST NOT be used.
Destination Port Number: 16 bits (unsigned integer) Destination Port Number: 16 bits (unsigned integer)
This is the SCTP port number to which this packet is destined. This is the SCTP port number to which this packet is destined.
The receiving host will use this port number to de-multiplex the The receiving host will use this port number to de-multiplex the
SCTP packet to the correct receiving endpoint/application. The SCTP packet to the correct receiving endpoint/application. The
port number 0 MUST NOT be used. port number 0 MUST NOT be used.
skipping to change at page 17, line 41 skipping to change at page 16, line 41
SCTP packet to the correct receiving endpoint/application. The SCTP packet to the correct receiving endpoint/application. The
port number 0 MUST NOT be used. port number 0 MUST NOT be used.
Verification Tag: 32 bits (unsigned integer) Verification Tag: 32 bits (unsigned integer)
The receiver of this packet uses the Verification Tag to validate The receiver of this packet uses the Verification Tag to validate
the sender of this SCTP packet. On transmit, the value of this the sender of this SCTP packet. On transmit, the value of this
Verification Tag MUST be set to the value of the Initiate Tag Verification Tag MUST be set to the value of the Initiate Tag
received from the peer endpoint during the association received from the peer endpoint during the association
initialization, with the following exceptions: initialization, with the following exceptions:
- A packet containing an INIT chunk MUST have a zero Verification - A packet containing an INIT chunk MUST have a zero Verification
Tag. Tag.
- A packet containing a SHUTDOWN-COMPLETE chunk with the T-bit - A packet containing a SHUTDOWN COMPLETE chunk with the T bit
set MUST have the Verification Tag copied from the packet with set MUST have the Verification Tag copied from the packet with
the SHUTDOWN-ACK chunk. the SHUTDOWN ACK chunk.
- A packet containing an ABORT chunk may have the verification - A packet containing an ABORT chunk may have the verification
tag copied from the packet which caused the ABORT to be sent. tag copied from the packet that caused the ABORT to be sent.
For details see Section 8.4 and Section 8.5. For details see Section 8.4 and Section 8.5.
An INIT chunk MUST be the only chunk in the SCTP packet carrying
it. An INIT chunk MUST be the only chunk in the SCTP packet carrying it.
Checksum: 32 bits (unsigned integer) Checksum: 32 bits (unsigned integer)
This field contains the checksum of this SCTP packet. Its This field contains the checksum of this SCTP packet. Its
calculation is discussed in Section 6.8. SCTP uses the CRC32c calculation is discussed in Section 6.8. SCTP uses the CRC32c
algorithm as described in Appendix B for calculating the checksum algorithm as described in Appendix B for calculating the checksum.
3.2. Chunk Field Descriptions 3.2. Chunk Field Descriptions
The figure below illustrates the field format for the chunks to be The figure below illustrates the field format for the chunks to be
transmitted in the SCTP packet. Each chunk is formatted with a Chunk transmitted in the SCTP packet. Each chunk is formatted with a Chunk
Type field, a chunk-specific Flag field, a Chunk Length field, and a Type field, a chunk-specific Flag field, a Chunk Length field, and a
Value field. Value field.
0 1 2 3 0 1 2 3
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 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
skipping to change at page 19, line 19 skipping to change at page 18, line 4
2 - Initiation Acknowledgement (INIT ACK) 2 - Initiation Acknowledgement (INIT ACK)
3 - Selective Acknowledgement (SACK) 3 - Selective Acknowledgement (SACK)
4 - Heartbeat Request (HEARTBEAT) 4 - Heartbeat Request (HEARTBEAT)
5 - Heartbeat Acknowledgement (HEARTBEAT ACK) 5 - Heartbeat Acknowledgement (HEARTBEAT ACK)
6 - Abort (ABORT) 6 - Abort (ABORT)
7 - Shutdown (SHUTDOWN) 7 - Shutdown (SHUTDOWN)
8 - Shutdown Acknowledgement (SHUTDOWN ACK) 8 - Shutdown Acknowledgement (SHUTDOWN ACK)
9 - Operation Error (ERROR) 9 - Operation Error (ERROR)
10 - State Cookie (COOKIE ECHO) 10 - State Cookie (COOKIE ECHO)
11 - Cookie Acknowledgement (COOKIE ACK) 11 - Cookie Acknowledgement (COOKIE ACK)
12 - Reserved for Explicit Congestion Notification Echo (ECNE) 12 - Reserved for Explicit Congestion Notification Echo
(ECNE)
13 - Reserved for Congestion Window Reduced (CWR) 13 - Reserved for Congestion Window Reduced (CWR)
14 - Shutdown Complete (SHUTDOWN COMPLETE) 14 - Shutdown Complete (SHUTDOWN COMPLETE)
15 to 62 - reserved by IETF 15 to 62 - available
63 - IETF-defined Chunk Extensions 63 - reserved for IETF-defined Chunk Extensions
64 to 126 - reserved by IETF 64 to 126 - available
127 - IETF-defined Chunk Extensions 127 - reserved for IETF-defined Chunk Extensions
128 to 190 - reserved by IETF 128 to 190 - available
191 - IETF-defined Chunk Extensions 191 - reserved for IETF-defined Chunk Extensions
192 to 254 - reserved by IETF 192 to 254 - available
255 - IETF-defined Chunk Extensions 255 - reserved for IETF-defined Chunk Extensions
Chunk Types are encoded such that the highest-order two bits Chunk Types are encoded such that the highest-order 2 bits specify
specify the action that must be taken if the processing endpoint the action that must be taken if the processing endpoint does not
does not recognize the Chunk Type. recognize the Chunk Type.
00 - Stop processing this SCTP packet and discard it, do not 00 - Stop processing this SCTP packet and discard it, do not
process any further chunks within it. process any further chunks within it.
01 - Stop processing this SCTP packet and discard it, do not 01 - Stop processing this SCTP packet and discard it, do not
process any further chunks within it, and report the process any further chunks within it, and report the
unrecognized chunk in an 'Unrecognized Chunk Type'. unrecognized chunk in an 'Unrecognized Chunk Type'.
10 - Skip this chunk and continue processing. 10 - Skip this chunk and continue processing.
11 - Skip this chunk and continue processing, but report in an 11 - Skip this chunk and continue processing, but report in an
ERROR Chunk using the 'Unrecognized Chunk Type' cause of ERROR chunk using the 'Unrecognized Chunk Type' cause of
error. error.
Note: The ECNE and CWR chunk types are reserved for future use of Note: The ECNE and CWR chunk types are reserved for future use of
Explicit Congestion Notification (ECN) - see Appendix A. Explicit Congestion Notification (ECN); see Appendix A.
Chunk Flags: 8 bits Chunk Flags: 8 bits
The usage of these bits depends on the chunk type as given by the
Chunk Type. Unless otherwise specified, they are set to zero on The usage of these bits depends on the Chunk type as given by the
transmit and are ignored on receipt. Chunk Type field. Unless otherwise specified, they are set to 0
on transmit and are ignored on receipt.
Chunk Length: 16 bits (unsigned integer) Chunk Length: 16 bits (unsigned integer)
This value represents the size of the chunk in bytes, including This value represents the size of the chunk in bytes, including
the Chunk Type, Chunk Flags, Chunk Length, and Chunk Value fields. the Chunk Type, Chunk Flags, Chunk Length, and Chunk Value fields.
Therefore, if the Chunk Value field is zero-length, the Length Therefore, if the Chunk Value field is zero-length, the Length
field will be set to 4. The Chunk Length field does not count any field will be set to 4. The Chunk Length field does not count any
chunk padding. chunk padding.
Chunks (including Type, Length, and Value fields) are padded out Chunks (including Type, Length, and Value fields) are padded out
by the sender with all zero bytes to be a multiple of 4 bytes by the sender with all zero bytes to be a multiple of 4 bytes
long. This padding MUST NOT be more than 3 bytes in total. The long. This padding MUST NOT be more than 3 bytes in total. The
Chunk Length value does not include terminating padding of the Chunk Length value does not include terminating padding of the
chunk. However, it does include padding of any variable-length chunk. However, it does include padding of any variable-length
parameter except the last parameter in the chunk. The receiver parameter except the last parameter in the chunk. The receiver
MUST ignore the padding. MUST ignore the padding.
Note: A robust implementation should accept the Chunk whether or Note: A robust implementation should accept the chunk whether or
not the final padding has been included in the Chunk Length. not the final padding has been included in the Chunk Length.
Chunk Value: variable length Chunk Value: variable length
The Chunk Value field contains the actual information to be The Chunk Value field contains the actual information to be
transferred in the chunk. The usage and format of this field is transferred in the chunk. The usage and format of this field is
dependent on the Chunk Type. dependent on the Chunk Type.
The total length of a chunk (including Type, Length, and Value The total length of a chunk (including Type, Length, and Value
fields) MUST be a multiple of 4 bytes. If the length of the chunk is fields) MUST be a multiple of 4 bytes. If the length of the chunk is
not a multiple of 4 bytes, the sender MUST pad the chunk with all not a multiple of 4 bytes, the sender MUST pad the chunk with all
zero bytes, and this padding is not included in the chunk length zero bytes, and this padding is not included in the Chunk Length
field. The sender MUST NOT pad with more than 3 bytes. The receiver field. The sender MUST NOT pad with more than 3 bytes. The receiver
MUST ignore the padding bytes. MUST ignore the padding bytes.
SCTP defined chunks are described in detail in Section 3.3. The SCTP-defined chunks are described in detail in Section 3.3. The
guidelines for IETF-defined chunk extensions can be found in guidelines for IETF-defined chunk extensions can be found in Section
Section 14.1 of this document. 14.1 of this document.
3.2.1. Optional/Variable-length Parameter Format 3.2.1. Optional/Variable-Length Parameter Format
Chunk values of SCTP control chunks consist of a chunk-type-specific Chunk values of SCTP control chunks consist of a chunk-type-specific
header of required fields, followed by zero or more parameters. The header of required fields, followed by zero or more parameters. The
optional and variable-length parameters contained in a chunk are optional and variable-length parameters contained in a chunk are
defined in a Type-Length-Value format as shown below. defined in a Type-Length-Value format as shown below.
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Parameter Type | Parameter Length | | Parameter Type | Parameter Length |
skipping to change at page 21, line 14 skipping to change at page 20, line 4
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Parameter Type | Parameter Length | | Parameter Type | Parameter Length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\ \ \ \
/ Parameter Value / / Parameter Value /
\ \ \ \
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Chunk Parameter Type: 16 bits (unsigned integer) Chunk Parameter Type: 16 bits (unsigned integer)
The Type field is a 16 bit identifier of the type of parameter. The Type field is a 16-bit identifier of the type of parameter.
It takes a value of 0 to 65534. It takes a value of 0 to 65534.
The value of 65535 is reserved for IETF-defined extensions. The value of 65535 is reserved for IETF-defined extensions.
Values other than those defined in specific SCTP chunk description Values other than those defined in specific SCTP chunk
are reserved for use by IETF. descriptions are reserved for use by IETF.
Chunk Parameter Length: 16 bits (unsigned integer) Chunk Parameter Length: 16 bits (unsigned integer)
The Parameter Length field contains the size of the parameter in The Parameter Length field contains the size of the parameter in
bytes, including the Parameter Type, Parameter Length, and bytes, including the Parameter Type, Parameter Length, and
Parameter Value fields. Thus, a parameter with a zero-length Parameter Value fields. Thus, a parameter with a zero-length
Parameter Value field would have a Length field of 4. The Parameter Value field would have a Length field of 4. The
Parameter Length does not include any padding bytes. Parameter Length does not include any padding bytes.
Chunk Parameter Value: variable-length. Chunk Parameter Value: variable length
The Parameter Value field contains the actual information to be The Parameter Value field contains the actual information to be
transferred in the parameter. transferred in the parameter.
The total length of a parameter (including Type, Parameter Length The total length of a parameter (including Type, Parameter Length,
and Value fields) MUST be a multiple of 4 bytes. If the length of and Value fields) MUST be a multiple of 4 bytes. If the length of
the parameter is not a multiple of 4 bytes, the sender pads the the parameter is not a multiple of 4 bytes, the sender pads the
Parameter at the end (i.e., after the Parameter Value field) with parameter at the end (i.e., after the Parameter Value field) with
all zero bytes. The length of the padding is not included in the all zero bytes. The length of the padding is not included in the
parameter length field. A sender MUST NOT pad with more than 3 Parameter Length field. A sender MUST NOT pad with more than 3
bytes. The receiver MUST ignore the padding bytes. bytes. The receiver MUST ignore the padding bytes.
The Parameter Types are encoded such that the highest-order two The Parameter Types are encoded such that the highest-order 2 bits
bits specify the action that must be taken if the processing specify the action that must be taken if the processing endpoint
endpoint does not recognize the Parameter Type. does not recognize the Parameter Type.
00 - Stop processing this parameter; do not process any further 00 - Stop processing this parameter; do not process any further
parameters within this chunk. parameters within this chunk.
01 - Stop processing this parameter, do not process any further 01 - Stop processing this parameter, do not process any further
parameters within this chunk, and report the unrecognized parameters within this chunk, and report the unrecognized
parameter in an 'Unrecognized Parameter', as described in parameter in an 'Unrecognized Parameter', as described in
Section 3.2.2. Section 3.2.2.
10 - Skip this parameter and continue processing. 10 - Skip this parameter and continue processing.
11 - Skip this parameter and continue processing but report the 11 - Skip this parameter and continue processing but report the
unrecognized parameter in an 'Unrecognized Parameter', as unrecognized parameter in an 'Unrecognized Parameter', as
described in Section 3.2.2. described in Section 3.2.2.
Please note that in all four cases an INIT-ACK or COOKIE-ECHO chunk Please note that in all four cases, an INIT ACK or COOKIE ECHO chunk
is sent. In the 00 or 01 case the processing of the parameters after is sent. In the 00 or 01 case, the processing of the parameters
the unknown parameter is canceled, but no processing already done is after the unknown parameter is canceled, but no processing already
rolled back. done is rolled back.
The actual SCTP parameters are defined in the specific SCTP chunk The actual SCTP parameters are defined in the specific SCTP chunk
sections. The rules for IETF-defined parameter extensions are sections. The rules for IETF-defined parameter extensions are
defined in Section 14.2. Note that a parameter type MUST be unique defined in Section 14.2. Note that a parameter type MUST be unique
across all chunks. For example, the parameter type '5' is used to across all chunks. For example, the parameter type '5' is used to
represent an IPv4 address (see Section 3.2.2). The value '5' then is represent an IPv4 address (see Section 3.3.2.1). The value '5' then
reserved across all chunks to represent an IPv4 address and MUST NOT is reserved across all chunks to represent an IPv4 address and MUST
be reused with a different meaning in any other chunk. NOT be reused with a different meaning in any other chunk.
3.2.2. Reporting of Unrecognized Parameters 3.2.2. Reporting of Unrecognized Parameters
If the receiver of an INIT chunk detects unrecognized parameters and If the receiver of an INIT chunk detects unrecognized parameters and
has to report them according to Section 3.2.1, it MUST put the has to report them according to Section 3.2.1, it MUST put the
'Unrecognized Parameter' parameter(s) in the INIT-ACK chunk sent in 'Unrecognized Parameter' parameter(s) in the INIT ACK chunk sent in
response to the INIT-chunk. Note that if the receiver of the INIT response to the INIT chunk. Note that if the receiver of the INIT
chunk is NOT going to establish an association (e.g., due to lack of chunk is NOT going to establish an association (e.g., due to lack of
resources), an 'Unrecognized Parameter' would NOT be included with resources), an 'Unrecognized Parameter' would NOT be included with
any ABORT being sent to the sender of the INIT. any ABORT being sent to the sender of the INIT.
If the receiver of an INIT-ACK chunk detects unrecognized parameters If the receiver of an INIT ACK chunk detects unrecognized parameters
and has to report them according to Section 3.2.1, it SHOULD bundle and has to report them according to Section 3.2.1, it SHOULD bundle
the ERROR chunk containing the 'Unrecognized Parameters' error cause the ERROR chunk containing the 'Unrecognized Parameters' error cause
with the COOKIE-ECHO chunk sent in response to the INIT-ACK chunk. with the COOKIE ECHO chunk sent in response to the INIT ACK chunk.
If the receiver of the INIT-ACK cannot bundle the COOKIE-ECHO chunk If the receiver of the INIT ACK cannot bundle the COOKIE ECHO chunk
with the ERROR chunk, the ERROR chunk MAY be sent separately but not with the ERROR chunk, the ERROR chunk MAY be sent separately but not
before the COOKIE-ACK has been received. before the COOKIE ACK has been received.
Note: Any time a COOKIE-ECHO is sent in a packet, it MUST be the Note: Any time a COOKIE ECHO is sent in a packet, it MUST be the
first chunk. first chunk.
3.3. SCTP Chunk Definitions 3.3. SCTP Chunk Definitions
This section defines the format of the different SCTP chunk types. This section defines the format of the different SCTP chunk types.
3.3.1. Payload Data (DATA) (0) 3.3.1. Payload Data (DATA) (0)
The following format MUST be used for the DATA chunk: The following format MUST be used for the DATA chunk:
skipping to change at page 23, line 40 skipping to change at page 22, line 36
Should be set to all '0's and ignored by the receiver. Should be set to all '0's and ignored by the receiver.
U bit: 1 bit U bit: 1 bit
The (U)nordered bit, if set to '1', indicates that this is an The (U)nordered bit, if set to '1', indicates that this is an
unordered DATA chunk, and there is no Stream Sequence Number unordered DATA chunk, and there is no Stream Sequence Number
assigned to this DATA chunk. Therefore, the receiver MUST ignore assigned to this DATA chunk. Therefore, the receiver MUST ignore
the Stream Sequence Number field. the Stream Sequence Number field.
After re-assembly (if necessary), unordered DATA chunks MUST be After reassembly (if necessary), unordered DATA chunks MUST be
dispatched to the upper layer by the receiver without any attempt dispatched to the upper layer by the receiver without any attempt
to re-order. to reorder.
If an unordered user message is fragmented, each fragment of the If an unordered user message is fragmented, each fragment of the
message MUST have its U bit set to '1'. message MUST have its U bit set to '1'.
B bit: 1 bit B bit: 1 bit
The (B)eginning fragment bit, if set, indicates the first fragment The (B)eginning fragment bit, if set, indicates the first fragment
of a user message. of a user message.
E bit: 1 bit E bit: 1 bit
skipping to change at page 24, line 22 skipping to change at page 23, line 17
a multi-fragment user message, as summarized in the following table: a multi-fragment user message, as summarized in the following table:
B E Description B E Description
============================================================ ============================================================
| 1 0 | First piece of a fragmented user message | | 1 0 | First piece of a fragmented user message |
+----------------------------------------------------------+ +----------------------------------------------------------+
| 0 0 | Middle piece of a fragmented user message | | 0 0 | Middle piece of a fragmented user message |
+----------------------------------------------------------+ +----------------------------------------------------------+
| 0 1 | Last piece of a fragmented user message | | 0 1 | Last piece of a fragmented user message |
+----------------------------------------------------------+ +----------------------------------------------------------+
| 1 1 | Unfragmented Message | | 1 1 | Unfragmented message |
============================================================ ============================================================
| Table 1: Fragment Description Flags | | Table 1: Fragment Description Flags |
============================================================ ============================================================
When a user message is fragmented into multiple chunks, the TSNs are When a user message is fragmented into multiple chunks, the TSNs are
used by the receiver to reassemble the message. This means that the used by the receiver to reassemble the message. This means that the
TSNs for each fragment of a fragmented user message MUST be strictly TSNs for each fragment of a fragmented user message MUST be strictly
sequential. sequential.
Length: 16 bits (unsigned integer) Length: 16 bits (unsigned integer)
This field indicates the length of the DATA chunk in bytes from This field indicates the length of the DATA chunk in bytes from
the beginning of the type field to the end of the user data field the beginning of the type field to the end of the User Data field
excluding any padding. A DATA chunk with one byte of user data excluding any padding. A DATA chunk with one byte of user data
will have Length set to 17 (indicating 17 bytes). will have Length set to 17 (indicating 17 bytes).
A DATA chunk with a user data field of length L will have the A DATA chunk with a User Data field of length L will have the
length field set to (16 + L) (indicating 16+L bytes) where L MUST Length field set to (16 + L) (indicating 16+L bytes) where L MUST
be greater than 0. be greater than 0.
TSN : 32 bits (unsigned integer) TSN : 32 bits (unsigned integer)
This value represents the TSN for this DATA chunk. The valid This value represents the TSN for this DATA chunk. The valid
range of TSN is from 0 to 4294967295 (2**32 - 1). TSN wraps back range of TSN is from 0 to 4294967295 (2**32 - 1). TSN wraps back
to 0 after reaching 4294967295. to 0 after reaching 4294967295.
Stream Identifier S: 16 bits (unsigned integer) Stream Identifier S: 16 bits (unsigned integer)
Identifies the stream to which the following user data belongs. Identifies the stream to which the following user data belongs.
Stream Sequence Number n: 16 bits (unsigned integer) Stream Sequence Number n: 16 bits (unsigned integer)
This value represents the stream sequence number of the following This value represents the Stream Sequence Number of the following
user data within the stream S. Valid range is 0 to 65535. user data within the stream S. Valid range is 0 to 65535.
When a user message is fragmented by SCTP for transport, the same When a user message is fragmented by SCTP for transport, the same
stream sequence number MUST be carried in each of the fragments of Stream Sequence Number MUST be carried in each of the fragments of
the message. the message.
Payload Protocol Identifier: 32 bits (unsigned integer) Payload Protocol Identifier: 32 bits (unsigned integer)
This value represents an application (or upper layer) specified This value represents an application (or upper layer) specified
protocol identifier. This value is passed to SCTP by its upper protocol identifier. This value is passed to SCTP by its upper
layer and sent to its peer. This identifier is not used by SCTP layer and sent to its peer. This identifier is not used by SCTP
but can be used by certain network entities, as well as by the but can be used by certain network entities, as well as by the
peer application, to identify the type of information being peer application, to identify the type of information being
carried in this DATA chunk. This field must be sent even in carried in this DATA chunk. This field must be sent even in
fragmented DATA chunks (to make sure it is available for agents in fragmented DATA chunks (to make sure it is available for agents in
the middle of the network). Note that this field is NOT touched the middle of the network). Note that this field is NOT touched
by an SCTP implementation, therefore its byte order is NOT by an SCTP implementation; therefore, its byte order is NOT
necessarily Big Endian. The upper layer is responsible for any necessarily big endian. The upper layer is responsible for any
byte order conversions to this field. byte order conversions to this field.
The value 0 indicates no application identifier is specified by The value 0 indicates that no application identifier is specified
the upper layer for this payload data. by the upper layer for this payload data.
User Data: variable length User Data: variable length
This is the payload user data. The implementation MUST pad the This is the payload user data. The implementation MUST pad the
end of the data to a 4 byte boundary with all-zero bytes. Any end of the data to a 4-byte boundary with all-zero bytes. Any
padding MUST NOT be included in the length field. A sender MUST padding MUST NOT be included in the Length field. A sender MUST
never add more than 3 bytes of padding. never add more than 3 bytes of padding.
3.3.2. Initiation (INIT) (1) 3.3.2. Initiation (INIT) (1)
This chunk is used to initiate a SCTP association between two This chunk is used to initiate an SCTP association between two
endpoints. The format of the INIT chunk is shown below: endpoints. The format of the INIT chunk is shown below:
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Type = 1 | Chunk Flags | Chunk Length | | Type = 1 | Chunk Flags | Chunk Length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Initiate Tag | | Initiate Tag |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Advertised Receiver Window Credit (a_rwnd) | | Advertised Receiver Window Credit (a_rwnd) |
skipping to change at page 26, line 36 skipping to change at page 25, line 36
Fixed Parameters Status Fixed Parameters Status
---------------------------------------------- ----------------------------------------------
Initiate Tag Mandatory Initiate Tag Mandatory
Advertised Receiver Window Credit Mandatory Advertised Receiver Window Credit Mandatory
Number of Outbound Streams Mandatory Number of Outbound Streams Mandatory
Number of Inbound Streams Mandatory Number of Inbound Streams Mandatory
Initial TSN Mandatory Initial TSN Mandatory
Variable Parameters Status Type Value Variable Parameters Status Type Value
------------------------------------------------------------- -------------------------------------------------------------
IPv4 Address (Note 1) Optional 5 IPv4 Address (Note 1) Optional 5 IPv6 Address
IPv6 Address (Note 1) Optional 6 (Note 1) Optional 6 Cookie Preservative
Cookie Preservative Optional 9 Optional 9 Reserved for ECN Capable (Note 2) Optional
Reserved for ECN Capable (Note 2) Optional 32768 (0x8000) 32768 (0x8000) Host Name Address (Note 3) Optional
Host Name Address (Note 3) Optional 11 11 Supported Address Types (Note 4) Optional 12
Supported Address Types (Note 4) Optional 12
Note 1: The INIT chunks can contain multiple addresses that can be Note 1: The INIT chunks can contain multiple addresses that can be
IPv4 and/or IPv6 in any combination. IPv4 and/or IPv6 in any combination.
Note 2: The ECN capable field is reserved for future use of Explicit Note 2: The ECN Capable field is reserved for future use of Explicit
Congestion Notification. Congestion Notification.
Note 3: An INIT chunk MUST NOT contain more than one Host Name Note 3: An INIT chunk MUST NOT contain more than one Host Name
address parameter. Moreover, the sender of the INIT MUST NOT combine Address parameter. Moreover, the sender of the INIT MUST NOT combine
any other address types with the Host Name address in the INIT. The any other address types with the Host Name Address in the INIT. The
receiver of INIT MUST ignore any other address types if the Host Name receiver of INIT MUST ignore any other address types if the Host Name
address parameter is present in the received INIT chunk. Address parameter is present in the received INIT chunk.
Note 4: This parameter, when present, specifies all the address types Note 4: This parameter, when present, specifies all the address types
the sending endpoint can support. The absence of this parameter the sending endpoint can support. The absence of this parameter
indicates that the sending endpoint can support any address type. indicates that the sending endpoint can support any address type.
IMPLEMENTATION NOTE: If an INIT chunk is received with known IMPLEMENTATION NOTE: If an INIT chunk is received with known
parameters that are not optional parameters of the INIT chunk then parameters that are not optional parameters of the INIT chunk, then
the receiver SHOULD process the INIT chunk and send back an INIT-ACK. the receiver SHOULD process the INIT chunk and send back an INIT ACK.
The receiver of the INIT chunk MAY bundle an ERROR chunk with the The receiver of the INIT chunk MAY bundle an ERROR chunk with the
COOKIE-ACK chunk later. However, restrictive implementations MAY COOKIE ACK chunk later. However, restrictive implementations MAY
send back an ABORT chunk in response to the INIT chunk. send back an ABORT chunk in response to the INIT chunk.
The Chunk Flags field in INIT is reserved and all bits in it should The Chunk Flags field in INIT is reserved, and all bits in it should
be set to 0 by the sender and ignored by the receiver. The sequence be set to 0 by the sender and ignored by the receiver. The sequence
of parameters within an INIT can be processed in any order. of parameters within an INIT can be processed in any order.
Initiate Tag: 32 bits (unsigned integer) Initiate Tag: 32 bits (unsigned integer)
The receiver of the INIT (the responding end) records the value of The receiver of the INIT (the responding end) records the value of
the Initiate Tag parameter. This value MUST be placed into the the Initiate Tag parameter. This value MUST be placed into the
Verification Tag field of every SCTP packet that the receiver of Verification Tag field of every SCTP packet that the receiver of
the INIT transmits within this association. the INIT transmits within this association.
skipping to change at page 27, line 45 skipping to change at page 26, line 39
If the value of the Initiate Tag in a received INIT chunk is found If the value of the Initiate Tag in a received INIT chunk is found
to be 0, the receiver MUST treat it as an error and close the to be 0, the receiver MUST treat it as an error and close the
association by transmitting an ABORT. association by transmitting an ABORT.
Advertised Receiver Window Credit (a_rwnd): 32 bits (unsigned Advertised Receiver Window Credit (a_rwnd): 32 bits (unsigned
integer) integer)
This value represents the dedicated buffer space, in number of This value represents the dedicated buffer space, in number of
bytes, the sender of the INIT has reserved in association with bytes, the sender of the INIT has reserved in association with
this window. During the life of the association this buffer space this window. During the life of the association, this buffer
SHOULD not be lessened (i.e. dedicated buffers taken away from space SHOULD NOT be lessened (i.e., dedicated buffers taken away
this association); however, an endpoint MAY change the value of from this association); however, an endpoint MAY change the value
a_rwnd it sends in SACK chunks. of a_rwnd it sends in SACK chunks.
Number of Outbound Streams (OS): 16 bits (unsigned integer) Number of Outbound Streams (OS): 16 bits (unsigned integer)
Defines the number of outbound streams the sender of this INIT Defines the number of outbound streams the sender of this INIT
chunk wishes to create in this association. The value of 0 MUST chunk wishes to create in this association. The value of 0 MUST
NOT be used. NOT be used.
Note: A receiver of an INIT with the OS value set to 0 SHOULD Note: A receiver of an INIT with the OS value set to 0 SHOULD
abort the association. abort the association.
Number of Inbound Streams (MIS) : 16 bits (unsigned integer) Number of Inbound Streams (MIS) : 16 bits (unsigned integer)
Defines the maximum number of streams the sender of this INIT Defines the maximum number of streams the sender of this INIT
skipping to change at page 28, line 30 skipping to change at page 27, line 24
Note: A receiver of an INIT with the MIS value of 0 SHOULD abort Note: A receiver of an INIT with the MIS value of 0 SHOULD abort
the association. the association.
Initial TSN (I-TSN) : 32 bits (unsigned integer) Initial TSN (I-TSN) : 32 bits (unsigned integer)
Defines the initial TSN that the sender will use. The valid range Defines the initial TSN that the sender will use. The valid range
is from 0 to 4294967295. This field MAY be set to the value of is from 0 to 4294967295. This field MAY be set to the value of
the Initiate Tag field. the Initiate Tag field.
3.3.2.1. Optional/Variable Length Parameters in INIT 3.3.2.1. Optional/Variable-Length Parameters in INIT
The following parameters follow the Type-Length-Value format as The following parameters follow the Type-Length-Value format as
defined in Section 3.2.1. Any Type-Length-Value fields MUST come defined in Section 3.2.1. Any Type-Length-Value fields MUST come
after the fixed-length fields defined in the previous section. after the fixed-length fields defined in the previous section.
IPv4 Address Parameter (5) IPv4 Address Parameter (5)
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
skipping to change at page 29, line 22 skipping to change at page 28, line 20
| Type = 6 | Length = 20 | | Type = 6 | Length = 20 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| | | |
| IPv6 Address | | IPv6 Address |
| | | |
| | | |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
IPv6 Address: 128 bits (unsigned integer) IPv6 Address: 128 bits (unsigned integer)
Contains an IPv6 address of the sending endpoint. It is binary Contains an IPv6 [RFC2460] address of the sending endpoint. It is
encoded. binary encoded.
Note: A sender MUST NOT use an IPv4-mapped IPv6 address [RFC4291]. Note: A sender MUST NOT use an IPv4-mapped IPv6 address [RFC4291],
but should instead use an IPv4 Address Parameter for an IPv4 but should instead use an IPv4 Address parameter for an IPv4
address. address.
Combined with the Source Port Number in the SCTP common header, Combined with the Source Port Number in the SCTP common header,
the value passed in an IPv4 or IPv6 Address parameter indicates a the value passed in an IPv4 or IPv6 Address parameter indicates a
transport address the sender of the INIT will support for the transport address the sender of the INIT will support for the
association being initiated. That is, during the lifetime of this association being initiated. That is, during the life time of
association, this IP address can appear in the source address this association, this IP address can appear in the source address
field of an IP datagram sent from the sender of the INIT, and can field of an IP datagram sent from the sender of the INIT, and can
be used as a destination address of an IP datagram sent from the be used as a destination address of an IP datagram sent from the
receiver of the INIT. receiver of the INIT.
More than one IP Address parameter can be included in an INIT More than one IP Address parameter can be included in an INIT
chunk when the INIT sender is multi-homed. Moreover, a multi- chunk when the INIT sender is multi-homed. Moreover, a multi-
homed endpoint may have access to different types of network, thus homed endpoint may have access to different types of network;
more than one address type can be present in one INIT chunk, i.e., thus, more than one address type can be present in one INIT chunk,
IPv4 and IPv6 addresses are allowed in the same INIT chunk. i.e., IPv4 and IPv6 addresses are allowed in the same INIT chunk.
If the INIT contains at least one IP Address parameter, then the If the INIT contains at least one IP Address parameter, then the
source address of the IP datagram containing the INIT chunk and source address of the IP datagram containing the INIT chunk and
any additional address(es) provided within the INIT can be used as any additional address(es) provided within the INIT can be used as
destinations by the endpoint receiving the INIT. If the INIT does destinations by the endpoint receiving the INIT. If the INIT does
not contain any IP Address parameters, the endpoint receiving the not contain any IP Address parameters, the endpoint receiving the
INIT MUST use the source address associated with the received IP INIT MUST use the source address associated with the received IP
datagram as its sole destination address for the association. datagram as its sole destination address for the association.
Note that not using any IP address parameters in the INIT and Note that not using any IP Address parameters in the INIT and INIT
INIT-ACK is an alternative to make an association more likely to ACK is an alternative to make an association more likely to work
work across a NAT box. across a NAT box.
Cookie Preservative (9) Cookie Preservative (9)
The sender of the INIT shall use this parameter to suggest to the The sender of the INIT shall use this parameter to suggest to the
receiver of the INIT for a longer life-span of the State Cookie. receiver of the INIT for a longer life-span of the State Cookie.
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Type = 9 | Length = 8 | | Type = 9 | Length = 8 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Suggested Cookie Life-span Increment (msec.) | | Suggested Cookie Life-Span Increment (msec.) |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Suggested Cookie Life-span Increment: 32 bits (unsigned integer) Suggested Cookie Life-Span Increment: 32 bits (unsigned integer)
This parameter indicates to the receiver how much increment in This parameter indicates to the receiver how much increment in
milliseconds the sender wishes the receiver to add to its default milliseconds the sender wishes the receiver to add to its default
cookie life-span. cookie life-span.
This optional parameter should be added to the INIT chunk by the This optional parameter should be added to the INIT chunk by the
sender when it re-attempts establishing an association with a peer sender when it reattempts establishing an association with a peer
to which its previous attempt of establishing the association to which its previous attempt of establishing the association
failed due to a stale cookie operation error. The receiver MAY failed due to a stale cookie operation error. The receiver MAY
choose to ignore the suggested cookie life-span increase for its choose to ignore the suggested cookie life-span increase for its
own security reasons. own security reasons.
Host Name Address (11) Host Name Address (11)
The sender of INIT uses this parameter to pass its Host Name (in The sender of INIT uses this parameter to pass its Host Name (in
place of its IP addresses) to its peer. The peer is responsible for place of its IP addresses) to its peer. The peer is responsible for
resolving the name. Using this parameter might make it more likely resolving the name. Using this parameter might make it more likely
skipping to change at page 31, line 33 skipping to change at page 30, line 28
| Address Type #1 | Address Type #2 | | Address Type #1 | Address Type #2 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| ...... | | ...... |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-++-+-+-+-+-+-+-+-+-+-+-+-+-+-++-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-++-+-+-+-+-+-+-+-+-+-+-+-+-+-++-+-+-+
Address Type: 16 bits (unsigned integer) Address Type: 16 bits (unsigned integer)
This is filled with the type value of the corresponding address This is filled with the type value of the corresponding address
TLV (e.g., IPv4 = 5, IPv6 = 6, Hostname = 11). TLV (e.g., IPv4 = 5, IPv6 = 6, Hostname = 11).
3.3.3. Initiation Acknowledgement (INIT ACK) (2): 3.3.3. Initiation Acknowledgement (INIT ACK) (2)
The INIT ACK chunk is used to acknowledge the initiation of an SCTP The INIT ACK chunk is used to acknowledge the initiation of an SCTP
association. association.
The parameter part of INIT ACK is formatted similarly to the INIT The parameter part of INIT ACK is formatted similarly to the INIT
chunk. It uses two extra variable parameters: The State Cookie and chunk. It uses two extra variable parameters: The State Cookie and
the Unrecognized Parameter: the Unrecognized Parameter:
The format of the INIT ACK chunk is shown below: The format of the INIT ACK chunk is shown below:
skipping to change at page 32, line 43 skipping to change at page 31, line 45
If the value of the Initiate Tag in a received INIT ACK chunk is If the value of the Initiate Tag in a received INIT ACK chunk is
found to be 0, the receiver MUST destroy the association found to be 0, the receiver MUST destroy the association
discarding its TCB. The receiver MAY send an ABORT for debugging discarding its TCB. The receiver MAY send an ABORT for debugging
purpose. purpose.
Advertised Receiver Window Credit (a_rwnd): 32 bits (unsigned Advertised Receiver Window Credit (a_rwnd): 32 bits (unsigned
integer) integer)
This value represents the dedicated buffer space, in number of This value represents the dedicated buffer space, in number of
bytes, the sender of the INIT ACK has reserved in association with bytes, the sender of the INIT ACK has reserved in association with
this window. During the life of the association this buffer space this window. During the life of the association, this buffer
SHOULD not be lessened (i.e. dedicated buffers taken away from space SHOULD NOT be lessened (i.e., dedicated buffers taken away
this association). from this association).
Number of Outbound Streams (OS): 16 bits (unsigned integer) Number of Outbound Streams (OS): 16 bits (unsigned integer)
Defines the number of outbound streams the sender of this INIT ACK Defines the number of outbound streams the sender of this INIT ACK
chunk wishes to create in this association. The value of 0 MUST chunk wishes to create in this association. The value of 0 MUST
NOT be used, and the value MUST NOT be greater than the MIS value NOT be used, and the value MUST NOT be greater than the MIS value
sent in the INIT chunk. sent in the INIT chunk.
Note: A receiver of an INIT ACK with the OS value set to 0 SHOULD Note: A receiver of an INIT ACK with the OS value set to 0 SHOULD
destroy the association discarding its TCB. destroy the association discarding its TCB.
skipping to change at page 33, line 23 skipping to change at page 32, line 25
Note: There is no negotiation of the actual number of streams but Note: There is no negotiation of the actual number of streams but
instead the two endpoints will use the min(requested, offered). instead the two endpoints will use the min(requested, offered).
See Section 5.1.1 for details. See Section 5.1.1 for details.
Note: A receiver of an INIT ACK with the MIS value set to 0 SHOULD Note: A receiver of an INIT ACK with the MIS value set to 0 SHOULD
destroy the association discarding its TCB. destroy the association discarding its TCB.
Initial TSN (I-TSN) : 32 bits (unsigned integer) Initial TSN (I-TSN) : 32 bits (unsigned integer)
Defines the initial TSN that the INIT-ACK sender will use. The Defines the initial TSN that the INIT ACK sender will use. The
valid range is from 0 to 4294967295. This field MAY be set to the valid range is from 0 to 4294967295. This field MAY be set to the
value of the Initiate Tag field. value of the Initiate Tag field.
Fixed Parameters Status Fixed Parameters Status
---------------------------------------------- ----------------------------------------------
Initiate Tag Mandatory Initiate Tag Mandatory
Advertised Receiver Window Credit Mandatory Advertised Receiver Window Credit Mandatory
Number of Outbound Streams Mandatory Number of Outbound Streams Mandatory
Number of Inbound Streams Mandatory Number of Inbound Streams Mandatory
Initial TSN Mandatory Initial TSN Mandatory
skipping to change at page 33, line 47 skipping to change at page 32, line 49
State Cookie Mandatory 7 State Cookie Mandatory 7
IPv4 Address (Note 1) Optional 5 IPv4 Address (Note 1) Optional 5
IPv6 Address (Note 1) Optional 6 IPv6 Address (Note 1) Optional 6
Unrecognized Parameter Optional 8 Unrecognized Parameter Optional 8
Reserved for ECN Capable (Note 2) Optional 32768 (0x8000) Reserved for ECN Capable (Note 2) Optional 32768 (0x8000)
Host Name Address (Note 3) Optional 11 Host Name Address (Note 3) Optional 11
Note 1: The INIT ACK chunks can contain any number of IP address Note 1: The INIT ACK chunks can contain any number of IP address
parameters that can be IPv4 and/or IPv6 in any combination. parameters that can be IPv4 and/or IPv6 in any combination.
Note 2: The ECN capable field is reserved for future use of Explicit Note 2: The ECN Capable field is reserved for future use of Explicit
Congestion Notification. Congestion Notification.
Note 3: The INIT ACK chunks MUST NOT contain more than one Host Name Note 3: The INIT ACK chunks MUST NOT contain more than one Host Name
address parameter. Moreover, the sender of the INIT ACK MUST NOT Address parameter. Moreover, the sender of the INIT ACK MUST NOT
combine any other address types with the Host Name address in the combine any other address types with the Host Name Address in the
INIT ACK. The receiver of the INIT ACK MUST ignore any other address INIT ACK. The receiver of the INIT ACK MUST ignore any other address
types if the Host Name address parameter is present. types if the Host Name Address parameter is present.
IMPLEMENTATION NOTE: An implementation MUST be prepared to receive a IMPLEMENTATION NOTE: An implementation MUST be prepared to receive an
INIT ACK that is quite large (more than 1500 bytes) due to the INIT ACK that is quite large (more than 1500 bytes) due to the
variable size of the state cookie AND the variable address list. For variable size of the State Cookie AND the variable address list. For
example if a responder to the INIT has 1000 IPv4 addresses it wishes example if a responder to the INIT has 1000 IPv4 addresses it wishes
to send, it would need at least 8,000 bytes to encode this in the to send, it would need at least 8,000 bytes to encode this in the
INIT ACK. INIT ACK.
IMPLEMENTATION NOTE: If an INIT-ACK chunk is received with known IMPLEMENTATION NOTE: If an INIT ACK chunk is received with known
parameters that are not optional parameters of the INIT-ACK chunk, parameters that are not optional parameters of the INIT ACK chunk,
then the receiver SHOULD process the INIT-ACK chunk and send back a then the receiver SHOULD process the INIT ACK chunk and send back a
COOKIE-ECHO. The receiver of the INIT-ACK chunk MAY bundle an ERROR COOKIE ECHO. The receiver of the INIT ACK chunk MAY bundle an ERROR
chunk with the COOKIE-ECHO chunk. However, restrictive chunk with the COOKIE ECHO chunk. However, restrictive
implementations MAY send back an ABORT chunk in response to the INIT- implementations MAY send back an ABORT chunk in response to the INIT
ACK chunk. ACK chunk.
In combination with the Source Port carried in the SCTP common In combination with the Source Port carried in the SCTP common
header, each IP Address parameter in the INIT ACK indicates to the header, each IP Address parameter in the INIT ACK indicates to the
receiver of the INIT ACK a valid transport address supported by the receiver of the INIT ACK a valid transport address supported by the
sender of the INIT ACK for the lifetime of the association being sender of the INIT ACK for the lifetime of the association being
initiated. initiated.
If the INIT ACK contains at least one IP Address parameter, then the If the INIT ACK contains at least one IP Address parameter, then the
source address of the IP datagram containing the INIT ACK and any source address of the IP datagram containing the INIT ACK and any
additional address(es) provided within the INIT ACK may be used as additional address(es) provided within the INIT ACK may be used as
destinations by the receiver of the INIT-ACK. If the INIT ACK does destinations by the receiver of the INIT ACK. If the INIT ACK does
not contain any IP Address parameters, the receiver of the INIT-ACK not contain any IP Address parameters, the receiver of the INIT ACK
MUST use the source address associated with the received IP datagram MUST use the source address associated with the received IP datagram
as its sole destination address for the association. as its sole destination address for the association.
The State Cookie and Unrecognized Parameters use the Type-Length- The State Cookie and Unrecognized Parameters use the Type-Length-
Value format as defined in Section 3.2.1 and are described below. Value format as defined in Section 3.2.1 and are described below.
The other fields are defined the same as their counterparts in the The other fields are defined the same as their counterparts in the
INIT chunk. INIT chunk.
3.3.3.1. Optional or Variable Length Parameters 3.3.3.1. Optional or Variable-Length Parameters
State Cookie State Cookie
Parameter Type Value: 7 Parameter Type Value: 7
Parameter Length: variable size, depending on Size of Cookie Parameter Length: Variable size, depending on size of Cookie.
Parameter Value: Parameter Value:
This parameter value MUST contain all the necessary state and This parameter value MUST contain all the necessary state and
parameter information required for the sender of this INIT ACK to parameter information required for the sender of this INIT ACK to
create the association, along with a Message Authentication Code create the association, along with a Message Authentication Code
(MAC). See Section 5.1.3 for details on State Cookie definition. (MAC). See Section 5.1.3 for details on State Cookie definition.
Unrecognized Parameter: Unrecognized Parameter:
Parameter Type Value: 8 Parameter Type Value: 8
Parameter Length: Variable Size. Parameter Length: Variable size.
Parameter Value: Parameter Value:
This parameter is returned to the originator of the INIT chunk This parameter is returned to the originator of the INIT chunk
when the INIT contains an unrecognized parameter which has a value when the INIT contains an unrecognized parameter that has a value
that indicates that it should be reported to the sender. This that indicates it should be reported to the sender. This
parameter value field will contain unrecognized parameters copied parameter value field will contain unrecognized parameters copied
from the INIT chunk complete with Parameter Type, Length and Value from the INIT chunk complete with Parameter Type, Length, and
fields. Value fields.
3.3.4. Selective Acknowledgement (SACK) (3): 3.3.4. Selective Acknowledgement (SACK) (3)
This chunk is sent to the peer endpoint to acknowledge received DATA This chunk is sent to the peer endpoint to acknowledge received DATA
chunks and to inform the peer endpoint of gaps in the received chunks and to inform the peer endpoint of gaps in the received
subsequences of DATA chunks as represented by their TSNs. subsequences of DATA chunks as represented by their TSNs.
The SACK MUST contain the Cumulative TSN Ack, Advertised Receiver The SACK MUST contain the Cumulative TSN Ack, Advertised Receiver
Window Credit (a_rwnd), Number of Gap Ack Blocks, and Number of Window Credit (a_rwnd), Number of Gap Ack Blocks, and Number of
Duplicate TSNs fields. Duplicate TSNs fields.
By definition, the value of the Cumulative TSN Ack parameter is the By definition, the value of the Cumulative TSN Ack parameter is the
skipping to change at page 36, line 41 skipping to change at page 35, line 35
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
/ / / /
\ ... \ \ ... \
/ / / /
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Duplicate TSN X | | Duplicate TSN X |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Chunk Flags: 8 bits Chunk Flags: 8 bits
Set to all zeros on transmit and ignored on receipt. Set to all '0's on transmit and ignored on receipt.
Cumulative TSN Ack: 32 bits (unsigned integer) Cumulative TSN Ack: 32 bits (unsigned integer)
This parameter contains the TSN of the last DATA chunk received in This parameter contains the TSN of the last DATA chunk received in
sequence before a gap. In the case where no DATA chunk has been sequence before a gap. In the case where no DATA chunk has been
received, this value is set to the peer's Initial TSN minus one. received, this value is set to the peer's Initial TSN minus one.
Advertised Receiver Window Credit (a_rwnd): 32 bits (unsigned Advertised Receiver Window Credit (a_rwnd): 32 bits (unsigned
integer) integer)
This field indicates the updated receive buffer space in bytes of This field indicates the updated receive buffer space in bytes of
the sender of this SACK, see Section 6.2.1 for details. the sender of this SACK; see Section 6.2.1 for details.
Number of Gap Ack Blocks: 16 bits (unsigned integer) Number of Gap Ack Blocks: 16 bits (unsigned integer)
Indicates the number of Gap Ack Blocks included in this SACK. Indicates the number of Gap Ack Blocks included in this SACK.
Number of Duplicate TSNs: 16 bit Number of Duplicate TSNs: 16 bit
This field contains the number of duplicate TSNs the endpoint has This field contains the number of duplicate TSNs the endpoint has
received. Each duplicate TSN is listed following the Gap Ack received. Each duplicate TSN is listed following the Gap Ack
Block list. Block list.
skipping to change at page 37, line 37 skipping to change at page 36, line 31
Gap Ack Block Start: 16 bits (unsigned integer) Gap Ack Block Start: 16 bits (unsigned integer)
Indicates the Start offset TSN for this Gap Ack Block. To Indicates the Start offset TSN for this Gap Ack Block. To
calculate the actual TSN number the Cumulative TSN Ack is added to calculate the actual TSN number the Cumulative TSN Ack is added to
this offset number. This calculated TSN identifies the first TSN this offset number. This calculated TSN identifies the first TSN
in this Gap Ack Block that has been received. in this Gap Ack Block that has been received.
Gap Ack Block End: 16 bits (unsigned integer) Gap Ack Block End: 16 bits (unsigned integer)
Indicates the End offset TSN for this Gap Ack Block. To calculate Indicates the End offset TSN for this Gap Ack Block. To calculate
the actual TSN number the Cumulative TSN Ack is added to this the actual TSN number, the Cumulative TSN Ack is added to this
offset number. This calculated TSN identifies the TSN of the last offset number. This calculated TSN identifies the TSN of the last
DATA chunk received in this Gap Ack Block. DATA chunk received in this Gap Ack Block.
For example, assume the receiver has the following DATA chunks newly For example, assume that the receiver has the following DATA chunks
arrived at the time when it decides to send a Selective ACK, newly arrived at the time when it decides to send a Selective ACK,
---------- ----------
| TSN=17 | | TSN=17 |
---------- ----------
| | <- still missing | | <- still missing
---------- ----------
| TSN=15 | | TSN=15 |
---------- ----------
| TSN=14 | | TSN=14 |
---------- ----------
| | <- still missing | | <- still missing
---------- ----------
| TSN=12 | | TSN=12 |
---------- ----------
| TSN=11 | | TSN=11 |
---------- ----------
| TSN=10 | | TSN=10 |
---------- ----------
then, the parameter part of the SACK MUST be constructed as follows then the parameter part of the SACK MUST be constructed as follows
(assuming the new a_rwnd is set to 4660 by the sender): (assuming the new a_rwnd is set to 4660 by the sender):
+--------------------------------+ +--------------------------------+
| Cumulative TSN Ack = 12 | | Cumulative TSN Ack = 12 |
+--------------------------------+ +--------------------------------+
| a_rwnd = 4660 | | a_rwnd = 4660 |
+----------------+---------------+ +----------------+---------------+
| num of block=2 | num of dup=0 | | num of block=2 | num of dup=0 |
+----------------+---------------+ +----------------+---------------+
|block #1 strt=2 |block #1 end=3 | |block #1 strt=2 |block #1 end=3 |
+----------------+---------------+ +----------------+---------------+
|block #2 strt=5 |block #2 end=5 | |block #2 strt=5 |block #2 end=5 |
+----------------+---------------+ +----------------+---------------+
Duplicate TSN: 32 bits (unsigned integer) Duplicate TSN: 32 bits (unsigned integer)
Indicates the number of times a TSN was received in duplicate Indicates the number of times a TSN was received in duplicate
since the last SACK was sent. Every time a receiver gets a since the last SACK was sent. Every time a receiver gets a
duplicate TSN (before sending the SACK) it adds it to the list of duplicate TSN (before sending the SACK), it adds it to the list of
duplicates. The duplicate count is re-initialized to zero after duplicates. The duplicate count is reinitialized to zero after
sending each SACK. sending each SACK.
For example, if a receiver were to get the TSN 19 three times it For example, if a receiver were to get the TSN 19 three times it
would list 19 twice in the outbound SACK. After sending the SACK if would list 19 twice in the outbound SACK. After sending the SACK, if
it received yet one more TSN 19 it would list 19 as a duplicate once it received yet one more TSN 19 it would list 19 as a duplicate once
in the next outgoing SACK. in the next outgoing SACK.
3.3.5. Heartbeat Request (HEARTBEAT) (4): 3.3.5. Heartbeat Request (HEARTBEAT) (4)
An endpoint should send this chunk to its peer endpoint to probe the An endpoint should send this chunk to its peer endpoint to probe the
reachability of a particular destination transport address defined in reachability of a particular destination transport address defined in
the present association. the present association.
The parameter field contains the Heartbeat Information which is a The parameter field contains the Heartbeat Information, which is a
variable length opaque data structure understood only by the sender. variable-length opaque data structure understood only by the sender.
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Type = 4 | Chunk Flags | Heartbeat Length | | Type = 4 | Chunk Flags | Heartbeat Length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\ \ \ \
/ Heartbeat Information TLV (Variable-Length) / / Heartbeat Information TLV (Variable-Length) /
\ \ \ \
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Chunk Flags: 8 bits Chunk Flags: 8 bits
Set to zero on transmit and ignored on receipt. Set to 0 on transmit and ignored on receipt.
Heartbeat Length: 16 bits (unsigned integer) Heartbeat Length: 16 bits (unsigned integer)
Set to the size of the chunk in bytes, including the chunk header Set to the size of the chunk in bytes, including the chunk header
and the Heartbeat Information field. and the Heartbeat Information field.
Heartbeat Information: variable length Heartbeat Information: variable length
Defined as a variable-length parameter using the format described Defined as a variable-length parameter using the format described
in Section 3.2.1, i.e.: in Section 3.2.1, i.e.:
Variable Parameters Status Type Value Variable Parameters Status Type Value
------------------------------------------------------------- -------------------------------------------------------------
Heartbeat Info Mandatory 1 Heartbeat Info Mandatory 1
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Heartbeat Info Type=1 | HB Info Length | | Heartbeat Info Type=1 | HB Info Length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
/ Sender-specific Heartbeat Info / / Sender-Specific Heartbeat Info /
\ \ \ \
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
The Sender-specific Heartbeat Info field should normally include
The Sender-Specific Heartbeat Info field should normally include
information about the sender's current time when this HEARTBEAT information about the sender's current time when this HEARTBEAT
chunk is sent and the destination transport address to which this chunk is sent and the destination transport address to which this
HEARTBEAT is sent (see Section 8.3). This information is simply HEARTBEAT is sent (see Section 8.3). This information is simply
reflected back by the receiver in the HEARTBEAT ACK message (see reflected back by the receiver in the HEARTBEAT ACK message (see
Section 3.3.6). Note also that the HEARTBEAT message is both for Section 3.3.6). Note also that the HEARTBEAT message is both for
reachability checking and for Path Verification (see Section 5.4). reachability checking and for path verification (see Section 5.4).
When a HEARTBEAT chunk is being used for path verification When a HEARTBEAT chunk is being used for path verification
purposes it MUST hold a 64 bit random nonce. purposes, it MUST hold a 64-bit random nonce.
3.3.6. Heartbeat Acknowledgement (HEARTBEAT ACK) (5): 3.3.6. Heartbeat Acknowledgement (HEARTBEAT ACK) (5)
An endpoint should send this chunk to its peer endpoint as a response An endpoint should send this chunk to its peer endpoint as a response
to a HEARTBEAT chunk (see Section 8.3). A HEARTBEAT ACK is always to a HEARTBEAT chunk (see Section 8.3). A HEARTBEAT ACK is always
sent to the source IP address of the IP datagram containing the sent to the source IP address of the IP datagram containing the
HEARTBEAT chunk to which this ack is responding. HEARTBEAT chunk to which this ack is responding.
The parameter field contains a variable length opaque data structure. The parameter field contains a variable-length opaque data structure.
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Type = 5 | Chunk Flags | Heartbeat Ack Length | | Type = 5 | Chunk Flags | Heartbeat Ack Length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\ \ \ \
/ Heartbeat Information TLV (Variable-Length) / / Heartbeat Information TLV (Variable-Length) /
\ \ \ \
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Chunk Flags: 8 bits Chunk Flags: 8 bits
Set to zero on transmit and ignored on receipt. Set to 0 on transmit and ignored on receipt.
Heartbeat Ack Length: 16 bits (unsigned integer) Heartbeat Ack Length: 16 bits (unsigned integer)
Set to the size of the chunk in bytes, including the chunk header Set to the size of the chunk in bytes, including the chunk header
and the Heartbeat Information field. and the Heartbeat Information field.
Heartbeat Information: variable length Heartbeat Information: variable length
This field MUST contain the Heartbeat Information parameter of the This field MUST contain the Heartbeat Information parameter of the
Heartbeat Request to which this Heartbeat Acknowledgement is Heartbeat Request to which this Heartbeat Acknowledgement is
responding. responding.
Variable Parameters Status Type Value Variable Parameters Status Type Value
------------------------------------------------------------- -------------------------------------------------------------
Heartbeat Info Mandatory 1 Heartbeat Info Mandatory 1
3.3.7. Abort Association (ABORT) (6): 3.3.7. Abort Association (ABORT) (6)
The ABORT chunk is sent to the peer of an association to close the The ABORT chunk is sent to the peer of an association to close the
association. The ABORT chunk may contain Cause Parameters to inform association. The ABORT chunk may contain Cause Parameters to inform
the receiver about the reason of the abort. DATA chunks MUST NOT be the receiver about the reason of the abort. DATA chunks MUST NOT be
bundled with ABORT. Control chunks (except for INIT, INIT ACK and bundled with ABORT. Control chunks (except for INIT, INIT ACK, and
SHUTDOWN COMPLETE) MAY be bundled with an ABORT but they MUST be SHUTDOWN COMPLETE) MAY be bundled with an ABORT, but they MUST be
placed before the ABORT in the SCTP packet, or they will be ignored placed before the ABORT in the SCTP packet or they will be ignored by
by the receiver. the receiver.
If an endpoint receives an ABORT with a format error or no TCB is If an endpoint receives an ABORT with a format error or no TCB is
found, it MUST silently discard it. Moreover, under any found, it MUST silently discard it. Moreover, under any
circumstances, an endpoint that receives an ABORT MUST NOT respond to circumstances, an endpoint that receives an ABORT MUST NOT respond to
that ABORT by sending an ABORT of its own. that ABORT by sending an ABORT of its own.
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Type = 6 |Reserved |T| Length | | Type = 6 |Reserved |T| Length |
skipping to change at page 41, line 43 skipping to change at page 40, line 43
Set to 0 on transmit and ignored on receipt. Set to 0 on transmit and ignored on receipt.
T bit: 1 bit T bit: 1 bit
The T bit is set to 0 if the sender filled in the Verification Tag The T bit is set to 0 if the sender filled in the Verification Tag
expected by the peer. If the Verification Tag is reflected, the T expected by the peer. If the Verification Tag is reflected, the T
bit MUST be set to 1. Reflecting means that the sent Verification bit MUST be set to 1. Reflecting means that the sent Verification
Tag is the same as the received one. Tag is the same as the received one.
Note: Special rules apply to this chunk for verification, please Note: Special rules apply to this chunk for verification; please
see Section 8.5.1 for details. see Section 8.5.1 for details.
Length: 16 bits (unsigned integer) Length: 16 bits (unsigned integer)
Set to the size of the chunk in bytes, including the chunk header Set to the size of the chunk in bytes, including the chunk header
and all the Error Cause fields present. and all the Error Cause fields present.
See Section 3.3.10 for Error Cause definitions. See Section 3.3.10 for Error Cause definitions.
3.3.8. Shutdown Association (SHUTDOWN) (7): 3.3.8. Shutdown Association (SHUTDOWN) (7)
An endpoint in an association MUST use this chunk to initiate a An endpoint in an association MUST use this chunk to initiate a
graceful close of the association with its peer. This chunk has the graceful close of the association with its peer. This chunk has the
following format. following format.
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Type = 7 | Chunk Flags | Length = 8 | | Type = 7 | Chunk Flags | Length = 8 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Cumulative TSN Ack | | Cumulative TSN Ack |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Chunk Flags: 8 bits Chunk Flags: 8 bits
Set to zero on transmit and ignored on receipt. Set to 0 on transmit and ignored on receipt.
Length: 16 bits (unsigned integer) Length: 16 bits (unsigned integer)
Indicates the length of the parameter. Set to 8. Indicates the length of the parameter. Set to 8.
Cumulative TSN Ack: 32 bits (unsigned integer) Cumulative TSN Ack: 32 bits (unsigned integer)
This parameter contains the TSN of the last chunk received in This parameter contains the TSN of the last chunk received in
sequence before any gaps. sequence before any gaps.
Note: Since the SHUTDOWN message does not contain Gap Ack Blocks, Note: Since the SHUTDOWN message does not contain Gap Ack Blocks,
it cannot be used to acknowledge TSNs received out of order. In a it cannot be used to acknowledge TSNs received out of order. In a
SACK, lack of Gap Ack Blocks that were previously included SACK, lack of Gap Ack Blocks that were previously included
indicates that the data receiver reneged on the associated DATA indicates that the data receiver reneged on the associated DATA
chunks. Since SHUTDOWN does not contain Gap Ack Blocks, the chunks. Since SHUTDOWN does not contain Gap Ack Blocks, the
receiver of the SHUTDOWN shouldn't interpret the lack of a Gap Ack receiver of the SHUTDOWN shouldn't interpret the lack of a Gap Ack
Block as a renege. (see Section 6.2 for information on reneging) Block as a renege. (See Section 6.2 for information on reneging.)
3.3.9. Shutdown Acknowledgement (SHUTDOWN ACK) (8): 3.3.9. Shutdown Acknowledgement (SHUTDOWN ACK) (8)
This chunk MUST be used to acknowledge the receipt of the SHUTDOWN This chunk MUST be used to acknowledge the receipt of the SHUTDOWN
chunk at the completion of the shutdown process, see Section 9.2 for chunk at the completion of the shutdown process; see Section 9.2 for
details. details.
The SHUTDOWN ACK chunk has no parameters. The SHUTDOWN ACK chunk has no parameters.
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Type = 8 |Chunk Flags | Length = 4 | | Type = 8 |Chunk Flags | Length = 4 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Chunk Flags: 8 bits Chunk Flags: 8 bits
Set to zero on transmit and ignored on receipt. Set to 0 on transmit and ignored on receipt.
3.3.10. Operation Error (ERROR) (9): 3.3.10. Operation Error (ERROR) (9)
An endpoint sends this chunk to its peer endpoint to notify it of An endpoint sends this chunk to its peer endpoint to notify it of
certain error conditions. It contains one or more error causes. An certain error conditions. It contains one or more error causes. An
Operation Error is not considered fatal in and of itself, but may be Operation Error is not considered fatal in and of itself, but may be
used with an ABORT chunk to report a fatal condition. It has the used with an ABORT chunk to report a fatal condition. It has the
following parameters: following parameters:
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Type = 9 | Chunk Flags | Length | | Type = 9 | Chunk Flags | Length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\ \ \ \
/ one or more Error Causes / / one or more Error Causes /
\ \ \ \
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Chunk Flags: 8 bits Chunk Flags: 8 bits
Set to zero on transmit and ignored on receipt. Set to 0 on transmit and ignored on receipt.
Length: 16 bits (unsigned integer) Length: 16 bits (unsigned integer)
Set to the size of the chunk in bytes, including the chunk header Set to the size of the chunk in bytes, including the chunk header
and all the Error Cause fields present. and all the Error Cause fields present.
Error causes are defined as variable-length parameters using the Error causes are defined as variable-length parameters using the
format described in 3.2.1, i.e.: format described in Section 3.2.1, that is:
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Cause Code | Cause Length | | Cause Code | Cause Length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
/ Cause-specific Information / / Cause-Specific Information /
\ \ \ \
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Cause Code: 16 bits (unsigned integer) Cause Code: 16 bits (unsigned integer)
Defines the type of error conditions being reported. Defines the type of error conditions being reported.
Cause Code Cause Code
Value Cause Code Value Cause Code
--------- ---------------- --------- ----------------
skipping to change at page 44, line 40 skipping to change at page 43, line 43
10 Cookie Received While Shutting Down 10 Cookie Received While Shutting Down
11 Restart of an Association with New Addresses 11 Restart of an Association with New Addresses
12 User Initiated Abort 12 User Initiated Abort
13 Protocol Violation 13 Protocol Violation
Cause Length: 16 bits (unsigned integer) Cause Length: 16 bits (unsigned integer)
Set to the size of the parameter in bytes, including the Cause Set to the size of the parameter in bytes, including the Cause
Code, Cause Length, and Cause-Specific Information fields. Code, Cause Length, and Cause-Specific Information fields.
Cause-specific Information: variable length Cause-Specific Information: variable length
This field carries the details of the error condition. This field carries the details of the error condition.
Section 3.3.10.1 - Section 3.3.10.13 define error causes for SCTP. Section 3.3.10.1 - Section 3.3.10.13 define error causes for SCTP.
Guidelines for the IETF to define new error cause values are Guidelines for the IETF to define new error cause values are
discussed in Section 14.3. discussed in Section 14.3.
3.3.10.1. Invalid Stream Identifier (1) 3.3.10.1. Invalid Stream Identifier (1)
Cause of error Cause of error
skipping to change at page 45, line 28 skipping to change at page 44, line 27
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Stream Identifier: 16 bits (unsigned integer) Stream Identifier: 16 bits (unsigned integer)
Contains the Stream Identifier of the DATA chunk received in Contains the Stream Identifier of the DATA chunk received in
error. error.
Reserved: 16 bits Reserved: 16 bits
This field is reserved. It is set to all 0's on transmit and This field is reserved. It is set to all 0's on transmit and
Ignored on receipt. ignored on receipt.
3.3.10.2. Missing Mandatory Parameter (2) 3.3.10.2. Missing Mandatory Parameter (2)
Cause of error Cause of error
--------------- ---------------
Missing Mandatory Parameter: Indicates that one or more mandatory TLV Missing Mandatory Parameter: Indicates that one or more mandatory TLV
parameters are missing in a received INIT or INIT ACK. parameters are missing in a received INIT or INIT ACK.
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Cause Code=2 | Cause Length=8+N*2 | | Cause Code=2 | Cause Length=8+N*2 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Number of missing params=N | | Number of missing params=N |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
skipping to change at page 46, line 4 skipping to change at page 44, line 48
| Cause Code=2 | Cause Length=8+N*2 | | Cause Code=2 | Cause Length=8+N*2 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Number of missing params=N | | Number of missing params=N |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Missing Param Type #1 | Missing Param Type #2 | | Missing Param Type #1 | Missing Param Type #2 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Missing Param Type #N-1 | Missing Param Type #N | | Missing Param Type #N-1 | Missing Param Type #N |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Number of Missing params: 32 bits (unsigned integer) Number of Missing params: 32 bits (unsigned integer)
This field contains the number of parameters contained in the This field contains the number of parameters contained in the
Cause-specific Information field. Cause-Specific Information field.
Missing Param Type: 16 bits (unsigned integer) Missing Param Type: 16 bits (unsigned integer)
Each field will contain the missing mandatory parameter number. Each field will contain the missing mandatory parameter number.
3.3.10.3. Stale Cookie Error (3) 3.3.10.3. Stale Cookie Error (3)
Cause of error Cause of error
-------------- --------------
Stale Cookie Error: Indicates the receipt of a valid State Cookie Stale Cookie Error: Indicates the receipt of a valid State Cookie
that has expired. that has expired.
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Cause Code=3 | Cause Length=8 | | Cause Code=3 | Cause Length=8 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Measure of Staleness (usec.) | | Measure of Staleness (usec.) |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
skipping to change at page 46, line 34 skipping to change at page 45, line 31
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Measure of Staleness: 32 bits (unsigned integer) Measure of Staleness: 32 bits (unsigned integer)
This field contains the difference, in microseconds, between the This field contains the difference, in microseconds, between the
current time and the time the State Cookie expired. current time and the time the State Cookie expired.
The sender of this error cause MAY choose to report how long past The sender of this error cause MAY choose to report how long past
expiration the State Cookie is by including a non-zero value in expiration the State Cookie is by including a non-zero value in
the Measure of Staleness field. If the sender does not wish to the Measure of Staleness field. If the sender does not wish to
provide this information it should set the Measure of Staleness provide this information, it should set the Measure of Staleness
field to the value of zero. field to the value of zero.
3.3.10.4. Out of Resource (4) 3.3.10.4. Out of Resource (4)
Cause of error Cause of error
--------------- ---------------
Out of Resource: Indicates that the sender is out of resource. This Out of Resource: Indicates that the sender is out of resource. This
is usually sent in combination with or within an ABORT. is usually sent in combination with or within an ABORT.
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Cause Code=4 | Cause Length=4 | | Cause Code=4 | Cause Length=4 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
3.3.10.5. Unresolvable Address (5) 3.3.10.5. Unresolvable Address (5)
skipping to change at page 47, line 25 skipping to change at page 46, line 24
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Cause Code=5 | Cause Length | | Cause Code=5 | Cause Length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
/ Unresolvable Address / / Unresolvable Address /
\ \ \ \
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Unresolvable Address: variable length Unresolvable Address: variable length
The unresolvable address field contains the complete Type, Length The Unresolvable Address field contains the complete Type, Length,
and Value of the address parameter (or Host Name parameter) that and Value of the address parameter (or Host Name parameter) that
contains the unresolvable address or host name. contains the unresolvable address or host name.
3.3.10.6. Unrecognized Chunk Type (6) 3.3.10.6. Unrecognized Chunk Type (6)
Cause of error Cause of error
--------------- ---------------
Unrecognized Chunk Type: This error cause is returned to the Unrecognized Chunk Type: This error cause is returned to the
originator of the chunk if the receiver does not understand the chunk originator of the chunk if the receiver does not understand the chunk
and the upper bits of the 'Chunk Type' are set to 01 or 11. and the upper bits of the 'Chunk Type' are set to 01 or 11.
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Cause Code=6 | Cause Length | | Cause Code=6 | Cause Length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
/ Unrecognized Chunk / / Unrecognized Chunk /
skipping to change at page 47, line 48 skipping to change at page 46, line 46
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Cause Code=6 | Cause Length | | Cause Code=6 | Cause Length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
/ Unrecognized Chunk / / Unrecognized Chunk /
\ \ \ \
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Unrecognized Chunk: variable length Unrecognized Chunk: variable length
The Unrecognized Chunk field contains the unrecognized Chunk from The Unrecognized Chunk field contains the unrecognized chunk from
the SCTP packet complete with Chunk Type, Chunk Flags and Chunk the SCTP packet complete with Chunk Type, Chunk Flags, and Chunk
Length. Length.
3.3.10.7. Invalid Mandatory Parameter (7) 3.3.10.7. Invalid Mandatory Parameter (7)
Cause of error Cause of error
--------------- ---------------
Invalid Mandatory Parameter: This error cause is returned to the Invalid Mandatory Parameter: This error cause is returned to the
originator of an INIT or INIT ACK chunk when one of the mandatory originator of an INIT or INIT ACK chunk when one of the mandatory
parameters is set to a invalid value. parameters is set to an invalid value.
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Cause Code=7 | Cause Length=4 | | Cause Code=7 | Cause Length=4 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
3.3.10.8. Unrecognized Parameters (8) 3.3.10.8. Unrecognized Parameters (8)
Cause of error Cause of error
--------------- ---------------
Unrecognized Parameters: This error cause is returned to the Unrecognized Parameters: This error cause is returned to the
originator of the INIT ACK chunk if the receiver does not recognize originator of the INIT ACK chunk if the receiver does not recognize
one or more Optional TLV parameters in the INIT ACK chunk. one or more Optional TLV parameters in the INIT ACK chunk.
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Cause Code=8 | Cause Length | | Cause Code=8 | Cause Length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
/ Unrecognized Parameters / / Unrecognized Parameters /
skipping to change at page 48, line 48 skipping to change at page 48, line 8
The Unrecognized Parameters field contains the unrecognized The Unrecognized Parameters field contains the unrecognized
parameters copied from the INIT ACK chunk complete with TLV. This parameters copied from the INIT ACK chunk complete with TLV. This
error cause is normally contained in an ERROR chunk bundled with error cause is normally contained in an ERROR chunk bundled with
the COOKIE ECHO chunk when responding to the INIT ACK, when the the COOKIE ECHO chunk when responding to the INIT ACK, when the
sender of the COOKIE ECHO chunk wishes to report unrecognized sender of the COOKIE ECHO chunk wishes to report unrecognized
parameters. parameters.
3.3.10.9. No User Data (9) 3.3.10.9. No User Data (9)
Cause of error Cause of error
--------------- ---------------
No User Data: This error cause is returned to the originator of a No User Data: This error cause is returned to the originator of a
DATA chunk if a received DATA chunk has no user data. DATA chunk if a received DATA chunk has no user data.
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Cause Code=9 | Cause Length=8 | | Cause Code=9 | Cause Length=8 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
/ TSN value / / TSN value /
\ \ \ \
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
TSN value: 32 bits (+unsigned integer) TSN value: 32 bits (unsigned integer)
The TSN value field contains the TSN of the DATA chunk received The TSN value field contains the TSN of the DATA chunk received
with no user data field. with no user data field.
This cause code is normally returned in an ABORT chunk (see This cause code is normally returned in an ABORT chunk (see
Section 6.2) Section 6.2).
3.3.10.10. Cookie Received While Shutting Down (10) 3.3.10.10. Cookie Received While Shutting Down (10)
Cause of error Cause of error
--------------- ---------------
Cookie Received While Shutting Down: A COOKIE ECHO was received While Cookie Received While Shutting Down: A COOKIE ECHO was received while
the endpoint was in SHUTDOWN-ACK-SENT state. This error is usually the endpoint was in the SHUTDOWN-ACK-SENT state. This error is
returned in an ERROR chunk bundled with the retransmitted SHUTDOWN usually returned in an ERROR chunk bundled with the retransmitted
ACK. SHUTDOWN ACK.
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Cause Code=10 | Cause Length=4 | | Cause Code=10 | Cause Length=4 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
3.3.10.11. Restart of an Association with New Addresses (11) 3.3.10.11. Restart of an Association with New Addresses (11)
Cause of error Cause of error
-------------- --------------
Restart of an association with new addresses: An INIT was received on Restart of an association with new addresses: An INIT was received on
an existing association. But the INIT added addresses to the an existing association. But the INIT added addresses to the
association that were previously NOT part of the association. The association that were previously NOT part of the association. The
new addresses are listed in the error code. This ERROR is normally new addresses are listed in the error code. This ERROR is normally
sent as part of an ABORT refusing the INIT (see Section 5.2). sent as part of an ABORT refusing the INIT (see Section 5.2).
0 1 2 3 0 1 2 3
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 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
skipping to change at page 50, line 16 skipping to change at page 49, line 27
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Cause Code=11 | Cause Length=Variable | | Cause Code=11 | Cause Length=Variable |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
/ New Address TLVs / / New Address TLVs /
\ \ \ \
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Note: Each New Address TLV is an exact copy of the TLV that was found Note: Each New Address TLV is an exact copy of the TLV that was found
in the INIT chunk that was new, including the Parameter Type and the in the INIT chunk that was new, including the Parameter Type and the
Parameter length. Parameter Length.
3.3.10.12. User-Initiated Abort (12) 3.3.10.12. User-Initiated Abort (12)
Cause of error Cause of error
-------------- --------------
This error cause MAY be included in ABORT chunks that are sent This error cause MAY be included in ABORT chunks that are sent
because of an upper layer request. The upper layer can specify an because of an upper-layer request. The upper layer can specify an
Upper Layer Abort Reason that is transported by SCTP transparently Upper Layer Abort Reason that is transported by SCTP transparently
and MAY be delivered to the upper layer protocol at the peer. and MAY be delivered to the upper-layer protocol at the peer.
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Cause Code=12 | Cause Length=Variable | | Cause Code=12 | Cause Length=Variable |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
/ Upper Layer Abort Reason / / Upper Layer Abort Reason /
\ \ \ \
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
skipping to change at page 51, line 14 skipping to change at page 50, line 26
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Cause Code=13 | Cause Length=Variable | | Cause Code=13 | Cause Length=Variable |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
/ Additional Information / / Additional Information /
\ \ \ \
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
3.3.11. Cookie Echo (COOKIE ECHO) (10): 3.3.11. Cookie Echo (COOKIE ECHO) (10)
This chunk is used only during the initialization of an association. This chunk is used only during the initialization of an association.
It is sent by the initiator of an association to its peer to complete It is sent by the initiator of an association to its peer to complete
the initialization process. This chunk MUST precede any DATA chunk the initialization process. This chunk MUST precede any DATA chunk
sent within the association, but MAY be bundled with one or more DATA sent within the association, but MAY be bundled with one or more DATA
chunks in the same packet. chunks in the same packet.
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Type = 10 |Chunk Flags | Length | | Type = 10 |Chunk Flags | Length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
/ Cookie / / Cookie /
\ \ \ \
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Chunk Flags: 8 bit Chunk Flags: 8 bit
Set to zero on transmit and ignored on receipt. Set to 0 on transmit and ignored on receipt.
Length: 16 bits (unsigned integer) Length: 16 bits (unsigned integer)
Set to the size of the chunk in bytes, including the 4 bytes of Set to the size of the chunk in bytes, including the 4 bytes of
the chunk header and the size of the Cookie. the chunk header and the size of the cookie.
Cookie: variable size Cookie: variable size
This field must contain the exact cookie received in the State This field must contain the exact cookie received in the State
Cookie parameter from the previous INIT ACK. Cookie parameter from the previous INIT ACK.
An implementation SHOULD make the cookie as small as possible to An implementation SHOULD make the cookie as small as possible to
insure interoperability. ensure interoperability.
Note: A Cookie Echo does NOT contain a State Cookie Parameter; Note: A Cookie Echo does NOT contain a State Cookie parameter;
instead, the data within the State Cookie's Parameter Value instead, the data within the State Cookie's Parameter Value
becomes the data within the Cookie Echo's Chunk Value. This becomes the data within the Cookie Echo's Chunk Value. This
allows an implementation to change only the first two bytes of the allows an implementation to change only the first 2 bytes of the
State Cookie parameter to become a Cookie Echo Chunk. State Cookie parameter to become a COOKIE ECHO chunk.
3.3.12. Cookie Acknowledgement (COOKIE ACK) (11): 3.3.12. Cookie Acknowledgement (COOKIE ACK) (11)
This chunk is used only during the initialization of an association. This chunk is used only during the initialization of an association.
It is used to acknowledge the receipt of a COOKIE ECHO chunk. This It is used to acknowledge the receipt of a COOKIE ECHO chunk. This
chunk MUST precede any DATA or SACK chunk sent within the chunk MUST precede any DATA or SACK chunk sent within the
association, but MAY be bundled with one or more DATA chunks or SACK association, but MAY be bundled with one or more DATA chunks or SACK
chunk in the same SCTP packet. chunk's in the same SCTP packet.
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Type = 11 |Chunk Flags | Length = 4 | | Type = 11 |Chunk Flags | Length = 4 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Chunk Flags: 8 bits Chunk Flags: 8 bits
Set to zero on transmit and ignored on receipt. Set to 0 on transmit and ignored on receipt.
3.3.13. Shutdown Complete (SHUTDOWN COMPLETE) (14): 3.3.13. Shutdown Complete (SHUTDOWN COMPLETE) (14)
This chunk MUST be used to acknowledge the receipt of the SHUTDOWN This chunk MUST be used to acknowledge the receipt of the SHUTDOWN
ACK chunk at the completion of the shutdown process, see Section 9.2 ACK chunk at the completion of the shutdown process; see Section 9.2
for details. for details.
The SHUTDOWN COMPLETE chunk has no parameters. The SHUTDOWN COMPLETE chunk has no parameters.
0 1 2 3 0 1 2 3
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 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Type = 14 |Reserved |T| Length = 4 | | Type = 14 |Reserved |T| Length = 4 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
skipping to change at page 53, line 18 skipping to change at page 52, line 21
expected by the peer. If the Verification Tag is reflected, the T expected by the peer. If the Verification Tag is reflected, the T
bit MUST be set to 1. Reflecting means that the sent Verification bit MUST be set to 1. Reflecting means that the sent Verification
Tag is the same as the received one. Tag is the same as the received one.
Note: Special rules apply to this chunk for verification, please see Note: Special rules apply to this chunk for verification, please see
Section 8.5.1 for details. Section 8.5.1 for details.
4. SCTP Association State Diagram 4. SCTP Association State Diagram
During the lifetime of an SCTP association, the SCTP endpoint's During the lifetime of an SCTP association, the SCTP endpoint's
association progress from one state to another in response to various association progresses from one state to another in response to
events. The events that may potentially advance an association's various events. The events that may potentially advance an
state include: association's state include:
o SCTP user primitive calls, e.g., [ASSOCIATE], [SHUTDOWN], [ABORT], o SCTP user primitive calls, e.g., [ASSOCIATE], [SHUTDOWN], [ABORT],
o Reception of INIT, COOKIE ECHO, ABORT, SHUTDOWN, etc., control o Reception of INIT, COOKIE ECHO, ABORT, SHUTDOWN, etc., control
chunks, or chunks, or
o Some timeout events. o Some timeout events.
The state diagram in the figures below illustrates state changes, The state diagram in the figures below illustrates state changes,
together with the causing events and resulting actions. Note that together with the causing events and resulting actions. Note that
some of the error conditions are not shown in the state diagram. some of the error conditions are not shown in the state diagram.
Full description of all special cases are found in the text. Full descriptions of all special cases are found in the text.
Note: Chunk names are given in all capital letters, while parameter Note: Chunk names are given in all capital letters, while parameter
names have the first letter capitalized, e.g., COOKIE ECHO chunk type names have the first letter capitalized, e.g., COOKIE ECHO chunk type
vs. State Cookie parameter. If more than one event/message can occur vs. State Cookie parameter. If more than one event/message can occur
which causes a state transition it is labeled (A), (B) etc. that causes a state transition, it is labeled (A), (B), etc.
----- -------- (from any state) ----- -------- (from any state)
/ \ / rcv ABORT [ABORT] / \ / rcv ABORT [ABORT]
rcv INIT | | | ---------- or ---------- rcv INIT | | | ---------- or ----------
--------------- | v v delete TCB snd ABORT --------------- | v v delete TCB snd ABORT
generate Cookie \ +---------+ delete TCB generate Cookie \ +---------+ delete TCB
snd INIT ACK ---| CLOSED | snd INIT ACK ---| CLOSED |
+---------+ +---------+
/ \ [ASSOCIATE] / \ [ASSOCIATE]
/ \ --------------- / \ ---------------
skipping to change at page 56, line 6 skipping to change at page 55, line 25
Notes: Notes:
1) If the State Cookie in the received COOKIE ECHO is invalid (i.e., 1) If the State Cookie in the received COOKIE ECHO is invalid (i.e.,
failed to pass the integrity check), the receiver MUST silently failed to pass the integrity check), the receiver MUST silently
discard the packet. Or, if the received State Cookie is expired discard the packet. Or, if the received State Cookie is expired
(see Section 5.1.5), the receiver MUST send back an ERROR chunk. (see Section 5.1.5), the receiver MUST send back an ERROR chunk.
In either case, the receiver stays in the CLOSED state. In either case, the receiver stays in the CLOSED state.
2) If the T1-init timer expires, the endpoint MUST retransmit INIT 2) If the T1-init timer expires, the endpoint MUST retransmit INIT
and re-start the T1-init timer without changing state. This MUST and restart the T1-init timer without changing state. This MUST
be repeated up to 'Max.Init.Retransmits' times. After that, the be repeated up to 'Max.Init.Retransmits' times. After that, the
endpoint MUST abort the initialization process and report the endpoint MUST abort the initialization process and report the
error to SCTP user. error to the SCTP user.
3) If the T1-cookie timer expires, the endpoint MUST retransmit 3) If the T1-cookie timer expires, the endpoint MUST retransmit
COOKIE ECHO and re-start the T1-cookie timer without changing COOKIE ECHO and restart the T1-cookie timer without changing
state. This MUST be repeated up to 'Max.Init.Retransmits' times. state. This MUST be repeated up to 'Max.Init.Retransmits' times.
After that, the endpoint MUST abort the initialization process After that, the endpoint MUST abort the initialization process
and report the error to SCTP user. and report the error to the SCTP user.
4) In SHUTDOWN-SENT state the endpoint MUST acknowledge any received 4) In the SHUTDOWN-SENT state, the endpoint MUST acknowledge any
DATA chunks without delay. received DATA chunks without delay.
5) In SHUTDOWN-RECEIVED state, the endpoint MUST NOT accept any new 5) In the SHUTDOWN-RECEIVED state, the endpoint MUST NOT accept any
send request from its SCTP user. new send requests from its SCTP user.
6) In SHUTDOWN-RECEIVED state, the endpoint MUST transmit or 6) In the SHUTDOWN-RECEIVED state, the endpoint MUST transmit or
retransmit data and leave this state when all data in queue is retransmit data and leave this state when all data in queue is
transmitted. transmitted.
7) In SHUTDOWN-ACK-SENT state, the endpoint MUST NOT accept any new 7) In the SHUTDOWN-ACK-SENT state, the endpoint MUST NOT accept any
send request from its SCTP user. new send requests from its SCTP user.
The CLOSED state is used to indicate that an association is not The CLOSED state is used to indicate that an association is not
created (i.e., doesn't exist). created (i.e., doesn't exist).
5. Association Initialization 5. Association Initialization
Before the first data transmission can take place from one SCTP Before the first data transmission can take place from one SCTP
endpoint ("A") to another SCTP endpoint ("Z"), the two endpoints must endpoint ("A") to another SCTP endpoint ("Z"), the two endpoints must
complete an initialization process in order to set up an SCTP complete an initialization process in order to set up an SCTP
association between them. association between them.
The SCTP user at an endpoint should use the ASSOCIATE primitive to The SCTP user at an endpoint should use the ASSOCIATE primitive to
initialize an SCTP association to another SCTP endpoint. initialize an SCTP association to another SCTP endpoint.
IMPLEMENTATION NOTE: From an SCTP-user's point of view, an IMPLEMENTATION NOTE: From an SCTP user's point of view, an
association may be implicitly opened, without an ASSOCIATE primitive association may be implicitly opened, without an ASSOCIATE primitive
(see Section 10.1 B) being invoked, by the initiating endpoint's (see Section 10.1 B) being invoked, by the initiating endpoint's
sending of the first user data to the destination endpoint. The sending of the first user data to the destination endpoint. The
initiating SCTP will assume default values for all mandatory and initiating SCTP will assume default values for all mandatory and
optional parameters for the INIT/INIT ACK. optional parameters for the INIT/INIT ACK.
Once the association is established, unidirectional streams are open Once the association is established, unidirectional streams are open
for data transfer on both ends (see Section 5.1.1). for data transfer on both ends (see Section 5.1.1).
5.1. Normal Establishment of an Association 5.1. Normal Establishment of an Association
skipping to change at page 57, line 29 skipping to change at page 56, line 49
destination IP address of the INIT ACK MUST be set to the source destination IP address of the INIT ACK MUST be set to the source
IP address of the INIT to which this INIT ACK is responding. In IP address of the INIT to which this INIT ACK is responding. In
the response, besides filling in other parameters, "Z" must set the response, besides filling in other parameters, "Z" must set
the Verification Tag field to Tag_A, and also provide its own the Verification Tag field to Tag_A, and also provide its own
Verification Tag (Tag_Z) in the Initiate Tag field. Verification Tag (Tag_Z) in the Initiate Tag field.
Moreover, "Z" MUST generate and send along with the INIT ACK a Moreover, "Z" MUST generate and send along with the INIT ACK a
State Cookie. See Section 5.1.3 for State Cookie generation. State Cookie. See Section 5.1.3 for State Cookie generation.
Note: After sending out INIT ACK with the State Cookie parameter, Note: After sending out INIT ACK with the State Cookie parameter,
"Z" MUST NOT allocate any resources, nor keep any states for the "Z" MUST NOT allocate any resources or keep any states for the new
new association. Otherwise, "Z" will be vulnerable to resource association. Otherwise, "Z" will be vulnerable to resource
attacks. attacks.
C) Upon reception of the INIT ACK from "Z", "A" shall stop the T1- C) Upon reception of the INIT ACK from "Z", "A" shall stop the T1-
init timer and leave COOKIE-WAIT state. "A" shall then send the init timer and leave the COOKIE-WAIT state. "A" shall then send
State Cookie received in the INIT ACK chunk in a COOKIE ECHO the State Cookie received in the INIT ACK chunk in a COOKIE ECHO
chunk, start the T1-cookie timer, and enter the COOKIE-ECHOED chunk, start the T1-cookie timer, and enter the COOKIE-ECHOED
state. state.
Note: The COOKIE ECHO chunk can be bundled with any pending Note: The COOKIE ECHO chunk can be bundled with any pending
outbound DATA chunks, but it MUST be the first chunk in the packet outbound DATA chunks, but it MUST be the first chunk in the packet
and until the COOKIE ACK is returned the sender MUST NOT send any and until the COOKIE ACK is returned the sender MUST NOT send any
other packets to the peer. other packets to the peer.
D) Upon reception of the COOKIE ECHO chunk, Endpoint "Z" will reply D) Upon reception of the COOKIE ECHO chunk, endpoint "Z" will reply
with a COOKIE ACK chunk after building a TCB and moving to the with a COOKIE ACK chunk after building a TCB and moving to the
ESTABLISHED state. A COOKIE ACK chunk may be bundled with any ESTABLISHED state. A COOKIE ACK chunk may be bundled with any
pending DATA chunks (and/or SACK chunks), but the COOKIE ACK chunk pending DATA chunks (and/or SACK chunks), but the COOKIE ACK chunk
MUST be the first chunk in the packet. MUST be the first chunk in the packet.
IMPLEMENTATION NOTE: An implementation may choose to send the IMPLEMENTATION NOTE: An implementation may choose to send the
Communication Up notification to the SCTP user upon reception of a Communication Up notification to the SCTP user upon reception of a
valid COOKIE ECHO chunk. valid COOKIE ECHO chunk.
E) Upon reception of the COOKIE ACK, endpoint "A" will move from the E) Upon reception of the COOKIE ACK, endpoint "A" will move from the
skipping to change at page 58, line 33 skipping to change at page 58, line 7
parameters in the received INIT or INIT ACK, invalid parameter parameters in the received INIT or INIT ACK, invalid parameter
values, or lack of local resources, it SHOULD respond with an ABORT values, or lack of local resources, it SHOULD respond with an ABORT
chunk. It SHOULD also specify the cause of abort, such as the type chunk. It SHOULD also specify the cause of abort, such as the type
of the missing mandatory parameters, etc., by including the error of the missing mandatory parameters, etc., by including the error
cause parameters with the ABORT chunk. The Verification Tag field in cause parameters with the ABORT chunk. The Verification Tag field in
the common header of the outbound SCTP packet containing the ABORT the common header of the outbound SCTP packet containing the ABORT
chunk MUST be set to the Initiate Tag value of the peer. chunk MUST be set to the Initiate Tag value of the peer.
Note that a COOKIE ECHO chunk that does NOT pass the integrity check Note that a COOKIE ECHO chunk that does NOT pass the integrity check
is NOT considered an 'invalid parameter' and requires special is NOT considered an 'invalid parameter' and requires special
handling see Section 5.1 handling; see Section 5.1.5.
After the reception of the first DATA chunk in an association the After the reception of the first DATA chunk in an association the
endpoint MUST immediately respond with a SACK to acknowledge the DATA endpoint MUST immediately respond with a SACK to acknowledge the DATA
chunk. Subsequent acknowledgements should be done as described in chunk. Subsequent acknowledgements should be done as described in
Section 6.2. Section 6.2.
When the TCB is created, each endpoint MUST set its internal When the TCB is created, each endpoint MUST set its internal
Cumulative TSN Ack Point to the value of its transmitted Initial TSN Cumulative TSN Ack Point to the value of its transmitted Initial TSN
minus one. minus one.
IMPLEMENTATION NOTE: The IP addresses and SCTP port are generally IMPLEMENTATION NOTE: The IP addresses and SCTP port are generally
used as the key to find the TCB within an SCTP instance. used as the key to find the TCB within an SCTP instance.
5.1.1. Handle Stream Parameters 5.1.1. Handle Stream Parameters
In the INIT and INIT ACK chunks, the sender of the chunk MUST In the INIT and INIT ACK chunks, the sender of the chunk MUST
indicate the number of outbound streams (OS) it wishes to have in the indicate the number of outbound streams (OSs) it wishes to have in
association, as well as the maximum inbound streams (MIS) it will the association, as well as the maximum inbound streams (MISs) it
accept from the other endpoint. will accept from the other endpoint.
After receiving the stream configuration information from the other After receiving the stream configuration information from the other
side, each endpoint MUST perform the following check: If the peer's side, each endpoint MUST perform the following check: If the peer's
MIS is less than the endpoint's OS, meaning that the peer is MIS is less than the endpoint's OS, meaning that the peer is
incapable of supporting all the outbound streams the endpoint wants incapable of supporting all the outbound streams the endpoint wants
to configure, the endpoint MUST use MIS outbound streams and MAY to configure, the endpoint MUST use MIS outbound streams and MAY
report any shortage to the upper layer. The upper layer can then report any shortage to the upper layer. The upper layer can then
choose to abort the association if the resource shortage is choose to abort the association if the resource shortage is
unacceptable. unacceptable.
skipping to change at page 59, line 36 skipping to change at page 59, line 11
which the chunk arrives and record it, in combination with the which the chunk arrives and record it, in combination with the
SCTP source port number, as the only destination transport address SCTP source port number, as the only destination transport address
for this peer. for this peer.
B) If there is a Host Name parameter present in the received INIT or B) If there is a Host Name parameter present in the received INIT or
INIT ACK chunk, the endpoint shall resolve that host name to a INIT ACK chunk, the endpoint shall resolve that host name to a
list of IP address(es) and derive the transport address(es) of list of IP address(es) and derive the transport address(es) of
this peer by combining the resolved IP address(es) with the SCTP this peer by combining the resolved IP address(es) with the SCTP
source port. source port.
The endpoint MUST ignore any other IP address parameters if they The endpoint MUST ignore any other IP Address parameters if they
are also present in the received INIT or INIT ACK chunk. are also present in the received INIT or INIT ACK chunk.
The time at which the receiver of an INIT resolves the host name The time at which the receiver of an INIT resolves the host name
has potential security implications to SCTP. If the receiver of has potential security implications to SCTP. If the receiver of
an INIT resolves the host name upon the reception of the chunk, an INIT resolves the host name upon the reception of the chunk,
and the mechanism the receiver uses to resolve the host name and the mechanism the receiver uses to resolve the host name
involves potential long delay (e.g. DNS query), the receiver may involves potential long delay (e.g., DNS query), the receiver may
open itself up to resource attacks for the period of time while it open itself up to resource attacks for the period of time while it
is waiting for the name resolution results before it can build the is waiting for the name resolution results before it can build the
State Cookie and release local resources. State Cookie and release local resources.
Therefore, in cases where the name translation involves potential Therefore, in cases where the name translation involves potential
long delay, the receiver of the INIT MUST postpone the name long delay, the receiver of the INIT MUST postpone the name
resolution till the reception of the COOKIE ECHO chunk from the resolution till the reception of the COOKIE ECHO chunk from the
peer. In such a case, the receiver of the INIT SHOULD build the peer. In such a case, the receiver of the INIT SHOULD build the
State Cookie using the received Host Name (instead of destination State Cookie using the received Host Name (instead of destination
transport addresses) and send the INIT ACK to the source IP transport addresses) and send the INIT ACK to the source IP
skipping to change at page 60, line 24 skipping to change at page 59, line 48
If the name resolution is not successful, the endpoint MUST If the name resolution is not successful, the endpoint MUST
immediately send an ABORT with "Unresolvable Address" error cause immediately send an ABORT with "Unresolvable Address" error cause
to its peer. The ABORT shall be sent to the source IP address to its peer. The ABORT shall be sent to the source IP address
from which the last peer packet was received. from which the last peer packet was received.
C) If there are only IPv4/IPv6 addresses present in the received INIT C) If there are only IPv4/IPv6 addresses present in the received INIT
or INIT ACK chunk, the receiver MUST derive and record all the or INIT ACK chunk, the receiver MUST derive and record all the
transport addresses from the received chunk AND the source IP transport addresses from the received chunk AND the source IP
address that sent the INIT or INIT ACK. The transport addresses address that sent the INIT or INIT ACK. The transport addresses
are derived by the combination of SCTP source port (from the are derived by the combination of SCTP source port (from the
common header) and the IP address parameter(s) carried in the INIT common header) and the IP Address parameter(s) carried in the INIT
or INIT ACK chunk and the source IP address of the IP datagram. or INIT ACK chunk and the source IP address of the IP datagram.
The receiver should use only these transport addresses as The receiver should use only these transport addresses as
destination transport addresses when sending subsequent packets to destination transport addresses when sending subsequent packets to
its peer. its peer.
D) An INIT or INIT ACK chunk MUST be treated as belonging to an D) An INIT or INIT ACK chunk MUST be treated as belonging to an
already established association (or one in the process of being already established association (or one in the process of being
established) if the use of any of the valid address parameters established) if the use of any of the valid address parameters
contained within the chunk would identify an existing TCB. contained within the chunk would identify an existing TCB.
IMPLEMENTATION NOTE: In some cases (e.g., when the implementation IMPLEMENTATION NOTE: In some cases (e.g., when the implementation
doesn't control the source IP address that is used for transmitting), doesn't control the source IP address that is used for transmitting),
an endpoint might need to include in its INIT or INIT ACK all an endpoint might need to include in its INIT or INIT ACK all
possible IP addresses from which packets to the peer could be possible IP addresses from which packets to the peer could be
transmitted. transmitted.
skipping to change at page 60, line 44 skipping to change at page 60, line 20
IMPLEMENTATION NOTE: In some cases (e.g., when the implementation IMPLEMENTATION NOTE: In some cases (e.g., when the implementation
doesn't control the source IP address that is used for transmitting), doesn't control the source IP address that is used for transmitting),
an endpoint might need to include in its INIT or INIT ACK all an endpoint might need to include in its INIT or INIT ACK all
possible IP addresses from which packets to the peer could be possible IP addresses from which packets to the peer could be
transmitted. transmitted.
After all transport addresses are derived from the INIT or INIT ACK After all transport addresses are derived from the INIT or INIT ACK
chunk using the above rules, the endpoint shall select one of the chunk using the above rules, the endpoint shall select one of the
transport addresses as the initial primary path. transport addresses as the initial primary path.
Note: The INIT-ACK MUST be sent to the source address of the INIT. Note: The INIT ACK MUST be sent to the source address of the INIT.
The sender of INIT may include a 'Supported Address Types' parameter The sender of INIT may include a 'Supported Address Types' parameter
in the INIT to indicate what types of address are acceptable. When in the INIT to indicate what types of address are acceptable. When
this parameter is present, the receiver of INIT (initiatee) MUST this parameter is present, the receiver of INIT (initiate) MUST
either use one of the address types indicated in the Supported either use one of the address types indicated in the Supported
Address Types parameter when responding to the INIT, or abort the Address Types parameter when responding to the INIT, or abort the
association with an "Unresolvable Address" error cause if it is association with an "Unresolvable Address" error cause if it is
unwilling or incapable of using any of the address types indicated by unwilling or incapable of using any of the address types indicated by
its peer. its peer.
IMPLEMENTATION NOTE: In the case that the receiver of an INIT ACK IMPLEMENTATION NOTE: In the case that the receiver of an INIT ACK
fails to resolve the address parameter due to an unsupported type, it fails to resolve the address parameter due to an unsupported type, it
can abort the initiation process and then attempt a re-initiation by can abort the initiation process and then attempt a reinitiation by
using a 'Supported Address Types' parameter in the new INIT to using a 'Supported Address Types' parameter in the new INIT to
indicate what types of address it prefers. indicate what types of address it prefers.
IMPLEMENTATION NOTE: If an SCTP endpoint that only supports either IMPLEMENTATION NOTE: If an SCTP endpoint that only supports either
IPv4 or IPv6 receives IPv4 and IPv6 addresses in an INIT or INIT- ACK IPv4 or IPv6 receives IPv4 and IPv6 addresses in an INIT or INIT ACK
chunk from its peer, it MUST use all the addresses belonging to the chunk from its peer, it MUST use all the addresses belonging to the
supported address family. The other addresses MAY be ignored. The supported address family. The other addresses MAY be ignored. The
endpoint SHOULD NOT respond with any kind of error indication. endpoint SHOULD NOT respond with any kind of error indication.
IMPLEMENTATION NOTE: If an SCTP endpoint lists in the 'Supported IMPLEMENTATION NOTE: If an SCTP endpoint lists in the 'Supported
Address Types' parameter either IPv4 or IPv6, but uses the other Address Types' parameter either IPv4 or IPv6, but uses the other
family for sending the packet containing the INIT chunk, or if it family for sending the packet containing the INIT chunk, or if it
also lists addresses of the other family in the INIT chunk, then the also lists addresses of the other family in the INIT chunk, then the
address family that is not listed in the 'Supported Address Types' address family that is not listed in the 'Supported Address Types'
parameter SHOULD also be considered as supported by the receiver of parameter SHOULD also be considered as supported by the receiver of
skipping to change at page 62, line 4 skipping to change at page 61, line 28
received INIT and the outgoing INIT ACK chunk, received INIT and the outgoing INIT ACK chunk,
2) In the TCB, set the creation time to the current time of day, and 2) In the TCB, set the creation time to the current time of day, and
the lifespan to the protocol parameter 'Valid.Cookie.Life' (see the lifespan to the protocol parameter 'Valid.Cookie.Life' (see
Section 15 ), Section 15 ),
3) From the TCB, identify and collect the minimal subset of 3) From the TCB, identify and collect the minimal subset of
information needed to re-create the TCB, and generate a MAC using information needed to re-create the TCB, and generate a MAC using
this subset of information and a secret key (see [RFC2104] for an this subset of information and a secret key (see [RFC2104] for an
example of generating a MAC), and example of generating a MAC), and
4) Generate the State Cookie by combining this subset of information 4) Generate the State Cookie by combining this subset of information
and the resultant MAC. and the resultant MAC.
After sending the INIT ACK with the State Cookie parameter, the After sending the INIT ACK with the State Cookie parameter, the
sender SHOULD delete the TCB and any other local resource related to sender SHOULD delete the TCB and any other local resource related to
the new association, so as to prevent resource attacks. the new association, so as to prevent resource attacks.
The hashing method used to generate the MAC is strictly a private The hashing method used to generate the MAC is strictly a private
matter for the receiver of the INIT chunk. The use of a MAC is matter for the receiver of the INIT chunk. The use of a MAC is
mandatory to prevent denial of service attacks. The secret key mandatory to prevent denial-of-service attacks. The secret key
SHOULD be random ( [RFC4086] provides some information on randomness SHOULD be random ( [RFC4086] provides some information on randomness
guidelines); it SHOULD be changed reasonably frequently, and the guidelines); it SHOULD be changed reasonably frequently, and the
timestamp in the State Cookie MAY be used to determine which key timestamp in the State Cookie MAY be used to determine which key
should be used to verify the MAC. should be used to verify the MAC.
An implementation SHOULD make the cookie as small as possible to An implementation SHOULD make the cookie as small as possible to
insure interoperability. ensure interoperability.
5.1.4. State Cookie Processing 5.1.4. State Cookie Processing
When an endpoint (in the COOKIE WAIT state) receives an INIT ACK When an endpoint (in the COOKIE-WAIT state) receives an INIT ACK
chunk with a State Cookie parameter, it MUST immediately send a chunk with a State Cookie parameter, it MUST immediately send a
COOKIE ECHO chunk to its peer with the received State Cookie. The COOKIE ECHO chunk to its peer with the received State Cookie. The
sender MAY also add any pending DATA chunks to the packet after the sender MAY also add any pending DATA chunks to the packet after the
COOKIE ECHO chunk. COOKIE ECHO chunk.
The endpoint shall also start the T1-cookie timer after sending out The endpoint shall also start the T1-cookie timer after sending out
the COOKIE ECHO chunk. If the timer expires, the endpoint shall the COOKIE ECHO chunk. If the timer expires, the endpoint shall
retransmit the COOKIE ECHO chunk and restart the T1-cookie timer. retransmit the COOKIE ECHO chunk and restart the T1-cookie timer.
This is repeated until either a COOKIE ACK is received or This is repeated until either a COOKIE ACK is received or
'Max.Init.Retransmits' (see Section 15 is reached causing the peer 'Max.Init.Retransmits' (see Section 15) is reached causing the peer
endpoint to be marked unreachable (and thus the association enters endpoint to be marked unreachable (and thus the association enters
the CLOSED state). the CLOSED state).
5.1.5. State Cookie Authentication 5.1.5. State Cookie Authentication
When an endpoint receives a COOKIE ECHO chunk from another endpoint When an endpoint receives a COOKIE ECHO chunk from another endpoint
with which it has no association, it shall take the following with which it has no association, it shall take the following
actions: actions:
1) Compute a MAC using the TCB data carried in the State Cookie and 1) Compute a MAC using the TCB data carried in the State Cookie and
the secret key (note the timestamp in the State Cookie MAY be the secret key (note the timestamp in the State Cookie MAY be
used to determine which secret key to use). Reference [RFC2104] used to determine which secret key to use). [RFC2104] can be
can be used as a guideline for generating the MAC, used as a guideline for generating the MAC,
2) Authenticate the State Cookie as one that it previously generated 2) Authenticate the State Cookie as one that it previously generated
by comparing the computed MAC against the one carried in the by comparing the computed MAC against the one carried in the
State Cookie. If this comparison fails, the SCTP packet, State Cookie. If this comparison fails, the SCTP packet,
including the COOKIE ECHO and any DATA chunks, should be silently including the COOKIE ECHO and any DATA chunks, should be silently
discarded, discarded,
3) Compare the port numbers and the Verification Tag contained 3) Compare the port numbers and the Verification Tag contained
within the COOKIE ECHO chunk to the actual port numbers and the within the COOKIE ECHO chunk to the actual port numbers and the
Verification Tag within the SCTP common header of the received Verification Tag within the SCTP common header of the received
packet. If these values do not match, the packet MUST be packet. If these values do not match, the packet MUST be
skipping to change at page 63, line 35 skipping to change at page 63, line 17
carried in the COOKIE ECHO and enter the ESTABLISHED state. carried in the COOKIE ECHO and enter the ESTABLISHED state.
6) Send a COOKIE ACK chunk to the peer acknowledging receipt of the 6) Send a COOKIE ACK chunk to the peer acknowledging receipt of the
COOKIE ECHO. The COOKIE ACK MAY be bundled with an outbound DATA COOKIE ECHO. The COOKIE ACK MAY be bundled with an outbound DATA
chunk or SACK chunk; however, the COOKIE ACK MUST be the first chunk or SACK chunk; however, the COOKIE ACK MUST be the first
chunk in the SCTP packet. chunk in the SCTP packet.
7) Immediately acknowledge any DATA chunk bundled with the COOKIE 7) Immediately acknowledge any DATA chunk bundled with the COOKIE
ECHO with a SACK (subsequent DATA chunk acknowledgement should ECHO with a SACK (subsequent DATA chunk acknowledgement should
follow the rules defined in Section 6.2). As mentioned in step follow the rules defined in Section 6.2). As mentioned in step
5, if the SACK is bundled with the COOKIE ACK, the COOKIE ACK 6, if the SACK is bundled with the COOKIE ACK, the COOKIE ACK
MUST appear first in the SCTP packet. MUST appear first in the SCTP packet.
If a COOKIE ECHO is received from an endpoint with which the receiver If a COOKIE ECHO is received from an endpoint with which the receiver
of the COOKIE ECHO has an existing association, the procedures in of the COOKIE ECHO has an existing association, the procedures in
Section 5.2 should be followed. Section 5.2 should be followed.
5.1.6. An Example of Normal Association Establishment 5.1.6. An Example of Normal Association Establishment
In the following example, "A" initiates the association and then In the following example, "A" initiates the association and then
sends a user message to "Z", then "Z" sends two user messages to "A" sends a user message to "Z", then "Z" sends two user messages to "A"
skipping to change at page 64, line 45 skipping to change at page 65, line 4
/ [TSN=init TSN_Z / [TSN=init TSN_Z
<--/ Strm=0,Seq=0 & user data 1] <--/ Strm=0,Seq=0 & user data 1]
SACK [TSN Ack=init TSN_Z, /---- DATA SACK [TSN Ack=init TSN_Z, /---- DATA
Block=0] --------\ / [TSN=init TSN_Z +1, Block=0] --------\ / [TSN=init TSN_Z +1,
\/ Strm=0,Seq=1 & user data 2] \/ Strm=0,Seq=1 & user data 2]
<------/\ <------/\
\ \
\------> \------>
Figure 4: INITIATION Example Figure 4: INITIATION Example
If the T1-init timer expires at "A" after the INIT or COOKIE ECHO If the T1-init timer expires at "A" after the INIT or COOKIE ECHO
chunks are sent, the same INIT or COOKIE ECHO chunk with the same chunks are sent, the same INIT or COOKIE ECHO chunk with the same
Initiate Tag (i.e., Tag_A) or State Cookie shall be retransmitted and Initiate Tag (i.e., Tag_A) or State Cookie shall be retransmitted and
the timer restarted. This shall be repeated Max.Init.Retransmits the timer restarted. This shall be repeated Max.Init.Retransmits
times before "A" considers "Z" unreachable and reports the failure to times before "A" considers "Z" unreachable and reports the failure to
its upper layer (and thus the association enters the CLOSED state). its upper layer (and thus the association enters the CLOSED state).
When retransmitting the INIT, the endpoint MUST follow the rules When retransmitting the INIT, the endpoint MUST follow the rules
defined in 6.3 to determine the proper timer value. defined in Section 6.3 to determine the proper timer value.
5.2. Handle Duplicate or Unexpected INIT, INIT ACK, COOKIE ECHO, and 5.2. Handle Duplicate or Unexpected INIT, INIT ACK, COOKIE ECHO, and
COOKIE ACK COOKIE ACK
During the lifetime of an association (in one of the possible During the lifetime of an association (in one of the possible
states), an endpoint may receive from its peer endpoint one of the states), an endpoint may receive from its peer endpoint one of the
setup chunks (INIT, INIT ACK, COOKIE ECHO, and COOKIE ACK). The setup chunks (INIT, INIT ACK, COOKIE ECHO, and COOKIE ACK). The
receiver shall treat such a setup chunk as a duplicate and process it receiver shall treat such a setup chunk as a duplicate and process it
as described in this section. as described in this section.
Note: An endpoint will not receive the chunk unless the chunk was Note: An endpoint will not receive the chunk unless the chunk was
sent to a SCTP transport address and is from a SCTP transport address sent to an SCTP transport address and is from an SCTP transport
associated with this endpoint. Therefore, the endpoint processes address associated with this endpoint. Therefore, the endpoint
such a chunk as part of its current association. processes such a chunk as part of its current association.
The following scenarios can cause duplicated or unexpected chunks: The following scenarios can cause duplicated or unexpected chunks:
A) The peer has crashed without being detected, re-started itself and A) The peer has crashed without being detected, restarted itself, and
sent out a new INIT chunk trying to restore the association, sent out a new INIT chunk trying to restore the association,
B) Both sides are trying to initialize the association at about the B) Both sides are trying to initialize the association at about the
same time, same time,
C) The chunk is from a stale packet that was used to establish the C) The chunk is from a stale packet that was used to establish the
present association or a past association that is no longer in present association or a past association that is no longer in
existence, existence,
D) The chunk is a false packet generated by an attacker, or D) The chunk is a false packet generated by an attacker, or
E) The peer never received the COOKIE ACK and is retransmitting its E) The peer never received the COOKIE ACK and is retransmitting its
COOKIE ECHO. COOKIE ECHO.
The rules in the following sections shall be applied in order to The rules in the following sections shall be applied in order to
identify and correctly handle these cases. identify and correctly handle these cases.
5.2.1. INIT received in COOKIE-WAIT or COOKIE-ECHOED State (Item B) 5.2.1. INIT Received in COOKIE-WAIT or COOKIE-ECHOED State (Item B)
This usually indicates an initialization collision, i.e., each This usually indicates an initialization collision, i.e., each
endpoint is attempting, at about the same time, to establish an endpoint is attempting, at about the same time, to establish an
association with the other endpoint. association with the other endpoint.
Upon receipt of an INIT in the COOKIE-WAIT state, an endpoint MUST Upon receipt of an INIT in the COOKIE-WAIT state, an endpoint MUST
respond with an INIT ACK using the same parameters it sent in its respond with an INIT ACK using the same parameters it sent in its
original INIT chunk (including its Initiation Tag, unchanged). When original INIT chunk (including its Initiate Tag, unchanged). When
responding, the endpoint MUST send the INIT ACK back to the same responding, the endpoint MUST send the INIT ACK back to the same
address that the original INIT (sent by this endpoint) was sent to. address that the original INIT (sent by this endpoint) was sent.
Upon receipt of an INIT in the COOKIE-ECHOED state, an endpoint MUST Upon receipt of an INIT in the COOKIE-ECHOED state, an endpoint MUST
respond with an INIT ACK using the same parameters it sent in its respond with an INIT ACK using the same parameters it sent in its
original INIT chunk (including its Initiation Tag, unchanged), original INIT chunk (including its Initiate Tag, unchanged), provided
provided that no NEW address has been added to the forming that no NEW address has been added to the forming association. If
association. If the INIT message indicates that a new address has the INIT message indicates that a new address has been added to the
been added to the association, then the entire INIT MUST be association, then the entire INIT MUST be discarded, and NO changes
discarded, and NO changes should be made to the existing association. should be made to the existing association. An ABORT SHOULD be sent
An ABORT SHOULD be sent in response that MAY include the error in response that MAY include the error 'Restart of an association
'Restart of an association with new addresses'. The error SHOULD with new addresses'. The error SHOULD list the addresses that were
list the addresses that were added to the restarting association. added to the restarting association.
When responding in either state (COOKIE-WAIT or COOKIE-ECHOED) with When responding in either state (COOKIE-WAIT or COOKIE-ECHOED) with
an INIT ACK, the original parameters are combined with those from the an INIT ACK, the original parameters are combined with those from the
newly received INIT chunk. The endpoint shall also generate a State newly received INIT chunk. The endpoint shall also generate a State
Cookie with the INIT ACK. The endpoint uses the parameters sent in Cookie with the INIT ACK. The endpoint uses the parameters sent in
its INIT to calculate the State Cookie. its INIT to calculate the State Cookie.
After that, the endpoint MUST NOT change its state, the T1-init timer After that, the endpoint MUST NOT change its state, the T1-init timer
shall be left running and the corresponding TCB MUST NOT be shall be left running, and the corresponding TCB MUST NOT be
destroyed. The normal procedures for handling State Cookies when a destroyed. The normal procedures for handling State Cookies when a
TCB exists will resolve the duplicate INITs to a single association. TCB exists will resolve the duplicate INITs to a single association.
For an endpoint that is in the COOKIE-ECHOED state it MUST populate For an endpoint that is in the COOKIE-ECHOED state, it MUST populate
its Tie-Tags within both the association TCB and inside the State its Tie-Tags within both the association TCB and inside the State
Cookie (see Section 5.2.2 for a description of the Tie-Tags). Cookie (see Section 5.2.2 for a description of the Tie-Tags).
5.2.2. Unexpected INIT in States Other than CLOSED, COOKIE- 5.2.2. Unexpected INIT in States Other than CLOSED, COOKIE-ECHOED,
ECHOED,COOKIE-WAIT and SHUTDOWN-ACK-SENT COOKIE-WAIT, and SHUTDOWN-ACK-SENT
Unless otherwise stated, upon receipt of an unexpected INIT for this Unless otherwise stated, upon receipt of an unexpected INIT for this
association, the endpoint shall generate an INIT ACK with a State association, the endpoint shall generate an INIT ACK with a State
Cookie. Before responding, the endpoint MUST check to see if the Cookie. Before responding, the endpoint MUST check to see if the
unexpected INIT adds new addresses to the association. If new unexpected INIT adds new addresses to the association. If new
addresses are added to the association, the endpoint MUST respond addresses are added to the association, the endpoint MUST respond
with an ABORT, copying the 'Initiation Tag' of the unexpected INIT with an ABORT, copying the 'Initiate Tag' of the unexpected INIT into
into the 'Verification Tag' of the outbound packet carrying the the 'Verification Tag' of the outbound packet carrying the ABORT. In
ABORT. In the ABORT response, the cause of error MAY be set to the ABORT response, the cause of error MAY be set to 'restart of an
'restart of an association with new addresses'. The error SHOULD association with new addresses'. The error SHOULD list the addresses
list the addresses that were added to the restarting association. If that were added to the restarting association. If no new addresses
no new addresses are added, when responding to the INIT in the are added, when responding to the INIT in the outbound INIT ACK, the
outbound INIT ACK, the endpoint MUST copy its current Tie-Tags to a endpoint MUST copy its current Tie-Tags to a reserved place within
reserved place within the State Cookie and the association's TCB. We the State Cookie and the association's TCB. We shall refer to these
shall refer to these locations inside the cookie as the Peer's-Tie- locations inside the cookie as the Peer's-Tie-Tag and the Local-Tie-
Tag and the Local-Tie-Tag. We will refer to the copy within an Tag. We will refer to the copy within an association's TCB as the
association's TCB as the Local Tag and Peer's Tag. The outbound SCTP Local Tag and Peer's Tag. The outbound SCTP packet containing this
packet containing this INIT ACK MUST carry a Verification Tag value INIT ACK MUST carry a Verification Tag value equal to the Initiate
equal to the Initiation Tag found in the unexpected INIT. And the Tag found in the unexpected INIT. And the INIT ACK MUST contain a
INIT ACK MUST contain a new Initiation Tag (randomly generated; see new Initiate Tag (randomly generated; see Section 5.3.1). Other
Section 5.3.1). Other parameters for the endpoint SHOULD be copied parameters for the endpoint SHOULD be copied from the existing
from the existing parameters of the association (e.g., number of parameters of the association (e.g., number of outbound streams) into
outbound streams) into the INIT ACK and cookie. the INIT ACK and cookie.
After sending out the INIT ACK or ABORT, the endpoint shall take no After sending out the INIT ACK or ABORT, the endpoint shall take no
further actions; i.e., the existing association, including its further actions; i.e., the existing association, including its
current state, and the corresponding TCB MUST NOT be changed. current state, and the corresponding TCB MUST NOT be changed.
Note: Only when a TCB exists and the association is not in a COOKIE- Note: Only when a TCB exists and the association is not in a COOKIE-
WAIT or SHUTDOWN-ACK-SENT state are the Tie-Tags populated with a WAIT or SHUTDOWN-ACK-SENT state are the Tie-Tags populated with a
value other than 0. For a normal association INIT (i.e., the value other than 0. For a normal association INIT (i.e., the
endpoint is in the CLOSED state), the Tie-Tags MUST be set to 0 endpoint is in the CLOSED state), the Tie-Tags MUST be set to 0
(indicating that no previous TCB existed). (indicating that no previous TCB existed).
5.2.3. Unexpected INIT ACK 5.2.3. Unexpected INIT ACK
If an INIT ACK is received by an endpoint in any state other than the If an INIT ACK is received by an endpoint in any state other than the
COOKIE-WAIT state, the endpoint should discard the INIT ACK chunk. COOKIE-WAIT state, the endpoint should discard the INIT ACK chunk.
An unexpected INIT ACK usually indicates the processing of an old or An unexpected INIT ACK usually indicates the processing of an old or
duplicated INIT chunk. duplicated INIT chunk.
5.2.4. Handle a COOKIE ECHO when a TCB exists 5.2.4. Handle a COOKIE ECHO when a TCB Exists
When a COOKIE ECHO chunk is received by an endpoint in any state for When a COOKIE ECHO chunk is received by an endpoint in any state for
an existing association (i.e., not in the CLOSED state) the following an existing association (i.e., not in the CLOSED state) the following
rules shall be applied: rules shall be applied:
1) Compute a MAC as described in Step 1 of Section 5.1.5, 1) Compute a MAC as described in step 1 of Section 5.1.5,
2) Authenticate the State Cookie as described in Step 2 of 2) Authenticate the State Cookie as described in step 2 of Section
Section 5.1.5 (this is case C or D above). 5.1.5 (this is case C or D above).
3) Compare the timestamp in the State Cookie to the current time. 3) Compare the timestamp in the State Cookie to the current time.
If the State Cookie is older than the lifespan carried in the If the State Cookie is older than the lifespan carried in the
State Cookie and the Verification Tags contained in the State State Cookie and the Verification Tags contained in the State
Cookie do not match the current association's Verification Tags, Cookie do not match the current association's Verification Tags,
the packet, including the COOKIE ECHO and any DATA chunks, should the packet, including the COOKIE ECHO and any DATA chunks, should
be discarded. The endpoint also MUST transmit an ERROR chunk be discarded. The endpoint also MUST transmit an ERROR chunk
with a "Stale Cookie" error cause to the peer endpoint (this is with a "Stale Cookie" error cause to the peer endpoint (this is
case C or D in Section 5.2). case C or D in Section 5.2).
If both Verification Tags in the State Cookie match the If both Verification Tags in the State Cookie match the
Verification Tags of the current association, consider the State Verification Tags of the current association, consider the State
Cookie valid (this is case E of section 5.2) even if the lifespan Cookie valid (this is case E in Section 5.2) even if the lifespan
is exceeded. is exceeded.
4) If the State Cookie proves to be valid, unpack the TCB into a 4) If the State Cookie proves to be valid, unpack the TCB into a
temporary TCB. temporary TCB.
5) Refer to Table 2 to determine the correct action to be taken. 5) Refer to Table 2 to determine the correct action to be taken.
+------------+------------+---------------+--------------+-------------+ +------------+------------+---------------+--------------+-------------+
| Local Tag | Peer's Tag | Local-Tie-Tag |Peer's-Tie-Tag| Action/ | | Local Tag | Peer's Tag | Local-Tie-Tag |Peer's-Tie-Tag| Action/ |
| | | | | Description | | | | | | Description |
+------------+------------+---------------+--------------+-------------+ +------------+------------+---------------+--------------+-------------+
| X | X | M | M | (A) | | X | X | M | M | (A) |
+------------+------------+---------------+--------------+-------------+ +------------+------------+---------------+--------------+-------------+
| M | X | A | A | (B) | | M | X | A | A | (B) |
+------------+------------+---------------+--------------+-------------+ +------------+------------+---------------+--------------+-------------+
skipping to change at page 68, line 23 skipping to change at page 68, line 33
| X | X | M | M | (A) | | X | X | M | M | (A) |
+------------+------------+---------------+--------------+-------------+ +------------+------------+---------------+--------------+-------------+
| M | X | A | A | (B) | | M | X | A | A | (B) |
+------------+------------+---------------+--------------+-------------+ +------------+------------+---------------+--------------+-------------+
| M | 0 | A | A | (B) | | M | 0 | A | A | (B) |
+------------+------------+---------------+--------------+-------------+ +------------+------------+---------------+--------------+-------------+
| X | M | 0 | 0 | (C) | | X | M | 0 | 0 | (C) |
+------------+------------+---------------+--------------+-------------+ +------------+------------+---------------+--------------+-------------+
| M | M | A | A | (D) | | M | M | A | A | (D) |
+======================================================================+ +======================================================================+
| Table 2: Handling of a COOKIE ECHO when a TCB exists | | Table 2: Handling of a COOKIE ECHO when a TCB Exists |
+======================================================================+ +======================================================================+
Legend: Legend:
X - Tag does not match the existing TCB X - Tag does not match the existing TCB.
M - Tag matches the existing TCB. M - Tag matches the existing TCB.
0 - No Tie-Tag in Cookie (unknown). 0 - No Tie-Tag in cookie (unknown).
A - All cases, i.e. M, X or 0. A - All cases, i.e., M, X, or 0.
Note: For any case not shown in Table 2, the cookie should be Note: For any case not shown in Table 2, the cookie should be
silently discarded. silently discarded.
Action Action
A) In this case, the peer may have restarted. When the endpoint A) In this case, the peer may have restarted. When the endpoint
recognizes this potential 'restart', the existing session is recognizes this potential 'restart', the existing session is
treated the same as if it received an ABORT followed by a new treated the same as if it received an ABORT followed by a new
COOKIE ECHO with the following exceptions: COOKIE ECHO with the following exceptions:
- Any SCTP DATA Chunks MAY be retained (this is an implementation - Any SCTP DATA chunks MAY be retained (this is an
specific option). implementation-specific option).
- A notification of RESTART SHOULD be sent to the ULP instead of - A notification of RESTART SHOULD be sent to the ULP instead of
a "COMMUNICATION LOST" notification. a "COMMUNICATION LOST" notification.
All the congestion control parameters (e.g., cwnd, ssthresh) All the congestion control parameters (e.g., cwnd, ssthresh)
related to this peer MUST be reset to their initial values (see related to this peer MUST be reset to their initial values (see
Section 6.2.1). Section 6.2.1).
After this the endpoint shall enter the ESTABLISHED state. After this, the endpoint shall enter the ESTABLISHED state.
If the endpoint is in the SHUTDOWN-ACK-SENT state and recognizes If the endpoint is in the SHUTDOWN-ACK-SENT state and recognizes
the peer has restarted (Action A), it MUST NOT setup a new that the peer has restarted (Action A), it MUST NOT set up a new
association but instead resend the SHUTDOWN ACK and send an ERROR association but instead resend the SHUTDOWN ACK and send an ERROR
chunk with a "Cookie Received while Shutting Down" error cause to chunk with a "Cookie Received While Shutting Down" error cause to
its peer. its peer.
B) In this case, both sides may be attempting to start an association B) In this case, both sides may be attempting to start an association
at about the same time but the peer endpoint started its INIT at about the same time, but the peer endpoint started its INIT
after responding to the local endpoint's INIT. Thus it may have after responding to the local endpoint's INIT. Thus, it may have
picked a new Verification Tag not being aware of the previous Tag picked a new Verification Tag, not being aware of the previous tag
it had sent this endpoint. The endpoint should stay in or enter it had sent this endpoint. The endpoint should stay in or enter
the ESTABLISHED state but it MUST update its peer's Verification the ESTABLISHED state, but it MUST update its peer's Verification
Tag from the State Cookie, stop any init or cookie timers that may Tag from the State Cookie, stop any init or cookie timers that may
running and send a COOKIE ACK. be running, and send a COOKIE ACK.
C) In this case, the local endpoint's cookie has arrived late. C) In this case, the local endpoint's cookie has arrived late.
Before it arrived, the local endpoint sent an INIT and received an Before it arrived, the local endpoint sent an INIT and received an
INIT-ACK and finally sent a COOKIE ECHO with the peer's same tag INIT ACK and finally sent a COOKIE ECHO with the peer's same tag
but a new tag of its own. The cookie should be silently but a new tag of its own. The cookie should be silently
discarded. The endpoint SHOULD NOT change states and should leave discarded. The endpoint SHOULD NOT change states and should leave
any timers running. any timers running.
D) When both local and remote tags match, the endpoint should enter D) When both local and remote tags match, the endpoint should enter
the ESTABLISHED state, if it is in the COOKIE-ECHOED state. It the ESTABLISHED state, if it is in the COOKIE-ECHOED state. It
should stop any cookie timer that may be running and send a COOKIE should stop any cookie timer that may be running and send a COOKIE
ACK. ACK.
Note: The "peer's Verification Tag" is the tag received in the Note: The "peer's Verification Tag" is the tag received in the
Initiate Tag field of the INIT or INIT ACK chunk. Initiate Tag field of the INIT or INIT ACK chunk.
5.2.4.1. An Example of a Association Restart 5.2.4.1. An Example of a Association Restart
In the following example, "A" initiates the association after a In the following example, "A" initiates the association after a
restart has occurred. Endpoint "Z" had no knowledge of the restart restart has occurred. Endpoint "Z" had no knowledge of the restart
until the exchange (i.e. Heartbeats had not yet detected the failure until the exchange (i.e., Heartbeats had not yet detected the failure
of "A"). (assuming no bundling or fragmentation occurs): of "A") (assuming no bundling or fragmentation occurs):
Endpoint A Endpoint Z Endpoint A Endpoint Z
<-------------- Association is established----------------------> <-------------- Association is established---------------------->
Tag=Tag_A Tag=Tag_Z Tag=Tag_A Tag=Tag_Z
<---------------------------------------------------------------> <--------------------------------------------------------------->
{A crashes and restarts} {A crashes and restarts}
{app sets up a association with Z} {app sets up a association with Z}
(build TCB) (build TCB)
INIT [I-Tag=Tag_A' INIT [I-Tag=Tag_A'
& other info] --------\ & other info] --------\
(Start T1-init timer) \ (Start T1-init timer) \
(Enter COOKIE-WAIT state) \---> (find a existing TCB (Enter COOKIE-WAIT state) \---> (find an existing TCB
compose temp TCB and Cookie_Z compose temp TCB and Cookie_Z
with Tie-Tags to previous with Tie-Tags to previous
association) association)
/--- INIT ACK [Veri Tag=Tag_A', /--- INIT ACK [Veri Tag=Tag_A',
/ I-Tag=Tag_Z', / I-Tag=Tag_Z',
(Cancel T1-init timer) <------/ Cookie_Z[TieTags= (Cancel T1-init timer) <------/ Cookie_Z[TieTags=
Tag_A,Tag_Z Tag_A,Tag_Z
& other info] & other info]
(destroy temp TCB,leave original (destroy temp TCB,leave original
in place) in place)
COOKIE ECHO [Veri=Tag_Z', COOKIE ECHO [Veri=Tag_Z',
Cookie_Z Cookie_Z
Tie=Tag_A, Tie=Tag_A,
Tag_Z]----------\ Tag_Z]----------\
(Start T1-init timer) \ (Start T1-init timer) \
(Enter COOKIE-ECHOED state) \---> (Find existing association, (Enter COOKIE-ECHOED state) \---> (Find existing association,
Tie-Tags match old tags, Tie-Tags match old tags,
Tags do not match i.e., Tags do not match, i.e.,
case X X M M above, case X X M M above,
Announce Restart to ULP Announce Restart to ULP
and reset association). and reset association).
/---- COOKIE-ACK /---- COOKIE ACK
(Cancel T1-init timer, <------/ (Cancel T1-init timer, <------/
Enter ESTABLISHED state) Enter ESTABLISHED state)
{app sends 1st user data; strm 0} {app sends 1st user data; strm 0}
DATA [TSN=initial TSN_A DATA [TSN=initial TSN_A
Strm=0,Seq=0 & user data]--\ Strm=0,Seq=0 & user data]--\
(Start T3-rtx timer) \ (Start T3-rtx timer) \
\-> \->
/--- SACK [TSN Ack=init TSN_A,Block=0] /--- SACK [TSN Ack=init TSN_A,Block=0]
(Cancel T3-rtx timer) <------/ (Cancel T3-rtx timer) <------/
skipping to change at page 71, line 15 skipping to change at page 71, line 15
5.2.5. Handle Duplicate COOKIE-ACK. 5.2.5. Handle Duplicate COOKIE-ACK.
At any state other than COOKIE-ECHOED, an endpoint should silently At any state other than COOKIE-ECHOED, an endpoint should silently
discard a received COOKIE ACK chunk. discard a received COOKIE ACK chunk.
5.2.6. Handle Stale COOKIE Error 5.2.6. Handle Stale COOKIE Error
Receipt of an ERROR chunk with a "Stale Cookie" error cause indicates Receipt of an ERROR chunk with a "Stale Cookie" error cause indicates
one of a number of possible events: one of a number of possible events:
A) That the association failed to completely setup before the State A) The association failed to completely setup before the State Cookie
Cookie issued by the sender was processed. issued by the sender was processed.
B) An old State Cookie was processed after setup completed. B) An old State Cookie was processed after setup completed.
C) An old State Cookie is received from someone that the receiver is C) An old State Cookie is received from someone that the receiver is
not interested in having an association with and the ABORT chunk not interested in having an association with and the ABORT chunk
was lost. was lost.
When processing an ERROR chunk with a "Stale Cookie" error cause an When processing an ERROR chunk with a "Stale Cookie" error cause an
endpoint should first examine if an association is in the process of endpoint should first examine if an association is in the process of
being setup, i.e. the association is in the COOKIE-ECHOED state. In being set up, i.e., the association is in the COOKIE-ECHOED state.
all cases if the association is not in the COOKIE-ECHOED state, the In all cases, if the association is not in the COOKIE-ECHOED state,
ERROR chunk should be silently discarded. the ERROR chunk should be silently discarded.
If the association is in the COOKIE-ECHOED state, the endpoint may If the association is in the COOKIE-ECHOED state, the endpoint may
elect one of the following three alternatives. elect one of the following three alternatives.
1) Send a new INIT chunk to the endpoint to generate a new State 1) Send a new INIT chunk to the endpoint to generate a new State
Cookie and re-attempt the setup procedure. Cookie and reattempt the setup procedure.
2) Discard the TCB and report to the upper layer the inability to 2) Discard the TCB and report to the upper layer the inability to
setup the association. setup the association.
3) Send a new INIT chunk to the endpoint, adding a Cookie 3) Send a new INIT chunk to the endpoint, adding a Cookie
Preservative parameter requesting an extension to the lifetime of Preservative parameter requesting an extension to the life time
the State Cookie. When calculating the time extension, an of the State Cookie. When calculating the time extension, an
implementation SHOULD use the RTT information measured based on implementation SHOULD use the RTT information measured based on
the previous COOKIE ECHO / ERROR exchange, and should add no more the previous COOKIE ECHO / ERROR exchange, and should add no more
than 1 second beyond the measured RTT, due to long State Cookie than 1 second beyond the measured RTT, due to long State Cookie
lifetimes making the endpoint more subject to a replay attack. lifetimes making the endpoint more subject to a replay attack.
5.3. Other Initialization Issues 5.3. Other Initialization Issues
5.3.1. Selection of Tag Value 5.3.1. Selection of Tag Value
Initiate Tag values should be selected from the range of 1 to 2**32 - Initiate Tag values should be selected from the range of 1 to 2**32 -
skipping to change at page 72, line 14 skipping to change at page 72, line 21
help protect against "man in the middle" and "sequence number" help protect against "man in the middle" and "sequence number"
attacks. The methods described in [RFC4086] can be used for the attacks. The methods described in [RFC4086] can be used for the
Initiate Tag randomization. Careful selection of Initiate Tags is Initiate Tag randomization. Careful selection of Initiate Tags is
also necessary to prevent old duplicate packets from previous also necessary to prevent old duplicate packets from previous
associations being mistakenly processed as belonging to the current associations being mistakenly processed as belonging to the current
association. association.
Moreover, the Verification Tag value used by either endpoint in a Moreover, the Verification Tag value used by either endpoint in a
given association MUST NOT change during the lifetime of an given association MUST NOT change during the lifetime of an
association. A new Verification Tag value MUST be used each time the association. A new Verification Tag value MUST be used each time the
endpoint tears-down and then re-establishes an association to the endpoint tears down and then reestablishes an association to the same
same peer. peer.
5.4. Path Verification 5.4. Path Verification
During association establishment, the two peers exchange a list of During association establishment, the two peers exchange a list of
addresses. In the predominant case, these lists accurately represent addresses. In the predominant case, these lists accurately represent
the addresses owned by each peer. However, it is possible that a the addresses owned by each peer. However, it is possible that a
misbehaving peer may supply addresses that it does not own. To misbehaving peer may supply addresses that it does not own. To
prevent this, the following rules are applied to all addresses of the prevent this, the following rules are applied to all addresses of the
new association: new association:
1) Any address passed to the sender of the INIT by its upper layer 1) Any address passed to the sender of the INIT by its upper layer
is automatically considered to be CONFIRMED. is automatically considered to be CONFIRMED.
2) For the receiver of the COOKIE-ECHO the only CONFIRMED address is
the one that the INIT-ACK was sent to. 2) For the receiver of the COOKIE ECHO, the only CONFIRMED address
is the one to which the INIT-ACK was sent.
3) All other addresses not covered by rules 1 and 2 are considered 3) All other addresses not covered by rules 1 and 2 are considered
UNCONFIRMED and are subject to probing for verification. UNCONFIRMED and are subject to probing for verification.
To probe an address for verification, an endpoint will send To probe an address for verification, an endpoint will send
HEARTBEATs including a 64-bit random nonce and a path indicator (to HEARTBEATs including a 64-bit random nonce and a path indicator (to
identify the address that the HEARTBEAT is sent to) within the identify the address that the HEARTBEAT is sent to) within the
HEARTBEAT parameter. HEARTBEAT parameter.
Upon receipt of the HEARTBEAT-ACK, a verification is made that the Upon receipt of the HEARTBEAT ACK, a verification is made that the
nonce included in the HEARTBEAT parameter is the one sent to the nonce included in the HEARTBEAT parameter is the one sent to the
address indicated inside the HEARTBEAT parameter. When this match address indicated inside the HEARTBEAT parameter. When this match
occurs, the address that the original HEARTBEAT was sent to is now occurs, the address that the original HEARTBEAT was sent to is now
considered CONFIRMED and available for normal data transfer. considered CONFIRMED and available for normal data transfer.
These probing procedures are started when an association moves to the These probing procedures are started when an association moves to the
ESTABLISHED state and are ended when all paths are confirmed. ESTABLISHED state and are ended when all paths are confirmed.
Each RTO a probe may be sent on an active UNCONFIRMED path in an In each RTO, a probe may be sent on an active UNCONFIRMED path in an
attempt to move it to the CONFIRMED state. If during this probing attempt to move it to the CONFIRMED state. If during this probing
the path becomes inactive, this rate is lowered to the normal the path becomes inactive, this rate is lowered to the normal
HEARTBEAT rate. At the expiration of the RTO timer, the error HEARTBEAT rate. At the expiration of the RTO timer, the error
counter of any path that was probed but not CONFIRMED is incremented counter of any path that was probed but not CONFIRMED is incremented
by one and subjected to path failure detection, as defined in by one and subjected to path failure detection, as defined in Section
Section 8.2. When probing UNCONFIRMED addresses, however, the 8.2. When probing UNCONFIRMED addresses, however, the association
association overall error count is NOT incremented. overall error count is NOT incremented.
The number of HEARTBEATS sent at each RTO SHOULD be limited by the The number of HEARTBEATS sent at each RTO SHOULD be limited by the
HB.Max.Burst parameter. It is an implementation decision as to how HB.Max.Burst parameter. It is an implementation decision as to how
to distribute HEARTBEATS to the peer's addresses for path to distribute HEARTBEATS to the peer's addresses for path
verification. verification.
Whenever a path is confirmed, an indication MAY be given to the upper Whenever a path is confirmed, an indication MAY be given to the upper
layer. layer.
An endpoint MUST NOT send any chunks to an UNCONFIRMED address, with An endpoint MUST NOT send any chunks to an UNCONFIRMED address, with
skipping to change at page 73, line 17 skipping to change at page 73, line 27
The number of HEARTBEATS sent at each RTO SHOULD be limited by the The number of HEARTBEATS sent at each RTO SHOULD be limited by the
HB.Max.Burst parameter. It is an implementation decision as to how HB.Max.Burst parameter. It is an implementation decision as to how
to distribute HEARTBEATS to the peer's addresses for path to distribute HEARTBEATS to the peer's addresses for path
verification. verification.
Whenever a path is confirmed, an indication MAY be given to the upper Whenever a path is confirmed, an indication MAY be given to the upper
layer. layer.
An endpoint MUST NOT send any chunks to an UNCONFIRMED address, with An endpoint MUST NOT send any chunks to an UNCONFIRMED address, with
the following exceptions: the following exceptions:
- A HEARTBEAT including a nonce MAY be sent to an UNCONFIRMED - A HEARTBEAT including a nonce MAY be sent to an UNCONFIRMED
address. address.
- A HEARTBEAT-ACK MAY be sent to an UNCONFIRMED address.
- A COOKIE-ACK MAY be sent to an UNCONFIRMED address, but it MUST be - A HEARTBEAT ACK MAY be sent to an UNCONFIRMED address.
- A COOKIE ACK MAY be sent to an UNCONFIRMED address, but it MUST be
bundled with a HEARTBEAT including a nonce. An implementation bundled with a HEARTBEAT including a nonce. An implementation
that does NOT support bundling MUST NOT send a COOKIE-ACK to an that does NOT support bundling MUST NOT send a COOKIE ACK to an
UNCONFIRMED address. UNCONFIRMED address.
- A COOKE-ECHO MAY be sent to an UNCONFIRMED address, but it MUST be
bundled with a HEARTBEAT including a nonce, and the packet MUST - A COOKIE ECHO MAY be sent to an UNCONFIRMED address, but it MUST
be bundled with a HEARTBEAT including a nonce, and the packet MUST
NOT exceed the path MTU. If the implementation does NOT support NOT exceed the path MTU. If the implementation does NOT support
bundling or if the bundled COOKIE-ECHO plus HEARTBEAT (including bundling or if the bundled COOKIE ECHO plus HEARTBEAT (including
nonce) would exceed the path MTU, then the implementation MUST NOT nonce) would exceed the path MTU, then the implementation MUST NOT
send a COOKIE-ECHO to an UNCONFIRMED address. send a COOKIE ECHO to an UNCONFIRMED address.
6. User Data Transfer 6. User Data Transfer
Data transmission MUST only happen in the ESTABLISHED, SHUTDOWN- Data transmission MUST only happen in the ESTABLISHED, SHUTDOWN-
PENDING, and SHUTDOWN-RECEIVED states. The only exception to this is PENDING, and SHUTDOWN-RECEIVED states. The only exception to this is
that DATA chunks are allowed to be bundled with an outbound COOKIE that DATA chunks are allowed to be bundled with an outbound COOKIE
ECHO chunk when in COOKIE-WAIT state. ECHO chunk when in the COOKIE-WAIT state.
DATA chunks MUST only be received according to the rules below in DATA chunks MUST only be received according to the rules below in
ESTABLISHED, SHUTDOWN-PENDING, SHUTDOWN-SENT. A DATA chunk received ESTABLISHED, SHUTDOWN-PENDING, and SHUTDOWN-SENT. A DATA chunk
in CLOSED is out of the blue and SHOULD be handled per 8.4. A DATA received in CLOSED is out of the blue and SHOULD be handled per
chunk received in any other state SHOULD be discarded. Section 8.4. A DATA chunk received in any other state SHOULD be
discarded.
A SACK MUST be processed in ESTABLISHED, SHUTDOWN-PENDING, and A SACK MUST be processed in ESTABLISHED, SHUTDOWN-PENDING, and
SHUTDOWN-RECEIVED. An incoming SACK MAY be processed in COOKIE- SHUTDOWN-RECEIVED. An incoming SACK MAY be processed in COOKIE-
ECHOED. A SACK in the CLOSED state is out of the blue and SHOULD be ECHOED. A SACK in the CLOSED state is out of the blue and SHOULD be
processed according to the rules in 8.4. A SACK chunk received in processed according to the rules in Section 8.4. A SACK chunk
any other state SHOULD be discarded. received in any other state SHOULD be discarded.
A SCTP receiver MUST be able to receive a minimum of 1500 bytes in An SCTP receiver MUST be able to receive a minimum of 1500 bytes in
one SCTP packet. This means that a SCTP endpoint MUST NOT indicate one SCTP packet. This means that an SCTP endpoint MUST NOT indicate
less than 1500 bytes in its Initial a_rwnd sent in the INIT or INIT less than 1500 bytes in its initial a_rwnd sent in the INIT or INIT
ACK. ACK.
For transmission efficiency, SCTP defines mechanisms for bundling of For transmission efficiency, SCTP defines mechanisms for bundling of
small user messages and fragmentation of large user messages. The small user messages and fragmentation of large user messages. The
following diagram depicts the flow of user messages through SCTP. following diagram depicts the flow of user messages through SCTP.
In this section the term "data sender" refers to the endpoint that In this section, the term "data sender" refers to the endpoint that
transmits a DATA chunk and the term "data receiver" refers to the transmits a DATA chunk and the term "data receiver" refers to the
endpoint that receives a DATA chunk. A data receiver will transmit endpoint that receives a DATA chunk. A data receiver will transmit
SACK chunks. SACK chunks.
+--------------------------+ +--------------------------+
| User Messages | | User Messages |
+--------------------------+ +--------------------------+
SCTP user ^ | SCTP user ^ |
==================|==|======================================= ==================|==|=======================================
| v (1) | v (1)
skipping to change at page 75, line 20 skipping to change at page 76, line 10
This document is specified as if there is a single retransmission This document is specified as if there is a single retransmission
timer per destination transport address, but implementations MAY have timer per destination transport address, but implementations MAY have
a retransmission timer for each DATA chunk. a retransmission timer for each DATA chunk.
The following general rules MUST be applied by the data sender for The following general rules MUST be applied by the data sender for
transmission and/or retransmission of outbound DATA chunks: transmission and/or retransmission of outbound DATA chunks:
A) At any given time, the data sender MUST NOT transmit new data to A) At any given time, the data sender MUST NOT transmit new data to
any destination transport address if its peer's rwnd indicates any destination transport address if its peer's rwnd indicates
that the peer has no buffer space (i.e., rwnd is 0; see that the peer has no buffer space (i.e., rwnd is 0; see Section
Section 6.2.1). However, regardless of the value of rwnd 6.2.1). However, regardless of the value of rwnd (including if it
(including if it is 0), the data sender can always have one DATA is 0), the data sender can always have one DATA chunk in flight to
chunk in flight to the receiver if allowed by cwnd (see rule B, the receiver if allowed by cwnd (see rule B, below). This rule
below). This rule allows the sender to probe for a change in rwnd allows the sender to probe for a change in rwnd that the sender
that the sender missed due to the SACK's having been lost in missed due to the SACK's having been lost in transit from the data
transit from the data receiver to the data sender. receiver to the data sender.
When the receiver's advertised window is zero, this probe is When the receiver's advertised window is zero, this probe is
called a zero window probe. Note that a zero window probe SHOULD called a zero window probe. Note that a zero window probe SHOULD
only be sent when all outstanding DATA chunks have been only be sent when all outstanding DATA chunks have been
cumulatively acknowledged and no DATA chunks are in flight. Zero cumulatively acknowledged and no DATA chunks are in flight. Zero
window probing MUST be supported. window probing MUST be supported.
If the sender continues to receive new packets from the receiver If the sender continues to receive new packets from the receiver
while doing zero window probing, the unacknowledged window probes while doing zero window probing, the unacknowledged window probes
should not increment the error counter for the association or any should not increment the error counter for the association or any
destination transport address. This is because the receiver MAY destination transport address. This is because the receiver MAY
keep its window closed for an indefinite time. Refer to keep its window closed for an indefinite time. Refer to Section
Section 6.2 on the receiver behavior when it advertises a zero 6.2 on the receiver behavior when it advertises a zero window.
window. The sender SHOULD send the first zero window probe after The sender SHOULD send the first zero window probe after 1 RTO
1 RTO when it detects that the receiver has closed its window and when it detects that the receiver has closed its window and SHOULD
SHOULD increase the probe interval exponentially afterwards. Also increase the probe interval exponentially afterwards. Also note
note that the cwnd SHOULD be adjusted according to Section 7.2.1. that the cwnd SHOULD be adjusted according to Section 7.2.1. Zero
Zero window probing does not affect the calculation of cwnd. window probing does not affect the calculation of cwnd.
The sender MUST also have an algorithm for sending new DATA chunks The sender MUST also have an algorithm for sending new DATA chunks
to avoid silly window syndrome (SWS) as described in [RFC0813]. to avoid silly window syndrome (SWS) as described in [RFC0813].
The algorithm can be similar to the one described in Section The algorithm can be similar to the one described in Section
4.2.3.4 of [RFC1122]. 4.2.3.4 of [RFC1122].
that the peer has no buffer space (i.e. rwnd is 0, see ).
However, regardless of the value of rwnd (including if it is 0), However, regardless of the value of rwnd (including if it is 0),
the data sender can always have one DATA chunk in flight to the the data sender can always have one DATA chunk in flight to the
receiver if allowed by cwnd (see rule B below). This rule allows receiver if allowed by cwnd (see rule B below). This rule allows
the sender to probe for a change in rwnd that the sender missed the sender to probe for a change in rwnd that the sender missed
due to the SACK having been lost in transit from the data receiver due to the SACK having been lost in transit from the data receiver
to the data sender. to the data sender.
B) At any given time, the sender MUST NOT transmit new data to a B) At any given time, the sender MUST NOT transmit new data to a
given transport address if it has cwnd or more bytes of data given transport address if it has cwnd or more bytes of data
outstanding to that transport address. outstanding to that transport address.
C) When the time comes for the sender to transmit, before sending new C) When the time comes for the sender to transmit, before sending new
DATA chunks, the sender MUST first transmit any outstanding DATA DATA chunks, the sender MUST first transmit any outstanding DATA
chunks which are marked for retransmission (limited by the current chunks that are marked for retransmission (limited by the current
cwnd). cwnd).
D) When the time comes for the sender to transmit new DATA chunks, D) When the time comes for the sender to transmit new DATA chunks,
the protocol parameter Max.Burst SHOULD be used to limit the the protocol parameter Max.Burst SHOULD be used to limit the
number of packets sent. The limit MAY be applied by adjusting number of packets sent. The limit MAY be applied by adjusting
cwnd as follows: cwnd as follows:
if((flightsize + Max.Burst*MTU) < cwnd) cwnd = flightsize + if((flightsize + Max.Burst*MTU) < cwnd) cwnd = flightsize +
Max.Burst*MTU Max.Burst*MTU
Or it MAY be applied by strictly limiting the number of packets Or it MAY be applied by strictly limiting the number of packets
emitted by the output routine. emitted by the output routine.
E) Then, the sender can send out as many new DATA chunks as Rule A E) Then, the sender can send out as many new DATA chunks as rule A
and Rule B allow. and rule B allow.
Multiple DATA chunks committed for transmission MAY be bundled in a Multiple DATA chunks committed for transmission MAY be bundled in a
single packet. Furthermore, DATA chunks being retransmitted MAY be single packet. Furthermore, DATA chunks being retransmitted MAY be
bundled with new DATA chunks, as long as the resulting packet size bundled with new DATA chunks, as long as the resulting packet size
does not exceed the path MTU. A ULP may request that no bundling is does not exceed the path MTU. A ULP may request that no bundling is
performed but this should only turn off any delays that a SCTP performed, but this should only turn off any delays that an SCTP
implementation may be using to increase bundling efficiency. It does implementation may be using to increase bundling efficiency. It does
not in itself stop all bundling from occurring (i.e. in case of not in itself stop all bundling from occurring (i.e., in case of
congestion or retransmission). congestion or retransmission).
Before an endpoint transmits a DATA chunk, if any received DATA Before an endpoint transmits a DATA chunk, if any received DATA
chunks have not been acknowledged (e.g., due to delayed ack), the chunks have not been acknowledged (e.g., due to delayed ack), the
sender should create a SACK and bundle it with the outbound DATA sender should create a SACK and bundle it with the outbound DATA
chunk, as long as the size of the final SCTP packet does not exceed chunk, as long as the size of the final SCTP packet does not exceed
the current MTU. See Section 6.2. the current MTU. See Section 6.2.
IMPLEMENTATION NOTE: When the window is full (i.e., transmission is IMPLEMENTATION NOTE: When the window is full (i.e., transmission is
disallowed by Rule A and/or Rule B), the sender MAY still accept send disallowed by rule A and/or rule B), the sender MAY still accept send
requests from its upper layer, but MUST transmit no more DATA chunks requests from its upper layer, but MUST transmit no more DATA chunks
until some or all of the outstanding DATA chunks are acknowledged and until some or all of the outstanding DATA chunks are acknowledged and
transmission is allowed by Rule A and Rule B again. transmission is allowed by rule A and rule B again.
Whenever a transmission or retransmission is made to any address, if Whenever a transmission or retransmission is made to any address, if
the T3-rtx timer of that address is not currently running, the sender the T3-rtx timer of that address is not currently running, the sender
MUST start that timer. If the timer for that address is already MUST start that timer. If the timer for that address is already
running, the sender MUST restart the timer if the earliest (i.e., running, the sender MUST restart the timer if the earliest (i.e.,
lowest TSN) outstanding DATA chunk sent to that address is being lowest TSN) outstanding DATA chunk sent to that address is being
retransmitted. Otherwise, the data sender MUST NOT restart the retransmitted. Otherwise, the data sender MUST NOT restart the
timer. timer.
When starting or restarting the T3-rtx timer, the timer value must be When starting or restarting the T3-rtx timer, the timer value must be
adjusted according to the timer rules defined in Section 6.3.2, and adjusted according to the timer rules defined in Sections 6.3.2 and
Section 6.3.3. 6.3.3.
Note: The data sender SHOULD NOT use a TSN that is more than 2**31 - Note: The data sender SHOULD NOT use a TSN that is more than 2**31 -
1 above the beginning TSN of the current send window. 1 above the beginning TSN of the current send window.
6.2. Acknowledgement on Reception of DATA Chunks 6.2. Acknowledgement on Reception of DATA Chunks
The SCTP endpoint MUST always acknowledge the reception of each valid The SCTP endpoint MUST always acknowledge the reception of each valid
DATA chunk when the DATA chunk received is inside its receive window. DATA chunk when the DATA chunk received is inside its receive window.
When the receiver's advertised window is 0, the receiver MUST drop When the receiver's advertised window is 0, the receiver MUST drop
skipping to change at page 77, line 47 skipping to change at page 78, line 36
not accepted. The receiver MUST also have an algorithm for not accepted. The receiver MUST also have an algorithm for
advertising its receive window to avoid receiver silly window advertising its receive window to avoid receiver silly window
syndrome (SWS), as described in [RFC0813]. The algorithm can be syndrome (SWS), as described in [RFC0813]. The algorithm can be
similar to the one described in Section 4.2.3.3 of [RFC1122]. similar to the one described in Section 4.2.3.3 of [RFC1122].
The guidelines on delayed acknowledgement algorithm specified in The guidelines on delayed acknowledgement algorithm specified in
Section 4.2 of [RFC2581] SHOULD be followed. Specifically, an Section 4.2 of [RFC2581] SHOULD be followed. Specifically, an
acknowledgement SHOULD be generated for at least every second packet acknowledgement SHOULD be generated for at least every second packet
(not every second DATA chunk) received, and SHOULD be generated (not every second DATA chunk) received, and SHOULD be generated
within 200 ms of the arrival of any unacknowledged DATA chunk. In within 200 ms of the arrival of any unacknowledged DATA chunk. In
some situations it may be beneficial for an SCTP transmitter to be some situations, it may be beneficial for an SCTP transmitter to be
more conservative than the algorithms detailed in this document more conservative than the algorithms detailed in this document
allow. However, an SCTP transmitter MUST NOT be more aggressive than allow. However, an SCTP transmitter MUST NOT be more aggressive than
the following algorithms allow. the following algorithms allow.
A SCTP receiver MUST NOT generate more than one SACK for every An SCTP receiver MUST NOT generate more than one SACK for every
incoming packet, other than to update the offered window as the incoming packet, other than to update the offered window as the
receiving application consumes new data. receiving application consumes new data.
IMPLEMENTATION NOTE: The maximum delay for generating an IMPLEMENTATION NOTE: The maximum delay for generating an
acknowledgement may be configured by the SCTP administrator, either acknowledgement may be configured by the SCTP administrator, either
statically or dynamically, in order to meet the specific timing statically or dynamically, in order to meet the specific timing
requirement of the protocol being carried. requirement of the protocol being carried.
An implementation MUST NOT allow the maximum delay to be configured An implementation MUST NOT allow the maximum delay to be configured
to be more than 500 ms. In other words an implementation MAY lower to be more than 500 ms. In other words, an implementation MAY lower
this value below 500ms but MUST NOT raise it above 500ms. this value below 500ms but MUST NOT raise it above 500ms.
Acknowledgments MUST be sent in SACK chunks unless shutdown was Acknowledgements MUST be sent in SACK chunks unless shutdown was
requested by the ULP, in which case an endpoint MAY send an requested by the ULP, in which case an endpoint MAY send an
acknowledgement in the SHUTDOWN chunk. A SACK chunk can acknowledge acknowledgement in the SHUTDOWN chunk. A SACK chunk can acknowledge
the reception of multiple DATA chunks. See Section 3.3.4 for SACK the reception of multiple DATA chunks. See Section 3.3.4 for SACK
chunk format. In particular, the SCTP endpoint MUST fill in the chunk format. In particular, the SCTP endpoint MUST fill in the
Cumulative TSN Ack field to indicate the latest sequential TSN (of a Cumulative TSN Ack field to indicate the latest sequential TSN (of a
valid DATA chunk) it has received. Any received DATA chunks with TSN valid DATA chunk) it has received. Any received DATA chunks with TSN
greater than the value in the Cumulative TSN Ack field are reported greater than the value in the Cumulative TSN Ack field are reported
in the Gap Ack Block fields. The SCTP endpoint MUST report as many in the Gap Ack Block fields. The SCTP endpoint MUST report as many
Gap Ack Blocks as can fit in a single SACK chunk limited by the Gap Ack Blocks as can fit in a single SACK chunk limited by the
current path MTU. current path MTU.
Note: The SHUTDOWN chunk does not contain Gap Ack Block fields. Note: The SHUTDOWN chunk does not contain Gap Ack Block fields.
Therefore, the endpoint should use a SACK instead of the SHUTDOWN Therefore, the endpoint should use a SACK instead of the SHUTDOWN
chunk to acknowledge DATA chunks received out of order . chunk to acknowledge DATA chunks received out of order .
When a packet arrives with duplicate DATA chunk(s) and with no new When a packet arrives with duplicate DATA chunk(s) and with no new
DATA chunk(s), the endpoint MUST immediately send a SACK with no DATA chunk(s), the endpoint MUST immediately send a SACK with no
delay. If a packet arrives with duplicate DATA chunk(s) bundled with delay. If a packet arrives with duplicate DATA chunk(s) bundled with
new DATA chunks, the endpoint MAY immediately send a SACK. Normally new DATA chunks, the endpoint MAY immediately send a SACK. Normally,
receipt of duplicate DATA chunks will occur when the original SACK receipt of duplicate DATA chunks will occur when the original SACK
chunk was lost and the peer's RTO has expired. The duplicate TSN chunk was lost and the peer's RTO has expired. The duplicate TSN
number(s) SHOULD be reported in the SACK as duplicate. number(s) SHOULD be reported in the SACK as duplicate.
When an endpoint receives a SACK, it MAY use the Duplicate TSN When an endpoint receives a SACK, it MAY use the duplicate TSN
information to determine if SACK loss is occurring. Further use of information to determine if SACK loss is occurring. Further use of
this data is for future study. this data is for future study.
The data receiver is responsible for maintaining its receive buffers. The data receiver is responsible for maintaining its receive buffers.
The data receiver SHOULD notify the data sender in a timely manner of The data receiver SHOULD notify the data sender in a timely manner of
changes in its ability to receive data. How an implementation changes in its ability to receive data. How an implementation
manages its receive buffers is dependent on many factors (e.g., manages its receive buffers is dependent on many factors (e.g.,
Operating System, memory management system, amount of memory, etc.). operating system, memory management system, amount of memory, etc.).
However, the data sender strategy defined in Section 6.2.1 is based However, the data sender strategy defined in Section 6.2.1 is based
on the assumption of receiver operation similar to the following: on the assumption of receiver operation similar to the following:
A) At initialization of the association, the endpoint tells the peer A) At initialization of the association, the endpoint tells the peer
how much receive buffer space it has allocated to the association how much receive buffer space it has allocated to the association
in the INIT or INIT ACK. The endpoint sets a_rwnd to this value. in the INIT or INIT ACK. The endpoint sets a_rwnd to this value.
B) As DATA chunks are received and buffered, decrement a_rwnd by the B) As DATA chunks are received and buffered, decrement a_rwnd by the
number of bytes received and buffered. This is, in effect, number of bytes received and buffered. This is, in effect,
closing rwnd at the data sender and restricting the amount of data closing rwnd at the data sender and restricting the amount of data
skipping to change at page 79, line 42 skipping to change at page 80, line 33
been acked in Gap Ack Blocks. For example, the data receiver may be been acked in Gap Ack Blocks. For example, the data receiver may be
holding data in its receive buffers while reassembling a fragmented holding data in its receive buffers while reassembling a fragmented
user message from its peer when it runs out of receive buffer space. user message from its peer when it runs out of receive buffer space.
It may drop these DATA chunks even though it has acknowledged them in It may drop these DATA chunks even though it has acknowledged them in
Gap Ack Blocks. If a data receiver drops DATA chunks, it MUST NOT Gap Ack Blocks. If a data receiver drops DATA chunks, it MUST NOT
include them in Gap Ack Blocks in subsequent SACKs until they are include them in Gap Ack Blocks in subsequent SACKs until they are
received again via retransmission. In addition, the endpoint should received again via retransmission. In addition, the endpoint should
take into account the dropped data when calculating its a_rwnd. take into account the dropped data when calculating its a_rwnd.
An endpoint SHOULD NOT revoke a SACK and discard data. Only in An endpoint SHOULD NOT revoke a SACK and discard data. Only in
extreme circumstance should an endpoint use this procedure (such as extreme circumstances should an endpoint use this procedure (such as
out of buffer space). The data receiver should take into account out of buffer space). The data receiver should take into account
that dropping data that has been acked in Gap Ack Blocks can result that dropping data that has been acked in Gap Ack Blocks can result
in suboptimal retransmission strategies in the data sender and thus in suboptimal retransmission strategies in the data sender and thus
in suboptimal performance. in suboptimal performance.
The following example illustrates the use of delayed The following example illustrates the use of delayed
acknowledgements: acknowledgements:
Endpoint A Endpoint Z Endpoint A Endpoint Z
skipping to change at page 80, line 28 skipping to change at page 81, line 31
{App sends 1 message; strm 1} {App sends 1 message; strm 1}
(bundle SACK with DATA) (bundle SACK with DATA)
/----- SACK [TSN Ack=9,block=0] \ /----- SACK [TSN Ack=9,block=0] \
/ DATA [TSN=6,Strm=1,Seq=2] / DATA [TSN=6,Strm=1,Seq=2]
(cancel T3-rtx timer) <------/ (Start T3-rtx timer) (cancel T3-rtx timer) <------/ (Start T3-rtx timer)
(ack delayed) (ack delayed)
(send ack) (send ack)
SACK [TSN Ack=6,block=0] -------------> (cancel T3-rtx timer) SACK [TSN Ack=6,block=0] -------------> (cancel T3-rtx timer)
Figure 7: Delayed Acknowledgment Example Figure 7: Delayed Acknowledgement Example
If an endpoint receives a DATA chunk with no user data (i.e., the If an endpoint receives a DATA chunk with no user data (i.e., the
Length field is set to 16) it MUST send an ABORT with error cause set Length field is set to 16), it MUST send an ABORT with error cause
to "No User Data". set to "No User Data".
An endpoint SHOULD NOT send a DATA chunk with no user data part. An endpoint SHOULD NOT send a DATA chunk with no user data part.
6.2.1. Processing a Received SACK 6.2.1. Processing a Received SACK
Each SACK an endpoint receives contains an a_rwnd value. This value Each SACK an endpoint receives contains an a_rwnd value. This value
represents the amount of buffer space the data receiver, at the time represents the amount of buffer space the data receiver, at the time
of transmitting the SACK, has left of its total receive buffer space of transmitting the SACK, has left of its total receive buffer space
(as specified in the INIT/INIT ACK). Using a_rwnd, Cumulative TSN (as specified in the INIT/INIT ACK). Using a_rwnd, Cumulative TSN
Ack and Gap Ack Blocks, the data sender can develop a representation Ack, and Gap Ack Blocks, the data sender can develop a representation
of the peer's receive buffer space. of the peer's receive buffer space.
One of the problems the data sender must take into account when One of the problems the data sender must take into account when
processing a SACK is that a SACK can be received out of order. That processing a SACK is that a SACK can be received out of order. That
is, a SACK sent by the data receiver can pass an earlier SACK and be is, a SACK sent by the data receiver can pass an earlier SACK and be
received first by the data sender. If a SACK is received out of received first by the data sender. If a SACK is received out of
order, the data sender can develop an incorrect view of the peer's order, the data sender can develop an incorrect view of the peer's
receive buffer space. receive buffer space.
Since there is no explicit identifier that can be used to detect out- Since there is no explicit identifier that can be used to detect
of-order SACKs, the data sender must use heuristics to determine if a out-of-order SACKs, the data sender must use heuristics to determine
SACK is new. if a SACK is new.
An endpoint SHOULD use the following rules to calculate the rwnd, An endpoint SHOULD use the following rules to calculate the rwnd,
using the a_rwnd value, the Cumulative TSN Ack and Gap Ack Blocks in using the a_rwnd value, the Cumulative TSN Ack, and Gap Ack Blocks in
a received SACK. a received SACK.
A) At the establishment of the association, the endpoint initializes A) At the establishment of the association, the endpoint initializes
the rwnd to the Advertised Receiver Window Credit (a_rwnd) the the rwnd to the Advertised Receiver Window Credit (a_rwnd) the
peer specified in the INIT or INIT ACK. peer specified in the INIT or INIT ACK.
B) Any time a DATA chunk is transmitted (or retransmitted) to a peer, B) Any time a DATA chunk is transmitted (or retransmitted) to a peer,
the endpoint subtracts the data size of the chunk from the rwnd of the endpoint subtracts the data size of the chunk from the rwnd of
that peer. that peer.
C) Any time a DATA chunk is marked for retransmission (via either T3- C) Any time a DATA chunk is marked for retransmission, either via
rtx timer expiration (Section 6.3.3) or via fast retransmit T3-rtx timer expiration (Section 6.3.3) or via Fast Retransmit
(Section 7.2.4), add the data size of those chunks to the rwnd. (Section 7.2.4), add the data size of those chunks to the rwnd.
Note: If the implementation is maintaining a timer on each DATA Note: If the implementation is maintaining a timer on each DATA
chunk then only DATA chunks whose timer expired would be marked chunk, then only DATA chunks whose timer expired would be marked
for retransmission. for retransmission.
D) Any time a SACK arrives, the endpoint performs the following: D) Any time a SACK arrives, the endpoint performs the following:
i) If Cumulative TSN Ack is less than the Cumulative TSN Ack i) If Cumulative TSN Ack is less than the Cumulative TSN Ack
Point, then drop the SACK. Since Cumulative TSN Ack is Point, then drop the SACK. Since Cumulative TSN Ack is
monotonically increasing, a SACK whose Cumulative TSN Ack is monotonically increasing, a SACK whose Cumulative TSN Ack is
less than the Cumulative TSN Ack Point indicates an out-of- less than the Cumulative TSN Ack Point indicates an out-of-
order SACK. order SACK.
ii) Set rwnd equal to the newly received a_rwnd minus the number ii) Set rwnd equal to the newly received a_rwnd minus the number
of bytes still outstanding after processing the Cumulative TSN of bytes still outstanding after processing the Cumulative
Ack and the Gap Ack Blocks. TSN Ack and the Gap Ack Blocks.
iii) If the SACK is missing a TSN that was previously iii) If the SACK is missing a TSN that was previously acknowledged
acknowledged via a Gap Ack Block (e.g., the data receiver via a Gap Ack Block (e.g., the data receiver reneged on the
reneged on the data), then consider the corresponding DATA that data), then consider the corresponding DATA that might be
might be possibly missing: Count one miss indication towards possibly missing: Count one miss indication towards Fast
fast retransmit as described in Section 7.2.4 , and if no Retransmit as described in Section 7.2.4, and if no
retransmit timer is running for the destination address to retransmit timer is running for the destination address to
which the DATA chunk was originally transmitted, then T3-rtx is which the DATA chunk was originally transmitted, then T3-rtx
started for that destination address. is started for that destination address.
iv) If the Cumulative TSN Ack matches or exceeds the Fast iv) If the Cumulative TSN Ack matches or exceeds the Fast
Recovery exitpoint (Section 7.2.4), Fast Recovery is exited. Recovery exitpoint (Section 7.2.4), Fast Recovery is exited.
6.3. Management of Retransmission Timer 6.3. Management of Retransmission Timer
An SCTP endpoint uses a retransmission timer T3-rtx to ensure data An SCTP endpoint uses a retransmission timer T3-rtx to ensure data
delivery in the absence of any feedback from its peer. The duration delivery in the absence of any feedback from its peer. The duration
of this timer is referred to as RTO (retransmission timeout). of this timer is referred to as RTO (retransmission timeout).
When an endpoint's peer is multi-homed, the endpoint will calculate a When an endpoint's peer is multi-homed, the endpoint will calculate a
separate RTO for each different destination transport address of its separate RTO for each different destination transport address of its
peer endpoint. peer endpoint.
The computation and management of RTO in SCTP follows closely how TCP The computation and management of RTO in SCTP follow closely how TCP
manages its retransmission timer. To compute the current RTO, an manages its retransmission timer. To compute the current RTO, an
endpoint maintains two state variables per destination transport endpoint maintains two state variables per destination transport
address: SRTT (smoothed round-trip time) and RTTVAR (round-trip time address: SRTT (smoothed round-trip time) and RTTVAR (round-trip time
variation). variation).
6.3.1. RTO Calculation 6.3.1. RTO Calculation
The rules governing the computation of SRTT, RTTVAR, and RTO are as The rules governing the computation of SRTT, RTTVAR, and RTO are as
follows: follows:
skipping to change at page 83, line 7 skipping to change at page 84, line 7
SRTT <- (1 - RTO.Alpha) * SRTT + RTO.Alpha * R' SRTT <- (1 - RTO.Alpha) * SRTT + RTO.Alpha * R'
Note: The value of SRTT used in the update to RTTVAR is its Note: The value of SRTT used in the update to RTTVAR is its
value before updating SRTT itself using the second assignment. value before updating SRTT itself using the second assignment.
After the computation, update RTO <- SRTT + 4 * RTTVAR. After the computation, update RTO <- SRTT + 4 * RTTVAR.
C4) When data is in flight and when allowed by rule C5 below, a new C4) When data is in flight and when allowed by rule C5 below, a new
RTT measurement MUST be made each round trip. Furthermore, new RTT measurement MUST be made each round trip. Furthermore, new
RTT measurements SHOULD be made no more than once per round-trip RTT measurements SHOULD be made no more than once per round trip
for a given destination transport address. There are two for a given destination transport address. There are two
reasons for this recommendation: First, it appears that reasons for this recommendation: First, it appears that
measuring more frequently often does not in practice yield any measuring more frequently often does not in practice yield any
significant benefit [ALLMAN99]; second, if measurements are made significant benefit [ALLMAN99]; second, if measurements are made
more often, then the values of RTO.Alpha and RTO.Beta in rule C3 more often, then the values of RTO.Alpha and RTO.Beta in rule C3
above should be adjusted so that SRTT and RTTVAR still adjust to above should be adjusted so that SRTT and RTTVAR still adjust to
changes at roughly the same rate (in terms of how many round changes at roughly the same rate (in terms of how many round
trips it takes them to reflect new values) as they would if trips it takes them to reflect new values) as they would if
making only one measurement per round-trip and using RTO.Alpha making only one measurement per round-trip and using RTO.Alpha
and RTO.Beta as given in rule C3. However, the exact nature of and RTO.Beta as given in rule C3. However, the exact nature of
these adjustments remains a research issue. these adjustments remains a research issue.
C5) Karn's algorithm: RTT measurements MUST NOT be made using C5) Karn's algorithm: RTT measurements MUST NOT be made using
packets that were retransmitted (and thus for which it is packets that were retransmitted (and thus for which it is
ambiguous whether the reply was for the first instance of the ambiguous whether the reply was for the first instance of the
the chunk or for a later instance) chunk or for a later instance)
IMPLEMENTATION NOTE: RTT measurements should only be made using IMPLEMENTATION NOTE: RTT measurements should only be made using
a chunk with TSN r if no chunk with TSN less than or equal to r a chunk with TSN r if no chunk with TSN less than or equal to r
is retransmitted since r is first sent. is retransmitted since r is first sent.
C6) Whenever RTO is computed, if it is less than RTO.Min seconds C6) Whenever RTO is computed, if it is less than RTO.Min seconds
then it is rounded up to RTO.Min seconds. The reason for this then it is rounded up to RTO.Min seconds. The reason for this
rule is that RTOs that do not have a high minimum value are rule is that RTOs that do not have a high minimum value are
susceptible to unnecessary timeouts [ALLMAN99]. susceptible to unnecessary timeouts [ALLMAN99].
skipping to change at page 84, line 16 skipping to change at page 85, line 20
retransmission), if the T3-rtx timer of that address is not retransmission), if the T3-rtx timer of that address is not
running, start it running so that it will expire after the RTO running, start it running so that it will expire after the RTO
of that address. The RTO used here is that obtained after any of that address. The RTO used here is that obtained after any
doubling due to previous T3-rtx timer expirations on the doubling due to previous T3-rtx timer expirations on the
corresponding destination address as discussed in rule E2 below. corresponding destination address as discussed in rule E2 below.
R2) Whenever all outstanding data sent to an address have been R2) Whenever all outstanding data sent to an address have been
acknowledged, turn off the T3-rtx timer of that address. acknowledged, turn off the T3-rtx timer of that address.
R3) Whenever a SACK is received that acknowledges the DATA chunk R3) Whenever a SACK is received that acknowledges the DATA chunk
with the earliest outstanding TSN for that address, restart T3- with the earliest outstanding TSN for that address, restart the
rtx timer for that address with its current RTO (if there is T3-rtx timer for that address with its current RTO (if there is
still outstanding data on that address). still outstanding data on that address).
R4) Whenever a SACK is received missing a TSN that was previously R4) Whenever a SACK is received missing a TSN that was previously
acknowledged via a Gap Ack Block, start T3-rtx for the acknowledged via a Gap Ack Block, start the T3-rtx for the
destination address to which the DATA chunk was originally destination address to which the DATA chunk was originally
transmitted if it is not already running. transmitted if it is not already running.
The following example shows the use of various timer rules (assuming The following example shows the use of various timer rules (assuming
the receiver uses delayed acks). that the receiver uses delayed acks).
Endpoint A Endpoint Z Endpoint A Endpoint Z
{App begins to send} {App begins to send}
Data [TSN=7,Strm=0,Seq=3] ------------> (ack delayed) Data [TSN=7,Strm=0,Seq=3] ------------> (ack delayed)
(Start T3-rtx timer) (Start T3-rtx timer)
{App sends 1 message; strm 1} {App sends 1 message; strm 1}
(bundle ack with data) (bundle ack with data)
DATA [TSN=8,Strm=0,Seq=4] ----\ /-- SACK [TSN Ack=7,Block=0] DATA [TSN=8,Strm=0,Seq=4] ----\ /-- SACK [TSN Ack=7,Block=0]
\ / DATA [TSN=6,Strm=1,Seq=2] \ / DATA [TSN=6,Strm=1,Seq=2]
\ / (Start T3-rtx timer) \ / (Start T3-rtx timer)
\ \
/ \ / \
(Re-start T3-rtx timer) <------/ \--> (ack delayed) (Restart T3-rtx timer) <------/ \--> (ack delayed)
(ack delayed) (ack delayed)
{send ack} {send ack}
SACK [TSN Ack=6,Block=0] --------------> (Cancel T3-rtx timer) SACK [TSN Ack=6,Block=0] --------------> (Cancel T3-rtx timer)
.. ..
(send ack) (send ack)
(Cancel T3-rtx timer) <-------------- SACK [TSN Ack=8,Block=0] (Cancel T3-rtx timer) <-------------- SACK [TSN Ack=8,Block=0]
Figure 8 - Timer Rule Examples Figure 8: Timer Rule Examples
6.3.3. Handle T3-rtx Expiration 6.3.3. Handle T3-rtx Expiration
Whenever the retransmission timer T3-rtx expires for a destination Whenever the retransmission timer T3-rtx expires for a destination
address, do the following: address, do the following:
E1) For the destination address for which the timer expires, adjust E1) For the destination address for which the timer expires, adjust
its ssthresh with rules defined in Section 7.2.3 and set the its ssthresh with rules defined in Section 7.2.3 and set the
cwnd <- MTU. cwnd <- MTU.
skipping to change at page 85, line 25 skipping to change at page 86, line 25
<- RTO * 2 ("back off the timer"). The maximum value discussed <- RTO * 2 ("back off the timer"). The maximum value discussed
in rule C7 above (RTO.max) may be used to provide an upper bound in rule C7 above (RTO.max) may be used to provide an upper bound
to this doubling operation. to this doubling operation.
E3) Determine how many of the earliest (i.e., lowest TSN) E3) Determine how many of the earliest (i.e., lowest TSN)
outstanding DATA chunks for the address for which the T3-rtx has outstanding DATA chunks for the address for which the T3-rtx has
expired will fit into a single packet, subject to the MTU expired will fit into a single packet, subject to the MTU
constraint for the path corresponding to the destination constraint for the path corresponding to the destination
transport address to which the retransmission is being sent transport address to which the retransmission is being sent
(this may be different from the address for which the timer (this may be different from the address for which the timer
expires [see Section 6.4]). Call this value K. Bundle and expires; see Section 6.4). Call this value K. Bundle and
retransmit those K DATA chunks in a single packet to the retransmit those K DATA chunks in a single packet to the
destination endpoint. destination endpoint.
E4) Start the retransmission timer T3-rtx on the destination address E4) Start the retransmission timer T3-rtx on the destination address
to which the retransmission is sent, if rule R1 above indicates to which the retransmission is sent, if rule R1 above indicates
to do so. The RTO to be used for starting T3-rtx should be the to do so. The RTO to be used for starting T3-rtx should be the
one for the destination address to which the retransmission is one for the destination address to which the retransmission is
sent, which, when the receiver is multi-homed, may be different sent, which, when the receiver is multi-homed, may be different
from the destination address for which the timer expired (see from the destination address for which the timer expired (see
Section 6.4 below). Section 6.4 below).
After retransmitting, once a new RTT measurement is obtained (which After retransmitting, once a new RTT measurement is obtained (which
can happen only when new data has been sent and acknowledged, per can happen only when new data has been sent and acknowledged, per
rule C5, or for a measurement made from a HEARTBEAT [see Section 8.3 rule C5, or for a measurement made from a HEARTBEAT; see Section
), the computation in rule C3 is performed, including the computation 8.3), the computation in rule C3 is performed, including the
of RTO, which may result in "collapsing" RTO back down after it has computation of RTO, which may result in "collapsing" RTO back down
been subject to doubling (rule E2). after it has been subject to doubling (rule E2).
Note: Any DATA chunks that were sent to the address for which the T3- Note: Any DATA chunks that were sent to the address for which the
rtx timer expired but did not fit in one MTU (rule E3 above), should T3-rtx timer expired but did not fit in one MTU (rule E3 above)
be marked for retransmission and sent as soon as cwnd allows should be marked for retransmission and sent as soon as cwnd allows
(normally when a SACK arrives). (normally, when a SACK arrives).
The final rule for managing the retransmission timer concerns The final rule for managing the retransmission timer concerns
failover (see Section 6.4.1): failover (see Section 6.4.1):
F1) Whenever an endpoint switches from the current destination F1) Whenever an endpoint switches from the current destination
transport address to a different one, the current retransmission transport address to a different one, the current retransmission
timers are left running. As soon as the endpoint transmits a timers are left running. As soon as the endpoint transmits a
packet containing DATA chunk(s) to the new transport address, packet containing DATA chunk(s) to the new transport address,
start the timer on that transport address, using the RTO value start the timer on that transport address, using the RTO value
of the destination address to which the data is being sent, if of the destination address to which the data is being sent, if
rule R1 indicates to do so. rule R1 indicates to do so.
6.4. Multi-homed SCTP Endpoints 6.4. Multi-Homed SCTP Endpoints
An SCTP endpoint is considered multi-homed if there are more than one An SCTP endpoint is considered multi-homed if there are more than one
transport address that can be used as a destination address to reach transport address that can be used as a destination address to reach
that endpoint. that endpoint.
Moreover, the ULP of an endpoint shall select one of the multiple Moreover, the ULP of an endpoint shall select one of the multiple
destination addresses of a multi-homed peer endpoint as the primary destination addresses of a multi-homed peer endpoint as the primary
path (see Section 5.1.2 and Section 10.1 for details). path (see Section 5.1.2 and Section 10.1 for details).
By default, an endpoint SHOULD always transmit to the primary path, By default, an endpoint SHOULD always transmit to the primary path,
skipping to change at page 86, line 39 skipping to change at page 87, line 39
received the DATA or control chunk to which it is replying. This received the DATA or control chunk to which it is replying. This
rule should also be followed if the endpoint is bundling DATA chunks rule should also be followed if the endpoint is bundling DATA chunks
together with the reply chunk. together with the reply chunk.
However, when acknowledging multiple DATA chunks received in packets However, when acknowledging multiple DATA chunks received in packets
from different source addresses in a single SACK, the SACK chunk may from different source addresses in a single SACK, the SACK chunk may
be transmitted to one of the destination transport addresses from be transmitted to one of the destination transport addresses from
which the DATA or control chunks being acknowledged were received. which the DATA or control chunks being acknowledged were received.
When a receiver of a duplicate DATA chunk sends a SACK to a multi- When a receiver of a duplicate DATA chunk sends a SACK to a multi-
homed endpoint it MAY be beneficial to vary the destination address homed endpoint, it MAY be beneficial to vary the destination address
and not use the source address of the DATA chunk. The reason being and not use the source address of the DATA chunk. The reason is that
that receiving a duplicate from a multi-homed endpoint might indicate receiving a duplicate from a multi-homed endpoint might indicate that
that the return path (as specified in the source address of the DATA the return path (as specified in the source address of the DATA
chunk) for the SACK is broken. chunk) for the SACK is broken.
Furthermore, when its peer is multi-homed, an endpoint SHOULD try to Furthermore, when its peer is multi-homed, an endpoint SHOULD try to
retransmit a chunk that timed out to an active destination transport retransmit a chunk that timed out to an active destination transport
address that is different from the last destination address to which address that is different from the last destination address to which
the DATA chunk was sent. the DATA chunk was sent.
Retransmissions do not affect the total outstanding data count. Retransmissions do not affect the total outstanding data count.
However, if the DATA chunk is retransmitted onto a different However, if the DATA chunk is retransmitted onto a different
destination address, both the outstanding data counts on the new destination address, both the outstanding data counts on the new
destination address and the old destination address to which the data destination address and the old destination address to which the data
chunk was last sent shall be adjusted accordingly. chunk was last sent shall be adjusted accordingly.
6.4.1. Failover from Inactive Destination Address 6.4.1. Failover from an Inactive Destination Address
Some of the transport addresses of a multi-homed SCTP endpoint may Some of the transport addresses of a multi-homed SCTP endpoint may
become inactive due to either the occurrence of certain error become inactive due to either the occurrence of certain error
conditions (see Section 8.2) or adjustments from SCTP user. conditions (see Section 8.2) or adjustments from the SCTP user.
When there is outbound data to send and the primary path becomes When there is outbound data to send and the primary path becomes
inactive (e.g., due to failures), or where the SCTP user explicitly inactive (e.g., due to failures), or where the SCTP user explicitly
requests to send data to an inactive destination transport address, requests to send data to an inactive destination transport address,
before reporting an error to its ULP, the SCTP endpoint should try to before reporting an error to its ULP, the SCTP endpoint should try to
send the data to an alternate active destination transport address if send the data to an alternate active destination transport address if
one exists. one exists.
When retransmitting data that timed out, if the endpoint is multi- When retransmitting data that timed out, if the endpoint is multi-
homed, it should consider each source-destination address pair in its homed, it should consider each source-destination address pair in its
retransmission selection policy. When retransmitting timed out data, retransmission selection policy. When retransmitting timed-out data,
the endpoint should attempt to pick the most divergent source- the endpoint should attempt to pick the most divergent source-
destination pair from the original source-destination pair to which destination pair from the original source-destination pair to which
the packet was transmitted. the packet was transmitted.
Note: Rules for picking the most divergent source-destination pair Note: Rules for picking the most divergent source-destination pair
are an implementation decision and is not specified within this are an implementation decision and are not specified within this
document. document.
6.5. Stream Identifier and Stream Sequence Number 6.5. Stream Identifier and Stream Sequence Number
Every DATA chunk MUST carry a valid stream identifier. If an Every DATA chunk MUST carry a valid stream identifier. If an
endpoint receives a DATA chunk with an invalid stream identifier, it endpoint receives a DATA chunk with an invalid stream identifier, it
shall acknowledge the reception of the DATA chunk following the shall acknowledge the reception of the DATA chunk following the
normal procedure, immediately send an ERROR chunk with cause set to normal procedure, immediately send an ERROR chunk with cause set to
"Invalid Stream Identifier" (see Section 3.3.10) and discard the DATA "Invalid Stream Identifier" (see Section 3.3.10), and discard the
chunk. The endpoint may bundle the ERROR chunk in the same packet as DATA chunk. The endpoint may bundle the ERROR chunk in the same
the SACK as long as the ERROR follows the SACK. packet as the SACK as long as the ERROR follows the SACK.
The stream sequence number in all the streams MUST start from 0 when The Stream Sequence Number in all the streams MUST start from 0 when
the association is established. Also, when the stream sequence the association is established. Also, when the Stream Sequence
number reaches the value 65535 the next stream sequence number MUST Number reaches the value 65535 the next Stream Sequence Number MUST
be set to 0. be set to 0.
6.6. Ordered and Unordered Delivery 6.6. Ordered and Unordered Delivery
Within a stream, an endpoint MUST deliver DATA chunks received with Within a stream, an endpoint MUST deliver DATA chunks received with
the U flag set to 0 to the upper layer according to the order of the U flag set to 0 to the upper layer according to the order of
their stream sequence number. If DATA chunks arrive out of order of their Stream Sequence Number. If DATA chunks arrive out of order of
their stream sequence number, the endpoint MUST hold the received their Stream Sequence Number, the endpoint MUST hold the received
DATA chunks from delivery to the ULP until they are re-ordered. DATA chunks from delivery to the ULP until they are reordered.
However, an SCTP endpoint can indicate that no ordered delivery is However, an SCTP endpoint can indicate that no ordered delivery is
required for a particular DATA chunk transmitted within the stream by required for a particular DATA chunk transmitted within the stream by
setting the U flag of the DATA chunk to 1. setting the U flag of the DATA chunk to 1.
When an endpoint receives a DATA chunk with the U flag set to 1, it When an endpoint receives a DATA chunk with the U flag set to 1, it
must bypass the ordering mechanism and immediately deliver the data must bypass the ordering mechanism and immediately deliver the data
to the upper layer (after re-assembly if the user data is fragmented to the upper layer (after reassembly if the user data is fragmented
by the data sender). by the data sender).
This provides an effective way of transmitting "out-of-band" data in This provides an effective way of transmitting "out-of-band" data in
a given stream. Also, a stream can be used as an "unordered" stream a given stream. Also, a stream can be used as an "unordered" stream
by simply setting the U flag to 1 in all DATA chunks sent through by simply setting the U flag to 1 in all DATA chunks sent through
that stream. that stream.
IMPLEMENTATION NOTE: When sending an unordered DATA chunk, an IMPLEMENTATION NOTE: When sending an unordered DATA chunk, an
implementation may choose to place the DATA chunk in an outbound implementation may choose to place the DATA chunk in an outbound
packet that is at the head of the outbound transmission queue if packet that is at the head of the outbound transmission queue if
skipping to change at page 89, line 4 skipping to change at page 90, line 6
calculate the missing DATA chunks and make decisions on whether to calculate the missing DATA chunks and make decisions on whether to
retransmit them (see Section 6.2.1 for details). retransmit them (see Section 6.2.1 for details).
Multiple gaps can be reported in one single SACK (see Section 3.3.4). Multiple gaps can be reported in one single SACK (see Section 3.3.4).
When its peer is multi-homed, the SCTP endpoint SHOULD always try to When its peer is multi-homed, the SCTP endpoint SHOULD always try to
send the SACK to the same destination address from which the last send the SACK to the same destination address from which the last
DATA chunk was received. DATA chunk was received.
Upon the reception of a SACK, the endpoint MUST remove all DATA Upon the reception of a SACK, the endpoint MUST remove all DATA
chunks which have been acknowledged by the SACK's Cumulative TSN Ack chunks that have been acknowledged by the SACK's Cumulative TSN Ack
from its transmit queue. The endpoint MUST also treat all the DATA from its transmit queue. The endpoint MUST also treat all the DATA
chunks with TSNs not included in the Gap Ack Blocks reported by the chunks with TSNs not included in the Gap Ack Blocks reported by the
SACK as "missing". The number of "missing" reports for each SACK as "missing". The number of "missing" reports for each
outstanding DATA chunk MUST be recorded by the data sender in order outstanding DATA chunk MUST be recorded by the data sender in order
to make retransmission decisions. See Section 7.2.4 for details. to make retransmission decisions. See Section 7.2.4 for details.
The following example shows the use of SACK to report a gap. The following example shows the use of SACK to report a gap.
Endpoint A Endpoint Z Endpoint A Endpoint Z {App
{App sends 3 messages; strm 0} sends 3 messages; strm 0} DATA [TSN=6,Strm=0,Seq=2] ----------
DATA [TSN=6,Strm=0,Seq=2] ---------------> (ack delayed) -----> (ack delayed) (Start T3-rtx timer)
(Start T3-rtx timer)
DATA [TSN=7,Strm=0,Seq=3] --------> X (lost) DATA [TSN=7,Strm=0,Seq=3] --------> X (lost)
DATA [TSN=8,Strm=0,Seq=4] ---------------> (gap detected, DATA [TSN=8,Strm=0,Seq=4] ---------------> (gap detected,
immediately send ack) immediately send ack)
/----- SACK [TSN Ack=6,Block=1, /----- SACK [TSN Ack=6,Block=1,
/ Start=2,End=2] / Start=2,End=2]
<-----/ <-----/ (remove 6 from out-queue,
(remove 6 from out-queue,
and mark 7 as "1" missing report) and mark 7 as "1" missing report)
Figure 9 - Reporting a Gap using SACK Figure 9: Reporting a Gap using SACK
The maximum number of Gap Ack Blocks that can be reported within a The maximum number of Gap Ack Blocks that can be reported within a
single SACK chunk is limited by the current path MTU. When a single single SACK chunk is limited by the current path MTU. When a single
SACK can not cover all the Gap Ack Blocks needed to be reported due SACK cannot cover all the Gap Ack Blocks needed to be reported due to
to the MTU limitation, the endpoint MUST send only one SACK, the MTU limitation, the endpoint MUST send only one SACK, reporting
reporting the Gap Ack Blocks from the lowest to highest TSNs, within the Gap Ack Blocks from the lowest to highest TSNs, within the size
the size limit set by the MTU, and leave the remaining highest TSN limit set by the MTU, and leave the remaining highest TSN numbers
numbers unacknowledged. unacknowledged.
6.8. CRC32c Checksum Calculation 6.8. CRC32c Checksum Calculation
When sending an SCTP packet, the endpoint MUST strengthen the data When sending an SCTP packet, the endpoint MUST strengthen the data
integrity of the transmission by including the CRC32c checksum value integrity of the transmission by including the CRC32c checksum value
calculated on the packet, as described below. calculated on the packet, as described below.
After the packet is constructed (containing the SCTP common header After the packet is constructed (containing the SCTP common header
and one or more control or DATA chunks), the transmitter MUST and one or more control or DATA chunks), the transmitter MUST
1) fill in the proper Verification Tag in the SCTP common header and 1) fill in the proper Verification Tag in the SCTP common header and
initialize the checksum field to '0's, initialize the checksum field to '0's,
2) calculate the CRC32c checksum of the whole packet, including the 2) calculate the CRC32c checksum of the whole packet, including the
SCTP common header and all the chunks (refer to appendix B for SCTP common header and all the chunks (refer to Appendix B for
details of the CRC32c algorithm); and details of the CRC32c algorithm); and
3) put the resultant value into the checksum field in the common 3) put the resultant value into the checksum field in the common
header, and leave the rest of the bits unchanged. header, and leave the rest of the bits unchanged.
When an SCTP packet is received, the receiver MUST first check the When an SCTP packet is received, the receiver MUST first check the
CRC32c checksum as follows: CRC32c checksum as follows:
1) Store the received CRC32c checksum value aside. 1) Store the received CRC32c checksum value aside.
2) Replace the 32 bits of the checksum field in the received SCTP 2) Replace the 32 bits of the checksum field in the received SCTP
packet with all '0's and calculate a CRC32c checksum value of the packet with all '0's and calculate a CRC32c checksum value of the
skipping to change at page 90, line 45 skipping to change at page 91, line 38
An endpoint MAY support fragmentation when sending DATA chunks, but An endpoint MAY support fragmentation when sending DATA chunks, but
it MUST support reassembly when receiving DATA chunks. If an it MUST support reassembly when receiving DATA chunks. If an
endpoint supports fragmentation, it MUST fragment a user message if endpoint supports fragmentation, it MUST fragment a user message if
the size of the user message to be sent causes the outbound SCTP the size of the user message to be sent causes the outbound SCTP
packet size to exceed the current MTU. If an implementation does not packet size to exceed the current MTU. If an implementation does not
support fragmentation of outbound user messages, the endpoint MUST support fragmentation of outbound user messages, the endpoint MUST
return an error to its upper layer and not attempt to send the user return an error to its upper layer and not attempt to send the user
message. message.
Note: If an implementation that supports fragmentation makes Note: If an implementation that supports fragmentation makes
available to its upper layer a mechanism to turn off fragmentation it available to its upper layer a mechanism to turn off fragmentation,
may do so. However, in so doing, it MUST react just like an it may do so. However, in so doing, it MUST react just like an
implementation that does NOT support fragmentation, i.e., it MUST implementation that does NOT support fragmentation, i.e., it MUST
reject sends that exceed the current P-MTU. reject sends that exceed the current Path MTU (P-MTU).
IMPLEMENTATION NOTE: In this error case, the Send primitive discussed IMPLEMENTATION NOTE: In this error case, the Send primitive discussed
in Section 10.1 would need to return an error to the upper layer. in Section 10.1 would need to return an error to the upper layer.
If its peer is multi-homed, the endpoint shall choose a size no If its peer is multi-homed, the endpoint shall choose a size no
larger than the association Path MTU. The association Path MTU is larger than the association Path MTU. The association Path MTU is
the smallest Path MTU of all destination addresses. the smallest Path MTU of all destination addresses.
Note: Once a message is fragmented it cannot be re-fragmented. Note: Once a message is fragmented, it cannot be re-fragmented.
Instead if the PMTU has been reduced, then IP fragmentation must be Instead, if the PMTU has been reduced, then IP fragmentation must be
used. Please see Section 7.3 for details of PMTU discovery. used. Please see Section 7.3 for details of PMTU discovery.
When determining when to fragment, the SCTP implementation MUST take When determining when to fragment, the SCTP implementation MUST take
into account the SCTP packet header as well as the DATA chunk into account the SCTP packet header as well as the DATA chunk
header(s). The implementation MUST also take into account the space header(s). The implementation MUST also take into account the space
required for a SACK chunk if bundling a SACK chunk with the DATA required for a SACK chunk if bundling a SACK chunk with the DATA
chunk. chunk.
Fragmentation takes the following steps: Fragmentation takes the following steps:
skipping to change at page 91, line 39 skipping to change at page 92, line 35
delivery, then the U flag of each DATA chunk of the user message delivery, then the U flag of each DATA chunk of the user message
MUST be set to 1. MUST be set to 1.
3) The transmitter MUST also set the B/E bits of the first DATA 3) The transmitter MUST also set the B/E bits of the first DATA
chunk in the series to '10', the B/E bits of the last DATA chunk chunk in the series to '10', the B/E bits of the last DATA chunk
in the series to '01', and the B/E bits of all other DATA chunks in the series to '01', and the B/E bits of all other DATA chunks
in the series to '00'. in the series to '00'.
An endpoint MUST recognize fragmented DATA chunks by examining the An endpoint MUST recognize fragmented DATA chunks by examining the
B/E bits in each of the received DATA chunks, and queue the B/E bits in each of the received DATA chunks, and queue the
fragmented DATA chunks for re-assembly. Once the user message is fragmented DATA chunks for reassembly. Once the user message is
reassembled, SCTP shall pass the re-assembled user message to the reassembled, SCTP shall pass the reassembled user message to the
specific stream for possible re-ordering and final dispatching. specific stream for possible reordering and final dispatching.
Note: If the data receiver runs out of buffer space while still Note: If the data receiver runs out of buffer space while still
waiting for more fragments to complete the re-assembly of the waiting for more fragments to complete the reassembly of the message,
message, it should dispatch part of its inbound message through a it should dispatch part of its inbound message through a partial
partial delivery API (see Section 10), freeing some of its receive delivery API (see Section 10), freeing some of its receive buffer
buffer space so that the rest of the message may be received. space so that the rest of the message may be received.
6.10. Bundling 6.10. Bundling
An endpoint bundles chunks by simply including multiple chunks in one An endpoint bundles chunks by simply including multiple chunks in one
outbound SCTP packet. The total size of the resultant IP datagram, outbound SCTP packet. The total size of the resultant IP datagram,
including the SCTP packet and IP headers, MUST be less or equal to
the current Path MTU. including the SCTP packet and IP headers, MUST be less that or equal
to the current Path MTU.
If its peer endpoint is multi-homed, the sending endpoint shall If its peer endpoint is multi-homed, the sending endpoint shall
choose a size no larger than the latest MTU of the current primary choose a size no larger than the latest MTU of the current primary
path. path.
When bundling control chunks with DATA chunks, an endpoint MUST place When bundling control chunks with DATA chunks, an endpoint MUST place
control chunks first in the outbound SCTP packet. The transmitter control chunks first in the outbound SCTP packet. The transmitter
MUST transmit DATA chunks within a SCTP packet in increasing order of MUST transmit DATA chunks within an SCTP packet in increasing order
TSN. of TSN.
Note: Since control chunks must be placed first in a packet and since Note: Since control chunks must be placed first in a packet and since
DATA chunks must be transmitted before SHUTDOWN or SHUTDOWN ACK DATA chunks must be transmitted before SHUTDOWN or SHUTDOWN ACK
chunks, DATA chunks cannot be bundled with SHUTDOWN or SHUTDOWN ACK chunks, DATA chunks cannot be bundled with SHUTDOWN or SHUTDOWN ACK
chunks. chunks.
Partial chunks MUST NOT be placed in an SCTP packet. A partial chunk Partial chunks MUST NOT be placed in an SCTP packet. A partial chunk
is a chunk that is not completely contained in the SCTP packet; i.e., is a chunk that is not completely contained in the SCTP packet; i.e.,
the SCTP packet is too short to contain all the bytes of the chunk as the SCTP packet is too short to contain all the bytes of the chunk as
indicated by the chunk length. indicated by the chunk length.
An endpoint MUST process received chunks in their order in the An endpoint MUST process received chunks in their order in the
packet. The receiver uses the chunk length field to determine the packet. The receiver uses the Chunk Length field to determine the
end of a chunk and beginning of the next chunk taking account of the end of a chunk and beginning of the next chunk taking account of the
fact that all chunks end on a 4 byte boundary. If the receiver fact that all chunks end on a 4-byte boundary. If the receiver
detects a partial chunk, it MUST drop the chunk. detects a partial chunk, it MUST drop the chunk.
An endpoint MUST NOT bundle INIT, INIT ACK or SHUTDOWN COMPLETE with An endpoint MUST NOT bundle INIT, INIT ACK, or SHUTDOWN COMPLETE with
any other chunks. any other chunks.
7. Congestion control 7. Congestion Control
Congestion control is one of the basic functions in SCTP. For some Congestion control is one of the basic functions in SCTP. For some
applications, it may be likely that adequate resources will be applications, it may be likely that adequate resources will be
allocated to SCTP traffic to assure prompt delivery of time-critical allocated to SCTP traffic to ensure prompt delivery of time-critical
data - thus it would appear to be unlikely, during normal operations, data -- thus, it would appear to be unlikely, during normal
that transmissions encounter severe congestion conditions. However operations, that transmissions encounter severe congestion
SCTP must operate under adverse operational conditions, which can conditions. However, SCTP must operate under adverse operational
develop upon partial network failures or unexpected traffic surges. conditions, which can develop upon partial network failures or
In such situations SCTP must follow correct congestion control steps unexpected traffic surges. In such situations, SCTP must follow
to recover from congestion quickly in order to get data delivered as correct congestion control steps to recover from congestion quickly
soon as possible. In the absence of network congestion, these in order to get data delivered as soon as possible. In the absence
preventive congestion control algorithms should show no impact on the of network congestion, these preventive congestion control algorithms
protocol performance. should show no impact on the protocol performance.
IMPLEMENTATION NOTE: As far as its specific performance requirements IMPLEMENTATION NOTE: As far as its specific performance requirements
are met, an implementation is always allowed to adopt a more are met, an implementation is always allowed to adopt a more
conservative congestion control algorithm than the one defined below. conservative congestion control algorithm than the one defined below.
The congestion control algorithms used by SCTP are based on The congestion control algorithms used by SCTP are based on
[RFC2581]. This section describes how the algorithms defined in [RFC2581]. This section describes how the algorithms defined in
[RFC2581] are adapted for use in SCTP. We first list differences in [RFC2581] are adapted for use in SCTP. We first list differences in
protocol designs between TCP and SCTP, and then describe SCTP's protocol designs between TCP and SCTP, and then describe SCTP's
congestion control scheme. The description will use the same congestion control scheme. The description will use the same
terminology as in TCP congestion control whenever appropriate. terminology as in TCP congestion control whenever appropriate.
SCTP congestion control is always applied to the entire association, SCTP congestion control is always applied to the entire association,
and not to individual streams. and not to individual streams.
7.1. SCTP Differences from TCP Congestion control 7.1. SCTP Differences from TCP Congestion Control
Gap Ack Blocks in the SCTP SACK carry the same semantic meaning as Gap Ack Blocks in the SCTP SACK carry the same semantic meaning as
the TCP SACK. TCP considers the information carried in the SACK as the TCP SACK. TCP considers the information carried in the SACK as
advisory information only. SCTP considers the information carried in advisory information only. SCTP considers the information carried in
the Gap Ack Blocks in the SACK chunk as advisory. In SCTP, any DATA the Gap Ack Blocks in the SACK chunk as advisory. In SCTP, any DATA
chunk that has been acknowledged by SACK, including DATA that arrived chunk that has been acknowledged by SACK, including DATA that arrived
at the receiving end out of order, are not considered fully delivered at the receiving end out of order, is not considered fully delivered
until the Cumulative TSN Ack Point passes the TSN of the DATA chunk until the Cumulative TSN Ack Point passes the TSN of the DATA chunk
(i.e., the DATA chunk has been acknowledged by the Cumulative TSN Ack (i.e., the DATA chunk has been acknowledged by the Cumulative TSN Ack
field in the SACK). Consequently, the value of cwnd controls the field in the SACK). Consequently, the value of cwnd controls the
amount of outstanding data, rather than (as in the case of non-SACK amount of outstanding data, rather than (as in the case of non-SACK
TCP) the upper bound between the highest acknowledged sequence number TCP) the upper bound between the highest acknowledged sequence number
and the latest DATA chunk that can be sent within the congestion and the latest DATA chunk that can be sent within the congestion
window. SCTP SACK leads to different implementations of fast- window. SCTP SACK leads to different implementations of Fast
retransmit and fast-recovery than non-SACK TCP. As an example see Retransmit and Fast Recovery than non-SACK TCP. As an example, see
[FALL96]. [FALL96].
The biggest difference between SCTP and TCP, however, is multi- The biggest difference between SCTP and TCP, however, is multi-
homing. SCTP is designed to establish robust communication homing. SCTP is designed to establish robust communication
associations between two endpoints each of which may be reachable by associations between two endpoints each of which may be reachable by
more than one transport address. Potentially different addresses may more than one transport address. Potentially different addresses may
lead to different data paths between the two endpoints, thus ideally lead to different data paths between the two endpoints; thus, ideally
one may need a separate set of congestion control parameters for each one may need a separate set of congestion control parameters for each
of the paths. The treatment here of congestion control for multi- of the paths. The treatment here of congestion control for multi-
homed receivers is new with SCTP and may require refinement in the homed receivers is new with SCTP and may require refinement in the
future. The current algorithms make the following assumptions: future. The current algorithms make the following assumptions:
o The sender usually uses the same destination address until being o The sender usually uses the same destination address until being
instructed by the upper layer to do otherwise; however, SCTP may instructed by the upper layer to do otherwise; however, SCTP may
change to an alternate destination in the event an address is change to an alternate destination in the event an address is
marked inactive (see Section 8.2). Also, SCTP may retransmit to a marked inactive (see Section 8.2). Also, SCTP may retransmit to a
different transport address than the original transmission. different transport address than the original transmission.
o The sender keeps a separate congestion control parameter set for o The sender keeps a separate congestion control parameter set for
each of the destination addresses it can send to (not each source- each of the destination addresses it can send to (not each
destination pair but for each destination). The parameters should source-destination pair but for each destination). The parameters
decay if the address is not used for a long enough time period. should decay if the address is not used for a long enough time
period.
o For each of the destination addresses, an endpoint does slow-start o For each of the destination addresses, an endpoint does slow start
upon the first transmission to that address. upon the first transmission to that address.
Note: TCP guarantees in-sequence delivery of data to its upper-layer Note: TCP guarantees in-sequence delivery of data to its upper-layer
protocol within a single TCP session. This means that when TCP protocol within a single TCP session. This means that when TCP
notices a gap in the received sequence number, it waits until the gap notices a gap in the received sequence number, it waits until the gap
is filled before delivering the data that was received with sequence is filled before delivering the data that was received with sequence
numbers higher than that of the missing data. On the other hand, numbers higher than that of the missing data. On the other hand,
SCTP can deliver data to its upper-layer protocol even if there is a SCTP can deliver data to its upper-layer protocol even if there is a
gap in TSN if the Stream Sequence Numbers are in sequence for a gap in TSN if the Stream Sequence Numbers are in sequence for a
particular stream (i.e., the missing DATA chunks are for a different particular stream (i.e., the missing DATA chunks are for a different
stream) or if unordered delivery is indicated. Although this does stream) or if unordered delivery is indicated. Although this does
not affect cwnd, it might affect rwnd calculation. not affect cwnd, it might affect rwnd calculation.
7.2. SCTP Slow-Start and Congestion Avoidance 7.2. SCTP Slow-Start and Congestion Avoidance
The slow start and congestion avoidance algorithms MUST be used by an The slow-start and congestion avoidance algorithms MUST be used by an
endpoint to control the amount of data being injected into the endpoint to control the amount of data being injected into the
network. The congestion control in SCTP is employed in regard to the network. The congestion control in SCTP is employed in regard to the
association, not to an individual stream. In some situations it may association, not to an individual stream. In some situations, it may
be beneficial for an SCTP sender to be more conservative than the be beneficial for an SCTP sender to be more conservative than the
algorithms allow; however, an SCTP sender MUST NOT be more aggressive algorithms allow; however, an SCTP sender MUST NOT be more aggressive
than the following algorithms allow. than the following algorithms allow.
Like TCP, an SCTP endpoint uses the following three control variables Like TCP, an SCTP endpoint uses the following three control variables
to regulate its transmission rate. to regulate its transmission rate.
o Receiver advertised window size (rwnd, in bytes), which is set by o Receiver advertised window size (rwnd, in bytes), which is set by
the receiver based on its available buffer space for incoming the receiver based on its available buffer space for incoming
packets. packets.
Note: This variable is kept on the entire association. Note: This variable is kept on the entire association.
o Congestion control window (cwnd, in bytes), which is adjusted by o Congestion control window (cwnd, in bytes), which is adjusted by
the sender based on observed network conditions. the sender based on observed network conditions.
Note: This variable is maintained on a per-destination address Note: This variable is maintained on a per-destination-address
basis. basis.
o Slow-start threshold (ssthresh, in bytes), which is used by the o Slow-start threshold (ssthresh, in bytes), which is used by the
sender to distinguish slow start and congestion avoidance phases. sender to distinguish slow-start and congestion avoidance phases.
Note: This variable is maintained on a per-destination address Note: This variable is maintained on a per-destination-address
basis. basis.
SCTP also requires one additional control variable, SCTP also requires one additional control variable,
partial_bytes_acked, which is used during congestion avoidance phase partial_bytes_acked, which is used during congestion avoidance phase
to facilitate cwnd adjustment. to facilitate cwnd adjustment.
Unlike TCP, an SCTP sender MUST keep a set of these control variables Unlike TCP, an SCTP sender MUST keep a set of these control variables
cwnd, ssthresh and partial_bytes_acked for EACH destination address cwnd, ssthresh, and partial_bytes_acked for EACH destination address
of its peer (when its peer is multi-homed). Only one rwnd is kept of its peer (when its peer is multi-homed). Only one rwnd is kept
for the whole association (no matter if the peer is multi-homed or for the whole association (no matter if the peer is multi-homed or
has a single address). has a single address).
7.2.1. Slow-Start 7.2.1. Slow-Start
Beginning data transmission into a network with unknown conditions or Beginning data transmission into a network with unknown conditions or
after a sufficiently long idle period requires SCTP to probe the after a sufficiently long idle period requires SCTP to probe the
network to determine the available capacity. The slow start network to determine the available capacity. The slow-start
algorithm is used for this purpose at the beginning of a transfer, or algorithm is used for this purpose at the beginning of a transfer, or
after repairing loss detected by the retransmission timer. after repairing loss detected by the retransmission timer.
o The initial cwnd before DATA transmission or after a sufficiently o The initial cwnd before DATA transmission or after a sufficiently
long idle period MUST be set to min(4*MTU, max (2*MTU, 4380 long idle period MUST be set to min(4*MTU, max (2*MTU, 4380
bytes)). bytes)).
o The initial cwnd after a retransmission timeout MUST be no more o The initial cwnd after a retransmission timeout MUST be no more
than 1*MTU. than 1*MTU.
o The initial value of ssthresh MAY be arbitrarily high (for o The initial value of ssthresh MAY be arbitrarily high (for
example, implementations MAY use the size of the receiver example, implementations MAY use the size of the receiver
advertised window). advertised window).
o Whenever cwnd is greater than zero, the endpoint is allowed to o Whenever cwnd is greater than zero, the endpoint is allowed to
have cwnd bytes of data outstanding on that transport address. have cwnd bytes of data outstanding on that transport address.
o When cwnd is less than or equal to ssthresh, an SCTP endpoint MUST o When cwnd is less than or equal to ssthresh, an SCTP endpoint MUST
use the slow start algorithm to increase cwnd only if the current use the slow-start algorithm to increase cwnd only if the current
congestion window is being fully utilized, an incoming SACK congestion window is being fully utilized, an incoming SACK
advances the Cumulative TSN Ack Point, and the data sender is not advances the Cumulative TSN Ack Point, and the data sender is not
in Fast Recovery. Only when these three conditions are met can in Fast Recovery. Only when these three conditions are met can
the cwnd be increased; otherwise, the cwnd MUST not be increased. the cwnd be increased; otherwise, the cwnd MUST not be increased.
If these conditions are met, then cwnd MUST be increased by, at If these conditions are met, then cwnd MUST be increased by, at
most, the lesser of 1) the total size of the previously most, the lesser of 1) the total size of the previously
outstanding DATA chunk(s) acknowledged, and 2) the destination's outstanding DATA chunk(s) acknowledged, and 2) the destination's
path MTU. This upper bound protects against the ACK-Splitting path MTU. This upper bound protects against the ACK-Splitting
attack outlined in [SAVAGE99]. attack outlined in [SAVAGE99].
In instances where its peer endpoint is multi-homed, if an endpoint In instances where its peer endpoint is multi-homed, if an endpoint
receives a SACK that advances its Cumulative TSN Ack Point, then it receives a SACK that advances its Cumulative TSN Ack Point, then it
should update its cwnd (or cwnds) apportioned to the destination should update its cwnd (or cwnds) apportioned to the destination
addresses to which it transmitted the acknowledged data. However if addresses to which it transmitted the acknowledged data. However, if
the received SACK does not advance the Cumulative TSN Ack Point, the the received SACK does not advance the Cumulative TSN Ack Point, the
endpoint MUST NOT adjust the cwnd of any of the destination endpoint MUST NOT adjust the cwnd of any of the destination
addresses. addresses.
Because an endpoint's cwnd is not tied to its Cumulative TSN Ack Because an endpoint's cwnd is not tied to its Cumulative TSN Ack
Point, as duplicate SACKs come in, even though they may not advance Point, as duplicate SACKs come in, even though they may not advance
the Cumulative TSN Ack Point an endpoint can still use them to clock the Cumulative TSN Ack Point an endpoint can still use them to clock
out new data. That is, the data newly acknowledged by the SACK out new data. That is, the data newly acknowledged by the SACK
diminishes the amount of data now in flight to less than cwnd; and so diminishes the amount of data now in flight to less than cwnd, and so
the current, unchanged value of cwnd now allows new data to be sent. the current, unchanged value of cwnd now allows new data to be sent.
On the other hand, the increase of cwnd must be tied to the On the other hand, the increase of cwnd must be tied to the
Cumulative TSN Ack Point advancement as specified above. Otherwise Cumulative TSN Ack Point advancement as specified above. Otherwise,
the duplicate SACKs will not only clock out new data, but also will the duplicate SACKs will not only clock out new data, but also will
adversely clock out more new data than what has just left the adversely clock out more new data than what has just left the
network, during a time of possible congestion. network, during a time of possible congestion.
o When the endpoint does not transmit data on a given transport o When the endpoint does not transmit data on a given transport
address, the cwnd of the transport address should be adjusted to address, the cwnd of the transport address should be adjusted to
max(cwnd/2, 4*MTU) per RTO. max(cwnd/2, 4*MTU) per RTO.
7.2.2. Congestion Avoidance 7.2.2. Congestion Avoidance
When cwnd is greater than ssthresh, cwnd should be incremented by When cwnd is greater than ssthresh, cwnd should be incremented by
1*MTU per RTT if the sender has cwnd or more bytes of data 1*MTU per RTT if the sender has cwnd or more bytes of data
outstanding for the corresponding transport address. outstanding for the corresponding transport address.
In practice an implementation can achieve this goal in the following In practice, an implementation can achieve this goal in the following
way: way:
o partial_bytes_acked is initialized to 0. o partial_bytes_acked is initialized to 0.
o Whenever cwnd is greater than ssthresh, upon each SACK arrival o Whenever cwnd is greater than ssthresh, upon each SACK arrival
that advances the Cumulative TSN Ack Point, increase that advances the Cumulative TSN Ack Point, increase
partial_bytes_acked by the total number of bytes of all new chunks partial_bytes_acked by the total number of bytes of all new chunks
acknowledged in that SACK including chunks acknowledged by the new acknowledged in that SACK including chunks acknowledged by the new
Cumulative TSN Ack and by Gap Ack Blocks. Cumulative TSN Ack and by Gap Ack Blocks.
skipping to change at page 97, line 15 skipping to change at page 98, line 11
o Same as in the slow start, when the sender does not transmit DATA o Same as in the slow start, when the sender does not transmit DATA
on a given transport address, the cwnd of the transport address on a given transport address, the cwnd of the transport address
should be adjusted to max(cwnd / 2, 4*MTU) per RTO. should be adjusted to max(cwnd / 2, 4*MTU) per RTO.
o When all of the data transmitted by the sender has been o When all of the data transmitted by the sender has been
acknowledged by the receiver, partial_bytes_acked is initialized acknowledged by the receiver, partial_bytes_acked is initialized
to 0. to 0.
7.2.3. Congestion Control 7.2.3. Congestion Control
Upon detection of packet losses from SACK (see Section 7.2.4), An Upon detection of packet losses from SACK (see Section 7.2.4), an
endpoint should do the following: endpoint should do the following:
ssthresh = max(cwnd/2, 4*MTU) ssthresh = max(cwnd/2, 4*MTU)
cwnd = ssthresh cwnd = ssthresh
partial_bytes_acked = 0 partial_bytes_acked = 0
Basically, a packet loss causes cwnd to be cut in half. Basically, a packet loss causes cwnd to be cut in half.
When the T3-rtx timer expires on an address, SCTP should perform slow When the T3-rtx timer expires on an address, SCTP should perform slow
start by: start by:
ssthresh = max(cwnd/2, 4*MTU) ssthresh = max(cwnd/2, 4*MTU)
cwnd = 1*MTU cwnd = 1*MTU
and assure that no more than one SCTP packet will be in flight for and ensure that no more than one SCTP packet will be in flight for
that address until the endpoint receives acknowledgement for that address until the endpoint receives acknowledgement for
successful delivery of data to that address. successful delivery of data to that address.
7.2.4. Fast Retransmit on Gap Reports 7.2.4. Fast Retransmit on Gap Reports
In the absence of data loss, an endpoint performs delayed In the absence of data loss, an endpoint performs delayed
acknowledgement. However, whenever an endpoint notices a hole in the acknowledgement. However, whenever an endpoint notices a hole in the
arriving TSN sequence, it SHOULD start sending a SACK back every time arriving TSN sequence, it SHOULD start sending a SACK back every time
a packet arrives carrying data until the hole is filled. a packet arrives carrying data until the hole is filled.
Whenever an endpoint receives a SACK that indicates that some TSNs Whenever an endpoint receives a SACK that indicates that some TSNs
are missing, it SHOULD wait for 2 further miss indications (via are missing, it SHOULD wait for two further miss indications (via
subsequent SACKs for a total of 3 missing reports) on the same TSNs subsequent SACKs for a total of three missing reports) on the same
before taking action with regard to Fast Retransmit. TSNs before taking action with regard to Fast Retransmit.
Miss indications SHOULD follow the HTNA (Highest TSN Newly Miss indications SHOULD follow the HTNA (Highest TSN Newly
Acknowledged) algorithm. For each incoming SACK, miss indications Acknowledged) algorithm. For each incoming SACK, miss indications
are incremented only for missing TSNs prior to the highest TSN newly are incremented only for missing TSNs prior to the highest TSN newly
acknowledged in the SACK. A newly acknowledged DATA chunk is one not acknowledged in the SACK. A newly acknowledged DATA chunk is one not
previously acknowledged in a SACK. If an endpoint is in Fast previously acknowledged in a SACK. If an endpoint is in Fast
Recovery and a SACK arrives that advances the Cumulative TSN Ack Recovery and a SACK arrives that advances the Cumulative TSN Ack
Point, the miss indications are incremented for all TSNs reported Point, the miss indications are incremented for all TSNs reported
missing in the SACK. missing in the SACK.
skipping to change at page 98, line 24 skipping to change at page 99, line 21
3) Determine how many of the earliest (i.e., lowest TSN) DATA chunks 3) Determine how many of the earliest (i.e., lowest TSN) DATA chunks
marked for retransmission will fit into a single packet, subject marked for retransmission will fit into a single packet, subject
to constraint of the path MTU of the destination transport to constraint of the path MTU of the destination transport
address to which the packet is being sent. Call this value K. address to which the packet is being sent. Call this value K.
Retransmit those K DATA chunks in a single packet. When a Fast Retransmit those K DATA chunks in a single packet. When a Fast
Retransmit is being performed, the sender SHOULD ignore the value Retransmit is being performed, the sender SHOULD ignore the value
of cwnd and SHOULD NOT delay retransmission for this single of cwnd and SHOULD NOT delay retransmission for this single
packet. packet.
4) Restart T3-rtx timer only if the last SACK acknowledged the 4) Restart the T3-rtx timer only if the last SACK acknowledged the
lowest outstanding TSN number sent to that address, or the lowest outstanding TSN number sent to that address, or the
endpoint is retransmitting the first outstanding DATA chunk sent endpoint is retransmitting the first outstanding DATA chunk sent
to that address. to that address.
5) Mark the DATA chunk(s) as being fast retransmitted and thus 5) Mark the DATA chunk(s) as being fast retransmitted and thus
ineligible for a subsequent fast retransmit. Those TSNs marked ineligible for a subsequent Fast Retransmit. Those TSNs marked
for retransmission due to the Fast Retransmit algorithm that did for retransmission due to the Fast-Retransmit algorithm that did
not fit in the sent datagram carrying K other TSNs are also not fit in the sent datagram carrying K other TSNs are also
marked as ineligible for a subsequent fast retransmit. However, marked as ineligible for a subsequent Fast Retransmit. However,
as they are marked for retransmission they will be retransmitted as they are marked for retransmission they will be retransmitted
later on as soon as cwnd allows. later on as soon as cwnd allows.
6) If not in Fast Recovery, enter Fast Recovery and mark the highest 6) If not in Fast Recovery, enter Fast Recovery and mark the highest
outstanding TSN as the Fast Recovery exit point. When a SACK outstanding TSN as the Fast Recovery exit point. When a SACK
acknowledges all TSNs up to and including this exit point, Fast acknowledges all TSNs up to and including this exit point, Fast
Recovery is exited. While in Fast Recovery, the ssthresh and Recovery is exited. While in Fast Recovery, the ssthresh and
cwnd SHOULD NOT change for any destinations due to a subsequent cwnd SHOULD NOT change for any destinations due to a subsequent
Fast Recovery event (i.e., one SHOULD NOT reduce the cwnd further Fast Recovery event (i.e., one SHOULD NOT reduce the cwnd further
due to a subsequent fast retransmit). due to a subsequent Fast Retransmit).
Note: Before the above adjustments, if the received SACK also Note: Before the above adjustments, if the received SACK also
acknowledges new DATA chunks and advances the Cumulative TSN Ack acknowledges new DATA chunks and advances the Cumulative TSN Ack
Point, the cwnd adjustment rules defined in Section 7.2.1 and Point, the cwnd adjustment rules defined in Section 7.2.1 and Section
Section 7.2.2 must be applied first. 7.2.2 must be applied first.
A straightforward implementation of the above keeps a counter for A straightforward implementation of the above keeps a counter for
each TSN hole reported by a SACK. The counter increments for each each TSN hole reported by a SACK. The counter increments for each
consecutive SACK reporting the TSN hole. After reaching 3 and consecutive SACK reporting the TSN hole. After reaching 3 and
starting the fast retransmit procedure, the counter resets to 0. starting the Fast-Retransmit procedure, the counter resets to 0.
Because cwnd in SCTP indirectly bounds the number of outstanding Because cwnd in SCTP indirectly bounds the number of outstanding
TSN's, the effect of TCP fast-recovery is achieved automatically with TSN's, the effect of TCP Fast Recovery is achieved automatically with
no adjustment to the congestion control window size. no adjustment to the congestion control window size.
7.3. Path MTU Discovery 7.3. Path MTU Discovery
[RFC4821] specifies "Packetization Layer Path MTU Discovery", whereby [RFC4821], [RFC1981], and [RFC1191] specify "Packetization Layer Path
an endpoint maintains an estimate of the maximum transmission unit MTU Discovery", whereby an endpoint maintains an estimate of the
(MTU) along a given Internet path and refrains from sending packets maximum transmission unit (MTU) along a given Internet path and
along that path which exceed the MTU, other than occasional attempts refrains from sending packets along that path that exceed the MTU,
to probe for a change in the Path MTU (PMTU). [RFC4821] is thorough other than occasional attempts to probe for a change in the Path MTU
in its discussion of the MTU discovery mechanism and strategies for (PMTU). [RFC4821] is thorough in its discussion of the MTU discovery
determining the current end-to-end MTU setting as well as detecting mechanism and strategies for determining the current end-to-end MTU
changes in this value. setting as well as detecting changes in this value.
An endpoint SHOULD apply these techniques, and SHOULD do so on a per- An endpoint SHOULD apply these techniques, and SHOULD do so on a
destination-address basis. per-destination-address basis.
There are 2 important SCTP specific points regarding path MTU There are two important SCTP-specific points regarding Path MTU
discovery: discovery:
1) SCTP associations can span multiple addresses. An endpoint MUST 1) SCTP associations can span multiple addresses. An endpoint MUST
maintain separate MTU estimates for each destination address of maintain separate MTU estimates for each destination address of
its peer. its peer.
2) The sender should track an association PMTU which will be the 2) The sender should track an association PMTU that will be the
smallest PMTU discovered for all of the peer's destination smallest PMTU discovered for all of the peer's destination
addresses. When fragmenting messages into multiple parts this addresses. When fragmenting messages into multiple parts this
association PMTU should be used to calculate the size of each association PMTU should be used to calculate the size of each
fragment. This will allow retransmissions to be seamlessly sent fragment. This will allow retransmissions to be seamlessly sent
to an alternate address without encountering IP fragmentation. to an alternate address without encountering IP fragmentation.
8. Fault Management 8. Fault Management
8.1. Endpoint Failure Detection 8.1. Endpoint Failure Detection
An endpoint shall keep a counter on the total number of consecutive An endpoint shall keep a counter on the total number of consecutive
retransmissions to its peer (this includes retransmissions to all the retransmissions to its peer (this includes retransmissions to all the
destination transport addresses of the peer if it is multi-homed), destination transport addresses of the peer if it is multi-homed),
including unacknowledged HEARTBEAT Chunks. If the value of this including unacknowledged HEARTBEAT chunks. If the value of this
counter exceeds the limit indicated in the protocol parameter counter exceeds the limit indicated in the protocol parameter
'Association.Max.Retrans', the endpoint shall consider the peer 'Association.Max.Retrans', the endpoint shall consider the peer
endpoint unreachable and shall stop transmitting any more data to it endpoint unreachable and shall stop transmitting any more data to it
(and thus the association enters the CLOSED state). In addition, the (and thus the association enters the CLOSED state). In addition, the
endpoint MAY report the failure to the upper layer and optionally endpoint MAY report the failure to the upper layer and optionally
report back all outstanding user data remaining in its outbound report back all outstanding user data remaining in its outbound
queue. The association is automatically closed when the peer queue. The association is automatically closed when the peer
endpoint becomes unreachable. endpoint becomes unreachable.
The counter shall be reset each time a DATA chunk sent to that peer The counter shall be reset each time a DATA chunk sent to that peer
endpoint is acknowledged (by the reception of a SACK), or a endpoint is acknowledged (by the reception of a SACK) or a HEARTBEAT
HEARTBEAT-ACK is received from the peer endpoint. ACK is received from the peer endpoint.
8.2. Path Failure Detection 8.2. Path Failure Detection
When its peer endpoint is multi-homed, an endpoint should keep a When its peer endpoint is multi-homed, an endpoint should keep an
error counter for each of the destination transport addresses of the error counter for each of the destination transport addresses of the
peer endpoint. peer endpoint.
Each time the T3-rtx timer expires on any address, or when a Each time the T3-rtx timer expires on any address, or when a
HEARTBEAT sent to an idle address is not acknowledged within a RTO, HEARTBEAT sent to an idle address is not acknowledged within an RTO,
the error counter of that destination address will be incremented. the error counter of that destination address will be incremented.
When the value in the error counter exceeds the protocol parameter When the value in the error counter exceeds the protocol parameter
'Path.Max.Retrans' of that destination address, the endpoint should 'Path.Max.Retrans' of that destination address, the endpoint should
mark the destination transport address as inactive, and a mark the destination transport address as inactive, and a
notification SHOULD be sent to the upper layer. notification SHOULD be sent to the upper layer.
When an outstanding TSN is acknowledged or a HEARTBEAT sent to that When an outstanding TSN is acknowledged or a HEARTBEAT sent to that
address is acknowledged with a HEARTBEAT ACK, the endpoint shall address is acknowledged with a HEARTBEAT ACK, the endpoint shall
clear the error counter of the destination transport address to which clear the error counter of the destination transport address to which
the DATA chunk was last sent (or HEARTBEAT was sent). When the peer the DATA chunk was last sent (or HEARTBEAT was sent). When the peer
skipping to change at page 100, line 43 skipping to change at page 101, line 40
address of the last chunk sent. However, this ambiguity does not address of the last chunk sent. However, this ambiguity does not
seem to bear any significant consequence to SCTP behavior. If this seem to bear any significant consequence to SCTP behavior. If this
ambiguity is undesirable, the transmitter may choose not to clear the ambiguity is undesirable, the transmitter may choose not to clear the
error counter if the last chunk sent was a retransmission. error counter if the last chunk sent was a retransmission.
Note: When configuring the SCTP endpoint, the user should avoid Note: When configuring the SCTP endpoint, the user should avoid
having the value of 'Association.Max.Retrans' larger than the having the value of 'Association.Max.Retrans' larger than the
summation of the 'Path.Max.Retrans' of all the destination addresses summation of the 'Path.Max.Retrans' of all the destination addresses
for the remote endpoint. Otherwise, all the destination addresses for the remote endpoint. Otherwise, all the destination addresses
may become inactive while the endpoint still considers the peer may become inactive while the endpoint still considers the peer
endpoint reachable. When this condition occurs, how the SCTP chooses endpoint reachable. When this condition occurs, how SCTP chooses to
to function is implementation specific. function is implementation specific.
When the primary path is marked inactive (due to excessive When the primary path is marked inactive (due to excessive
retransmissions, for instance), the sender MAY automatically transmit retransmissions, for instance), the sender MAY automatically transmit
new packets to an alternate destination address if one exists and is new packets to an alternate destination address if one exists and is
active. If more than one alternate address is active when the active. If more than one alternate address is active when the
primary path is marked inactive only ONE transport address SHOULD be primary path is marked inactive, only ONE transport address SHOULD be
chosen and used as the new destination transport address. chosen and used as the new destination transport address.
8.3. Path Heartbeat 8.3. Path Heartbeat
By default, an SCTP endpoint SHOULD monitor the reachability of the By default, an SCTP endpoint SHOULD monitor the reachability of the
idle destination transport address(es) of its peer by sending a idle destination transport address(es) of its peer by sending a
HEARTBEAT chunk periodically to the destination transport HEARTBEAT chunk periodically to the destination transport
address(es). HEARTBEAT sending MAY begin upon reaching the address(es). HEARTBEAT sending MAY begin upon reaching the
ESTABLISHED state and is discontinued after sending either SHUTDOWN ESTABLISHED state and is discontinued after sending either SHUTDOWN
or SHUTDOWN-ACK. A receiver of a HEARTBEAT MUST respond to a or SHUTDOWN-ACK. A receiver of a HEARTBEAT MUST respond to a
HEARTBEAT with a HEARTBEAT-ACK after entering the COOKIE-ECHOED state HEARTBEAT with a HEARTBEAT-ACK after entering the COOKIE-ECHOED state
(INIT sender) or the ESTABLISHED state (INIT receiver), up until (INIT sender) or the ESTABLISHED state (INIT receiver), up until
reaching the SHUTDOWN-SENT state (SHUTDOWN sender) or the SHUTDOWN- reaching the SHUTDOWN-SENT state (SHUTDOWN sender) or the SHUTDOWN-
ACK-SENT state (SHUTDOWN receiver). ACK-SENT state (SHUTDOWN receiver).
A destination transport address is considered "idle" if no new chunk A destination transport address is considered "idle" if no new chunk
which can be used for updating path RTT (usually including first that can be used for updating path RTT (usually including first
transmission DATA, INIT, COOKIE ECHO, HEARTBEAT etc.) and no transmission DATA, INIT, COOKIE ECHO, HEARTBEAT, etc.) and no
HEARTBEAT has been sent to it within the current heartbeat period of HEARTBEAT has been sent to it within the current heartbeat period of
that address. This applies to both active and inactive destination that address. This applies to both active and inactive destination
addresses. addresses.
The upper layer can optionally initiate the following functions: The upper layer can optionally initiate the following functions:
A) Disable heartbeat on a specific destination transport address of a A) Disable heartbeat on a specific destination transport address of a
given association, given association,
B) Change the HB.interval, B) Change the HB.interval,
C) Re-enable heartbeat on a specific destination transport address of C) Re-enable heartbeat on a specific destination transport address of
a given association, and, a given association, and
D) Request an on-demand HEARTBEAT on a specific destination transport D) Request an on-demand HEARTBEAT on a specific destination transport
address of a given association. address of a given association.
The endpoint should increment the respective error counter of the The endpoint should increment the respective error counter of the
destination transport address each time a HEARTBEAT is sent to that destination transport address each time a HEARTBEAT is sent to that
address and not acknowledged within one RTO. address and not acknowledged within one RTO.
When the value of this counter reaches the protocol parameter When the value of this counter reaches the protocol parameter
'Path.Max.Retrans', the endpoint should mark the corresponding 'Path.Max.Retrans', the endpoint should mark the corresponding
skipping to change at page 102, line 34 skipping to change at page 103, line 34
HEARTBEAT ACK. The receiver of the HEARTBEAT ACK must also clear the HEARTBEAT ACK. The receiver of the HEARTBEAT ACK must also clear the
association overall error count as well (as defined in Section 8.1). association overall error count as well (as defined in Section 8.1).
The receiver of the HEARTBEAT ACK should also perform an RTT The receiver of the HEARTBEAT ACK should also perform an RTT
measurement for that destination transport address using the time measurement for that destination transport address using the time
value carried in the HEARTBEAT ACK chunk. value carried in the HEARTBEAT ACK chunk.
On an idle destination address that is allowed to heartbeat, it is On an idle destination address that is allowed to heartbeat, it is
recommended that a HEARTBEAT chunk is sent once per RTO of that recommended that a HEARTBEAT chunk is sent once per RTO of that
destination address plus the protocol parameter 'HB.interval', with destination address plus the protocol parameter 'HB.interval', with
jittering of +/- 50% of the RTO value, and exponential back-off of jittering of +/- 50% of the RTO value, and exponential backoff of the
the RTO if the previous HEARTBEAT is unanswered. RTO if the previous HEARTBEAT is unanswered.
A primitive is provided for the SCTP user to change the HB.interval A primitive is provided for the SCTP user to change the HB.interval
and turn on or off the heartbeat on a given destination address. The and turn on or off the heartbeat on a given destination address. The
heartbeat interval set by the SCTP user is added to the RTO of that heartbeat interval set by the SCTP user is added to the RTO of that
destination (including any exponential backoff). Only one heartbeat destination (including any exponential backoff). Only one heartbeat
should be sent each time the heartbeat timer expires (if multiple should be sent each time the heartbeat timer expires (if multiple
destinations are idle). It is a implementation decision on how to destinations are idle). It is an implementation decision on how to
choose which of the candidate idle destinations to heartbeat to (if choose which of the candidate idle destinations to heartbeat to (if
more than one destination is idle). more than one destination is idle).
Note: When tuning the heartbeat interval, there is a side effect that Note: When tuning the heartbeat interval, there is a side effect that
SHOULD be taken into account. When this value is increased, i.e. the SHOULD be taken into account. When this value is increased, i.e.,
HEARTBEAT takes longer, the detection of lost ABORT messages takes the HEARTBEAT takes longer, the detection of lost ABORT messages
longer as well. If a peer endpoint ABORTs the association for any takes longer as well. If a peer endpoint ABORTs the association for
reason and the ABORT chunk is lost, the local endpoint will only any reason and the ABORT chunk is lost, the local endpoint will only
discover the lost ABORT by sending a DATA chunk or HEARTBEAT chunk discover the lost ABORT by sending a DATA chunk or HEARTBEAT chunk
(thus causing the peer to send another ABORT). This must be (thus causing the peer to send another ABORT). This must be
considered when tuning the HEARTBEAT timer. If the HEARTBEAT is considered when tuning the HEARTBEAT timer. If the HEARTBEAT is
disabled only sending DATA to the association will discover a lost disabled, only sending DATA to the association will discover a lost
ABORT from the peer. ABORT from the peer.
8.4. Handle "Out of the blue" Packets 8.4. Handle "Out of the Blue" Packets
An SCTP packet is called an "out of the blue" (OOTB) packet if it is An SCTP packet is called an "out of the blue" (OOTB) packet if it is
correctly formed (i.e., passed the receiver's CRC32c check; see correctly formed (i.e., passed the receiver's CRC32c check; see
Section 6.8), but the receiver is not able to identify the Section 6.8), but the receiver is not able to identify the
association to which this packet belongs. association to which this packet belongs.
The receiver of an OOTB packet MUST do the following: The receiver of an OOTB packet MUST do the following:
1) If the OOTB packet is to or from a non-unicast address, a 1) If the OOTB packet is to or from a non-unicast address, a
receiver SHOULD silently discard the packet. Otherwise, receiver SHOULD silently discard the packet. Otherwise,
2) If the OOTB packet contains an ABORT chunk, the receiver MUST 2) If the OOTB packet contains an ABORT chunk, the receiver MUST
silently discard the OOTB packet and take no further action. silently discard the OOTB packet and take no further action.
Otherwise, Otherwise,
3) If the packet contains an INIT chunk with a Verification Tag set 3) If the packet contains an INIT chunk with a Verification Tag set
to '0', process it as described in Section 5.1. If, for whatever to '0', process it as described in Section 5.1. If, for whatever
reason, the INIT cannot be processed normally and an ABORT has to reason, the INIT cannot be processed normally and an ABORT has to
be sent in response, the Verification Tag of the packet be sent in response, the Verification Tag of the packet
containing the ABORT chunk MUST be the Initiate tag of the containing the ABORT chunk MUST be the Initiate Tag of the
received INIT chunk, and the T-Bit of the ABORT chunk has to be received INIT chunk, and the T bit of the ABORT chunk has to be
set to 0, indicating that the Verification Tag is NOT reflected. set to 0, indicating that the Verification Tag is NOT reflected.
4) If the packet contains a COOKIE ECHO in the first chunk, process 4) If the packet contains a COOKIE ECHO in the first chunk, process
it as described in Section 5.1. Otherwise, it as described in Section 5.1. Otherwise,
5) If the packet contains a SHUTDOWN ACK chunk, the receiver should 5) If the packet contains a SHUTDOWN ACK chunk, the receiver should
respond to the sender of the OOTB packet with a SHUTDOWN respond to the sender of the OOTB packet with a SHUTDOWN
COMPLETE. When sending the SHUTDOWN COMPLETE, the receiver of COMPLETE. When sending the SHUTDOWN COMPLETE, the receiver of
the OOTB packet must fill in the Verification Tag field of the the OOTB packet must fill in the Verification Tag field of the
outbound packet with the Verification Tag received in the outbound packet with the Verification Tag received in the
SHUTDOWN ACK and set the T-bit in the Chunk Flags to indicate SHUTDOWN ACK and set the T bit in the Chunk Flags to indicate
that the Verification Tag is reflected. Otherwise, that the Verification Tag is reflected. Otherwise,
6) If the packet contains a SHUTDOWN COMPLETE chunk, the receiver 6) If the packet contains a SHUTDOWN COMPLETE chunk, the receiver
should silently discard the packet and take no further action. should silently discard the packet and take no further action.
Otherwise, Otherwise,
7) If the packet contains a "Stale cookie" ERROR or a COOKIE ACK the 7) If the packet contains a "Stale Cookie" ERROR or a COOKIE ACK,
SCTP Packet should be silently discarded. Otherwise, the SCTP packet should be silently discarded. Otherwise,
8) The receiver should respond to the sender of the OOTB packet with 8) The receiver should respond to the sender of the OOTB packet with
an ABORT. When sending the ABORT, the receiver of the OOTB an ABORT. When sending the ABORT, the receiver of the OOTB
packet MUST fill in the Verification Tag field of the outbound packet MUST fill in the Verification Tag field of the outbound
packet with the value found in the Verification Tag field of the packet with the value found in the Verification Tag field of the
OOTB packet and set the T-bit in the Chunk Flags to indicate that OOTB packet and set the T bit in the Chunk Flags to indicate that
the Verification Tag is reflected. After sending this ABORT, the the Verification Tag is reflected. After sending this ABORT, the
receiver of the OOTB packet shall discard the OOTB packet and receiver of the OOTB packet shall discard the OOTB packet and
take no further action. take no further action.
8.5. Verification Tag 8.5. Verification Tag
The Verification Tag rules defined in this section apply when sending The Verification Tag rules defined in this section apply when sending
or receiving SCTP packets which do not contain an INIT, SHUTDOWN or receiving SCTP packets that do not contain an INIT, SHUTDOWN
COMPLETE, COOKIE ECHO (see Section 5.1), ABORT or SHUTDOWN ACK chunk. COMPLETE, COOKIE ECHO (see Section 5.1), ABORT, or SHUTDOWN ACK
The rules for sending and receiving SCTP packets containing one of chunk. The rules for sending and receiving SCTP packets containing
these chunk types are discussed separately in Section 8.5.1. one of these chunk types are discussed separately in Section 8.5.1.
When sending an SCTP pack