1 / 31

SCTP: next generation signalling protocol and FreeBSD 7

SCTP: next generation signalling protocol and FreeBSD 7. Murat Balaban. Director, R & D ender sys ltd. http://www.enderunix.org/murat/. SCTP Intro. new IP transport protocol, existing at an equivalent level as UDP and TCP

whitney
Download Presentation

SCTP: next generation signalling protocol and FreeBSD 7

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: next generation signalling protocoland FreeBSD 7 Murat Balaban Director, R & Dendersys ltd.http://www.enderunix.org/murat/

  2. SCTP Intro • new IP transport protocol, existing at an equivalent level as UDP and TCP • provide transport layer functions to all of the main Internet applications • IETF standart • RFC 2960 – RFC 3758

  3. Like TCP • provides a reliable transport service • In-order delivery • connection-oriented • Congestion avoidance • Slow start

  4. Unlike TCP • provides a number of functions that are considered critical for signaling transport • at the same time can provide transport benefits to other applications requiring additional performance and reliability. 

  5. SCTP Core Features • Multi-streaming • Multi-homing

  6. Multi-streaming • Name is derived from the multi-streaming function • In contrast, TCP provides a single stream of data and ensures that delivery of that stream takes place with perfect sequence preservation • For a number of applications, this characteristic of strict sequence preservation is not truly necessary

  7. Multi-streaming contd. • Signalling Multiple streams can carry different signalls of varying importance Multiple calls can be placed on different streams whithin the same “association”

  8. Multi-streaming contd. • Web page objects Objects can be placed on different independent streams, which results in a better perceived performance.

  9. Multi-streaming: How? By creating independence between data transmission and data delivery.  In particular, each DATA “chunk” (or PDU) in the protocol uses two sets of sequence numbers, a Transmission Sequence Number that governs the transmission of messages and the detection of message loss, and the Stream ID/Stream Sequence Number pair, which is used to determine the sequence of delivery of received data.

  10. Multi-homing • the ability for a single SCTP endpoint to support multiple IP addresses • Benefit: potentially greater survivability of the session in the presence of network failures • redundant LANs can be used to reinforce the local access, while various options are possible in the core network to reduce the dependency of failures for different addresses

  11. App-3 App-2 App-1 OS NI-1 NI-2 NI-3 160.15.82.20 10.1.61.11 161.10.8.221 Multi-homing

  12. Multi-homing contd. • Use of addresses with different prefixes can force routing to go through different carriers, for example, while route-pinning techniques or even redundant core networks can also be used if there is control over the network architecture and protocols.

  13. Multi-homing: load sharing? • Nope. • Only for redundancy

  14. Multi-homing: load sharing? • Nope. • Only for redundancy

  15. Multi-homing: How? • SCTP endpoints can exchange lists of addresses during initiation of the association • A single port number is used across the entire address list at an endpoint for a specific session. • to reduce the potential for security problems, it is required that some response messages be sent specifically to the source address in the message that caused the response

  16. Other features • a unicast protocol, and supports data exchange between exactly 2 endpoints, although these may be represented by multiple IP addresses. • provides reliable transmission • Full-duplex

  17. Other features contd. • message oriented and supports framing of individual message boundaries.  In comparison, TCP is stream oriented and does not preserve any implicit structure within a transmitted byte stream. • Rate-adaptive • Unordered data delivery option

  18. Other features contd. • Security cookie against connection flood attack (SYN flood) • Built-in heartbeat (reachability check) • Extensibility (TLV chunks)

  19. Association Establishment • To establish this state, both sides go through a specific set of exchanges • TCP uses a 3-way handshake (SYN, SYN/ACK, ACK) • SCTP uses a 4-way handshake • In TCP, the communication relationship between two endpoints is called a “connection” • In SCTP, this is called an “association” this is because it is a broader concept than a single connection (i.e. multi-homing)

  20. Endpoint A Endpoint Z INIT INIT-ACK Association Is Up * Association Is Up COOKIE-ECHO * COOKIE-ACK * -- User data can be attached Setting Up an Association

  21. [Rcv INIT] Gen Cookie Send INIT-ACK CLOSED COOKIE_WAIT [ASSOCIATE] Create TCB Send INIT Start init timer [rcv valid COOKIE-ECHO] Create TCB Send COOKIE-ACK [rcv INIT-ACK] Send COOKIE-ECHO Stop init timer Start cookie timer COOKIE_ECHOED ESTABLISHED [rcv COOKIE-ACK] Stop cookie timer SCTP States I

  22. ESTABLISHED [SHUTDOWN] Check outstanding data chunks [rcv SHUTDOWN] Check outstanding data chunks SHUTDOWN- PENDING SHUTDOWN- PENDING [No More Outstanding data chunks] Send SHUTDOWN Start shutdown timer [No More Outstanding data chunks] Send SHUTDOWN-ACK Start shutdown- timer NEXT-SLIDE NEXT-SLIDE SCTP States II

  23. FROM STATES-2 FROM STATES-2 SHUTDOWN- SENT SHUTDOWN- ACK-SENT [rcv SHUTDOWN-ACK] send SHUTDOWN_COMPETE Stop shutdown timer Delete TCB [rcv SHUTDOWN-COMPLETE] Stop shutdown timer delete TCB CLOSED SCTP States III

  24. IP Header SCTP Common Header Chunk 1 ... Chunk N SCTP Header with IP

  25. Source Port Destination Port Verification Tag CRC-32c Checksum Common Header

  26. Chunk Type Chunk Length Chunk Flags Chunk Data SCTP Chunks • Chunk Type: 8-bit value indicating the type of chunk • Chunk Flags: 8-bit flags, defined on per chunk type basis • Chunk Length: 16-bit length in bytes, including the chunk type, chunk flags, and chunk length fields. • Note that chunks are padded to 32-bit boundaries within an SCTP packet. Any padding bytes (0x00) used are NOT included in the chunk length

  27. SCTP Chunk Types • There are 20 chunk types currently defined in SCTP (including non-RFC/Internet Draft extensions): • (1) DATA (0x00) • (2) INITIATION [INIT] (0x01) • (3) INITIATION-ACKNOWLEDGMENT [INIT-ACK] (0x02) • (4) SELECTIVE-ACKNOWLEDGMENT [SACK] (0x03) • (5) HEARTBEAT (0x04)

  28. Flags=0 Type=a Length=variable State Cookie from INIT-ACK Cookie Echo Chunk

  29. Type=0x00 Flags=UBE Length=variable TSN Value Stream Sequence Num Stream Identifier Payload Protocol Identifier Variable Length User Data DATA Chunk Flag Bits ‘UBE’ are used to indicate: • U – Unordered Data • B – Beginning of Fragmented Message • E – End of Fragmented Message • A user message that fits in one chunk would have both the B and E bits set

  30. FreeBSD ready? • Not yet. • -CURRENT • Planned for 7.0-RELEASE • Thanks to Randal Steward

  31. -- Thanks -- Q & A Murat Balaban EnderUNIX Yazılım Geliştirme Takımımurat@enderunix.orghttp://www.enderunix.org/murat/

More Related