1 / 87

SCTP: Stream Control Transmission Protocol

SCTP: Stream Control Transmission Protocol. Table of Content. Introduction Motivations for Developing SCTP SCTP Features SCTP Terminology SCTP Packets SCTP States SCTP Data Transmission SCTP and Multihoming SCTP Streams SCTP Extensions Other STCP Research Topics

fred
Download Presentation

SCTP: Stream Control Transmission Protocol

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. SCTP: Stream Control Transmission Protocol

  2. Table of Content • Introduction • Motivations for Developing SCTP • SCTP Features • SCTP Terminology • SCTP Packets • SCTP States • SCTP Data Transmission • SCTP and Multihoming • SCTP Streams • SCTP Extensions • Other STCP Research Topics • References and Resources

  3. Introduction

  4. Application UDP TCP SCTP IPv4/IPv6 Link Layer Physical Layer IP Network • SCTP • is a reliable transport protocol operating on top of a potentially unreliable connectionless packet service such as IP. • offers acknowledged error-free non-duplicated transfer of datagrams. • a selective retransmission mechanism is applied to correct loss or corruption of data.

  5. Motivations for Developing SCTP

  6. Development by IETF SIGTRAN working group • To create a new, IP based transport protocol • For transport of signaling data over IP-based networks • Anticipation of carrier network convergence • All-IP networks • 3GPP networks based on IPv6 possible • communication between signaling gateways (SGs), media gateway controllers (MGCs) and signaling end- and transfer-points (SEP, STPs)

  7. Problems for TCP • Byte-Stream Oriented • Provide strict ordering of information, which causes Head of Line (HOL) Blocking problem • No built-in support for multi-homed IP hosts • Vulnerable for SYN flooding attacks (a kind of DoS attack using TCP three-way handshake • Problems for UDP • Unreliable data transfer • No congestion/flow control (applications must handle it by themselves)

  8. SCTP Features

  9. Provide an end-to-end reliable transmission service over IP networks • Support multiple streams: multiple streams per path • Support multi-homed hosts • Multiple IP addresses per host • More tolerant to network failures • Message-oriented: conserve message boundaries • Unordered delivery: SCTP can deliver messages as ordered or unordered. • Congestion Control: SCTP congestion control is similar to TCP. • Enable seamless introduction of SCTP into IP networks • SCTP is rate adaptive similar to TCP • slow start, congestion avoidance, fast retransmit and fast recovery • delayed Selective ACKs (SACKs) and duplicate SACKs

  10. Features Comparison

  11. SCTP Terminology

  12. Chunk • A unit of information within an SCTP packet, consisting of a chunk header and chunk-specific content. • SCTP association • A protocol relationship between SCTP endpoints. • It is composed of the two SCTP endpoints and protocol state information including Verification Tags and the currently active set of Transmission Sequence Numbers (TSNs), etc. • An association can be uniquely identified by the transport addresses used by the endpoints in the association. • Two SCTP endpoints MUST NOT have more than one SCTP association between them at any given time.

  13. Path • The route taken by the SCTP packets sent by one SCTP endpoint to a specific destination transport address of its peer SCTP endpoint. • Primary Path • The destination and source address that will be put into a packet outbound to the peer endpoint by default. • The above definition includes the source address since an implementation MAY wish to control the return path taken by reply chunks better and on which interface the packet is transmitted when the data sender is multi-homed. • Stream: • A uni-directional logical channel established from one to another associated SCTP endpoint. • All user messages are delivered in sequence except for those submitted to the unordered delivery service.

  14. IP IP IP2 IP1 IP1 IP2 TSN:SSN Data Chunk Application Application SCTP SCTP s3 s3 s1 s2 s1 s2 Association 7:3 8:3 9:3 4:2 5:2 6:2 1:1 2:1 3:1 buffer buffer 10.0.2.1:999 10.0.1.1:999 10.0.1.2:888 10.0.2.2:888 Primary Path Retransmission Path

  15. Idle destination address • An address that has not had user messages sent to it within some length of time. • Inactive destination transport address • An address which is considered inactive due to errors and unavailable to transport user messages. • SCTP packet • The unit of data delivery across the interface between SCTP and the connectionless packet network (e.g., IP). • An SCTP packet includes the common SCTP header, possible SCTP control chunks, and user data encapsulated within SCTP DATA chunks.

  16. Transmission Sequence Number (TSN) • A 32-bit sequence number used internally by SCTP. • One TSN is attached to each chunk containing user data to permit the receiving SCTP endpoint to acknowledge its receipt and detect duplicate deliveries. • Stream Sequence Number (SSN) • A 16-bit sequence number used internally by SCTP to assure delivery of the user messages within a given stream. • One stream sequence number is attached to each user message.

  17. Message Authentication Code (MAC) • An integrity check mechanism based on cryptographic hash functions using a secret key. • It is used by an endpoint to validate the State Cookie information that is returned from the peer in the COOKIE ECHO chunk. • Verification Tag • A 32 bit unsigned integer that is randomly generated. • It provides a key allowing a receiver to verify that the SCTP packet belongs to the current association and is not an old or stale packet from a previous association.

  18. SCTP Packets

  19. An SCTP packet forms the payload of an IP packet. • An SCTP packet is composed of a common header and chunks. • A chunk may contain either control information or user data. • Multiple chunks may be multiplexed into one SCTP packet up to the Path-MTU size. • Control chunks bundled before data chunks

  20. An SCTP-Protocol Data Unit with several chunks

  21. SCTP Common Header • Source and Destination Port • the same port concept as TCP and UDP • Verification Tag • the receiver of this packet uses the Verification Tag to validate the sender of this SCTP packet. • Checksum • each SCTP packet is protected by a 32 bit checksum (Adler-32 algorithm), which is thus more robust than the 16 bit checksum of TCP and UDP

  22. SCTP Chunks

  23. Payload Data (DATA) (0) • Stream Identifier • Identifies the stream to which the following user data belongs. • Stream Sequence Number • this value represents the stream sequence number of the following user data within the stream S.

  24. Initiation (INIT) • Initiate Tag • This value MUST be placed into the Verification Tag field of every SCTP packet. • Advertised Receiver Window Credit (a_rwnd) • This value represents the dedicated buffer space.

  25. Initiation Acknowledgement (INIT ACK) • The parameter part of INIT ACK is formatted similarly to the INIT chunk. It uses two extra variable parameters: The State Cookie and the Unrecognized Parameter:

  26. Selective Acknowledgement (SACK)

  27. Selective Acknowledgement (SACK) • SACK is sent to the peer endpoint to acknowledge received DATA chunks and to inform the peer endpoint of gaps in the received subsequences of DATA chunks as represented by their TSNs. • Cumulative TSN Ack • This parameter contains the TSN of the last DATA chunk received in sequence before a gap. • Gap Ack Block Start • Indicates the Start offset TSN for this Gap Ack Block. • Gap Ack Block End • Indicates the End offset TSN for this Gap Ack Block. • Gap Ack Blocks • TSNs >= (Cumulative TSN Ack + Gap Ack Block Start) and TSNs <= (Cumulative TSN Ack + Gap Ack Block End) • These TSNs are assumed to have been received correctly.

  28. Selective Acknowledgement (SACK) • Duplicate TSN • Indicates the number of times a TSN was received in duplicate 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 duplicates. The duplicate count is re-initialized to zero after sending each SACK.

  29. Selective Acknowledgement (SACK) 12+2 ~ 12+3 12+5 ~ 12+5

  30. Selective Acknowledgement (SACK) 10+2 ~ 10+6

  31. Heartbeat Request (HEARTBEAT) • Sent by endpoint and to probe the reachability of a particular destination transport address. Heartbeat Acknowledgement (HEARTBEAT ACK)

  32. Abort Association (ABORT) • It is sent to the peer of an association to close the association. • If an endpoint receives an ABORT with a format error or for an association that doesn’t exist, it MUST silently discard it. • DATA chunks MUST NOT be bundled with ABORT.

  33. Shutdown Association (SHUTDOWN) • An endpoint in an association MUST use this chunk to initiate a graceful close of the association with its peer. Shutdown Acknowledgement (SHUTDOWN ACK)

  34. Operation Error (ERROR) • An endpoint sends this chunk to its peer endpoint to notify it of certain error conditions. • Error causes are defined as variable-length parameters

  35. Operation Error (ERROR) • Each error cause may carry its own set of parameters. The error causes that have been defined are

  36. Cookie Echo (COOKIE ECHO) • It is used only during the initiation of an association • It must precede any DATA chunk sent within the association, but may be bundled with one or more DATA chunks in the same packet. Cookie Acknowledgement (COOKIE ACK)

  37. Shutdown Complete (SHUTDOWN COMPLETE) • Be sent to acknowledge the receipt of the SHUTDOWN ACK chunk at the completion of the shutdown process.

  38. SCTP States

  39. Association establishment and shutdown. SCTP uses a cookie mechanism in a four-way handshake to establish an association. • The shutdown process is a three-way handshake.

  40. Normal Association Establishment a

  41. The endpoint that initiates the association will be referred to as “Node A”; the peer endpoint that receives the association establishment requests will be referred to as “Node B”. • Node A generates an INIT chunk and sends it to Node B. Node A starts the INIT timer. • If Node B wishes to accept the association, it generates an INIT_ACK chunk that includes a cookie. It then sends the INIT ACK chunk, along with a cookie, back to Node A.

  42. Node A receives the INIT ACK chunk and stops INIT timer. Node A generates a COOKIE ECHO chunk, which is then sent to Node B. Node A starts the cookie timer. DATA chunks may be also be bundled in this packet. • Node B checks the validity of the cookie. Following validation it sends a COOKIE ACK back to Node A. • Node A receives the COOKIE ACK and enters into the next phase of data transmission.

  43. Association Termination a

  44. Node A sends a SHOTDOWN chunk to Node B and start the shutdown timer. • Node B acknowledges the receipt of the SHUTDOWN chunk through the generation of SHUTDOWN ACK chunk, which is sent to Node A. • Node A receives the SHUTDOWN ACK and responds by stopping the SHUTDOWN timer. Then, Node A generates a SHUTDOWN COMPLETE chunk and sends the chunk to Node B.

  45. SCTP Data Transmission

  46. General Concepts • Detection of loss and duplication of data chunks is enabled by numbering all data chunks in the sender with the so-called Transmission Sequence Number (TSN). • The acknowledgements sent from the receiver to the sender are based on TSNs. • Retransmissions are timer-controlled. The timer duration is derived from continuous measurements of the round trip delay (RTT). • Whenever such a retransmission timer expires, (and congestion control allows transmissions) all non-acknowledged data chunks are retransmitted and the timer is started again doubling its initial duration (like in TCP).

  47. General Concepts • When the receiver detects one or more gaps in the sequence of data chunks, each received SCTP packet is acknowledged by sending a Selective Acknowledgement (SACK) which reports all gaps. • Whenever the sender receives four consecutive SACKs reporting the same data chunk missing, this data chunk is immediately retransmitted (fast retransmit). • Most up-to-date operating systems already support a similar optional extension to TCP.

  48. Flow Control • SCTP uses an end-to-end window based flow and congestion control mechanism similar to the one that is well known from TCP. • The receiver of data may control the rate at which the sender is sending by specifying an octet-based window size (the so-called Receiver Window), and returning this value along with all SACK chunks. • The sender itself keeps a variable known as Congestion Window (CWND) that controls the maximum number of outstanding bytes • Each received data chunk must be acknowledged, and the receiver may wait a certain time before that is done

  49. Selective Acknowledgement • The acknowledgements carry all TSN numbers that have been received by one side with them. • That is, there is a so called Cumulative TSN Ack value, that indicates all the data that have successfully been reassembled at the receivers side, and has either already been delivered to the receiving Upper Layer Process, or may readily be delivered upon request. • Moreover, there are so-called Gap Blocks that indicate which segments of data chunks have arrived, with some data chunks missing in between.

More Related