/SCTP -Stream Control Transmission Protocol-

SCTP -Stream Control Transmission Protocol-

The SCTP is a 11 years old protocol which have been standarized on 2000.
SCTP is reliabe, message-oriented and provides multiple streams.the SCTP almost has the same functionality that the TCP do in it’s one-to-one interface, the one-to-many interface of the SCTP allows trivial porting of the application and some more advanced features unlike one-to-one interface.
so it’s prefered to use the one-to-many interface.

unlike TCP. SCTP is message oriented. it provides sequenced delivery of sequenced records like UDP.
SCTP can provide multiple streams between connection endpoints. each stream has it’s own sequenced delivery messages.
SCTP provides multihoming which means that a single SCTP endpoint can support multiple IP addresses. which means that SCTP can override a network failure by switching to another address which is already associated with the SCTP.
we mentioned before that SCTP is message-oriented.but it’s connection-oriented just like TCP too, but unlike the TCP connection establishment which is three way handshake. SCTP connection establishment is four-way handshake.
You might think that the number is the issue (3 or 4) but the SCTP handshakes are different from the TCP handshakes.
Here goes the scenario :-
1 – server must be ready to accept a connection by supporting a socket and calling bind and listen
2- the client calls connect or sends a message to the server. this makes this client sends it’s list of IP addresses,ISN, number of streams client requests( this is called INIT message )
3- the server ACK the client INIT message with sending INIT,ACK which has the server IP list…etc(like the client) + the state cookie which is a cookie contains all of the stat that the server need to ensure.
4- the client ECHO the cookie with COOKIE-ECHO message
5- the server ACK the validity of that cookie by sending a COOKIE-ACK message

This figure illustrate the 4-way handshake process using 4 packets

But always remember that the SCTP doesn’t have to go into connection establishment to send and receive data. SCTP can be connection oriented or message oriented(connectionless like UDP).
the SCTP interface models as I mentioned above there are two interface models one-to-one,one-to-many. one-to-one interface can correspond to only and only one endpoint. but one-to-many can correspond to many endpoints from one server.
The One-to-One Style :-
this style provides the same functionality the TCP has. what happens in the one to one style is:-
server starts(calls socket,bind,listen),client starts(calls socket,connect). now we have a byte stream between these two points and they exchange data and close connection. so here the server can’t associate many connections at a time because it’s already connected to a point

the One-To-Many style :-
the one to many have several merits. best of them is that an SCTP one-to-many endpoint that can write a server without without managing a large number of sockets. one socket is enough…just like UDP!

What happens here is that the server starts create a socket and bind and listen and then waits for a message.(this blocks till a message arrives),client starts and calls a socket and sends a message and does the four way handshake, server receives the message and sends back a reply..etc and then they both close the socket…enough for today 🙂