In computer networking, the Stream Control Transmission Protocol (SCTP) is a Transport Layer protocol, serving in a similar role as the popular protocols TCP and UDP. Indeed, it provides some of the same service features of both, ensuring reliable, in-sequence transport of messages with congestion control.
The protocol was defined by the IETF Signaling Transport (SIGTRAN) working group in 2000. RFC 4960 defines the protocol. RFC 3286 provides an introduction.
In the absence of native SCTP support in operating systems it is possible to tunnel SCTP over UDP,[1], as well as mapping TCP API calls to SCTP ones.[2]
| The TCP/IP model (RFC 1122) |
|---|
| Application Layer |
|
BGP · DHCP · DNS · FTP · Gopher · GTP · HTTP · IMAP · IRC · NNTP · NTP · POP · RIP · RPC · RTCP · RTP · RTSP · SDP · SIP · SMTP · SNMP · SOAP · SSH · SSL · STUN · Telnet · TLS · XMPP · (more) |
| Transport Layer |
| TCP · UDP · DCCP · SCTP · RSVP · ECN · (more) |
| Internet Layer |
| IP (IPv4 · IPv6) · ICMP · ICMPv6 · IGMP · IPsec · (more) |
| Link Layer |
| ARP · RARP · NDP · OSPF · Tunnels · Media Access Control · Device Drivers · (more) |
Contents |
Whereas TCP is stream-oriented, i.e., transports byte streams, SCTP is transaction-oriented, meaning it transports data in one or more messages. A message is a group of bytes sent in one transaction (transmit operation). Although TCP correctly reorders data that arrives out of order, it is concerned only with bytes. It does not honor message boundaries, i.e., the structure of data in terms of their original transmission units at the sender. SCTP, in contrast, conserves message boundaries by operating on whole messages in a fashion similar to the User Datagram Protocol (UDP). This means that a group of bytes that is sent in one transmission operation (transaction) is read exactly as that group, called message, at the receiver.
The term "multi-streaming" refers to the capability of SCTP to transmit several independent streams of messages in parallel, for example transmitting Web page images together with the Web page text. You can think of multi-streaming as bundling several TCP connections into a single SCTP association, operating on messages rather than bytes.
TCP preserves byte order in the stream by assigning a sequence number to each byte. SCTP, on the other hand, assigns a sequence number to each message sent in a stream. This allows independent ordering of messages in different streams. However, message ordering is optional in SCTP; a receiving application may choose to process messages in the order they are received instead of the order they were sent.
Benefits of SCTP include:
The designers of SCTP originally intended it for the transport of telephony (Signaling System 7) protocols over IP, with the goal of duplicating some of the reliability attributes of the SS7 signaling network in IP. This IETF effort is known as SIGTRAN. In the meantime, other uses have been proposed, for example the Diameter protocol and Reliable server pooling ("RSerPool").
Transmission Control Protocol (TCP) has provided the primary means to transfer data across the Internet in a reliable way.
However, TCP has imposed limitations on several applications. From RFC 4960:
- TCP provides both reliable data transfer and strict order-of- transmission delivery of data. Some applications need reliable transfer without sequence maintenance, while others would be satisfied with partial ordering of the data. In both of these cases, the head-of-line blocking offered by TCP causes unnecessary delay.
- The stream-oriented nature of TCP is often an inconvenience. Applications must add their own record marking to delineate their messages, and must make explicit use of the push facility to ensure that a complete message is transferred in a reasonable time.
- The limited scope of TCP sockets complicates the task of providing highly-available data transfer capability using multi-homed hosts.
- TCP is relatively vulnerable to denial-of-service attacks, such as SYN attacks.
These limitations affect the performance of IP over public switched telephone networks.
| Feature Name | UDP | TCP | SCTP |
|---|---|---|---|
| Connection oriented | No | Yes | Yes |
| Reliable transport | No | Yes | Yes |
| Preserve message boundary | Yes | No | Yes |
| Ordered delivery | No | Yes | Yes |
| Unordered delivery | Yes | No | Yes |
| Data checksum | Yes | Yes | Yes |
| Checksum size (bits) | 16 | 16 | 32 |
| Path MTU | No | Yes | Yes |
| Congestion control | No | Yes | Yes |
| Multiple streams | No | No | Yes |
| Multi-homing support | No | No | Yes |
| Bundling / Nagle | No | Yes | Yes |
The following operating systems implement SCTP:
Various third-party implementations of SCTP exist for other operating systems. FreeBSD contains the SCTP reference implementation.[3]
Userspace library:
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
SCTP packets have a simpler basic structure than TCP or UDP packets. Each consists of two basic sections:
Each chunk has a type identifier that is one byte long yielding, at most, 255 different chunk types. RFC 4960 defines a list of chunk types and there are currently 15 types defined. The remainder of the chunk is a two byte length (maximum size of 65,535 bytes) and the data. If the chunk does not form a multiple of 4 bytes (i.e., the length is not a multiple of 4) then it is implicitly padded with zeros which are not included in the chunk length.
No comments have been added.