SCTP Vs TCP

25
SCTP v/s TCP – A SCTP v/s TCP – A Comparison of Comparison of Transport Protocols Transport Protocols Presentation Presentation by by Mukesh Kumar Sharma Mukesh Kumar Sharma

description

SCTP Vs TCP, Ericsson, Transmision

Transcript of SCTP Vs TCP

  • SCTP v/s TCP A Comparison of Transport ProtocolsPresentationbyMukesh Kumar Sharma

  • OutlineMotivationIntroduction to SCTPDifference with TCPExperimental DesignParametersResultsConclusion

  • MotivationTCP has provided the primary means to transfer data reliably across the Internet, however TCP has imposed limitations on several applications.

    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.

  • MotivationThe 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 thepush facilityto 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 usingmulti-homedhosts.TCP is relatively vulnerable to denial-of-service attacks, such asSYN attacks.

  • Motivation (contd)

    HTTP is one such application

    While transferring multiple embedded files we only wantReliable file transfer for each filePartial ordering for the packets of each file but not total ordering amongst all the packets

    SYN FLOOD or ATTACKS

    A SYN flood is a form of denial-of-service attack in which an attacker sends a succession of SYN requests to a target's system in an attempt to consume enough server resources to make the system unresponsive to legitimate traffic.The server will wait for the acknowledgement for some time, as simple network congestion could also be the cause of the missing ACK, but in an attack increasingly large numbers of half-open connections will bind resources on the server until no new connections can be made, resulting in a denial of service to legitimate traffic. Some systems may also malfunction badly or even crash if other operating system functions are starved of resources in this way.

  • What is SCTP?Originally designed to support PSTN signaling messages over IP Networks.It is a reliable transport protocol operating on top of a connectionless packet network such as IP (same level as TCP).TheStream Control Transmission Protocol(SCTP) is atransport layerprotocol(protocol number 132]) serving in a similar role to the popular protocolsTransmission Control Protocol(TCP) andUser Datagram Protocol(UDP).It provides some of the same service features of both: it is message-oriented like UDP and ensures reliable, in-sequence transport of messages withcongestion controllike TCP.In the absence of native SCTP support in operating systems it is possible totunnelSCTP over UDP,[3]as well as mapping TCP API calls to SCTP ones.

  • Major Differences from TCPSCTP is message oriented as opposed to being byte stream oriented

    SCTP has the concept of an association instead of a connection

    Each association can have multiple streams

    SCTP separates reliable transfer of datagrams from the delivery mechanism

    SCTP supports multihoming.

  • Major Differences from TCPSCTP uses what are called associations, which are similar to the connections, with which we are all familiar inTCP. However, a SCTP association can actually include multiple connections.

    It is not uncommon to see hundreds of point-to-point connections under one SCTP association. In fact this is arequirement for a telecommunications network.

    SCTP provides multi-homing support where one (or both) endpoints of a connection can support more than one IPaddress. This capability provides transparent fail-over between redundant network paths.

  • Throw More LightSCTP applications submit their data to be transmitted in messages (groups of bytes) to the SCTP transport layer. SCTP places messages and control information into separatechunks(data chunks and control chunks), each identified by achunk header. The protocol can fragment a message into a number of data chunks, but each data chunk contains data from only one user message. SCTP bundles the chunks into SCTP packets. The SCTP packet, which is submitted to theInternet Protocol, consists of a packet header, SCTP control chunks (when necessary), followed by SCTP data chunks (when available).

    SCTP may be characterized as message-oriented, meaning it transports a sequence of messages (each being a group of bytes), rather than transporting an unbroken stream of bytes as does TCP. As in UDP, in SCTP a sender sends a message in one operation, and that exact message is passed to the receiving application process in one operation. In contrast, TCP is a stream-oriented protocol, transportingstreams of bytesreliably and in order. However TCP does not allow the receiver to know how many times the sender application called on the TCP transport passing it groups of bytes to be sent out. At the sender, TCP simply appends more bytes to a queue of bytes waiting to go out over the network, rather than having to keep a queue of individual separate outbound messages which must be preserved as such.

  • Throw More LightThe termmulti-streamingrefers to the capability of SCTP to transmit several independent streams of chunks in parallel, for example transmittingweb pageimages together with the web page text. In essence, it involves bundling several connections into a single SCTP association, operating on messages (or chunks) rather than bytes.

    TCP preserves byte order in the stream by assigning a sequence number to each packet. SCTP, on the other hand, assigns a sequence number to eachmessagesent 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 of receipt instead of the order they were sent.

  • WHY SCTP FOR LTENow we all know that TCP is great for what it does over the Internet, but in a telecom environment SCTP is necessary. Why?SCTP handles the communications between the eNodeB and the MME. Thiscommunication connection is very important and fragile since it must be able to detect dropouts very quickly. TCP does notdo this, whereas SCTP has watchdogs that immediately recognize when a packet is dropped or a link goes down. LTEproviders specifically and telecom networks in general need this ability to insure a high quality of service.Additionally SCTP has, as a default, selective ACK, which is optional in TCP. What this means is that a packet will NEVERbe resent if it has already been acknowledged as sent. In the LTE world, where every bit counts, using SCTP means no wasted data.

  • Packet Format

  • Similarities to TCPSimilar Flow Control and Congestion Control Strategies employed

    Slow Start and Congestion Avoidance phasesSelective AcknowledgementFast Retransmit3 way hand-shake

  • HTTP Server ArchitectureSingle File Transfer ( Both TCP and SCTP are similar)Childprocess

  • HTTP Server ArchitectureMultiple File Transfer (Embedded files) - TCPChildprocess

  • HTTP Server ArchitectureMultiple Files Transfer (Embedded Files) - SCTPChildprocess

  • ParametersWe observe latencies for single file and multiple file transfers by varying the following parameters

    Loss rate (0%, 1%, 2%, 5%, 8%, 10%, 15%, 20%, 25%)Link Bandwidth (40kbps, 400kbps, 3mbps,10mbps)We keep Latency constant (80ms)

  • Results

  • Results

  • Results

  • About Errors

    Loss in this direction 1%Loss in this direction 1%

  • Reason

    3

    21321File 2File 31

    TCPReceive buffer in kernelServerClient

    TCPSend buffer in kernel231

    23

  • Reason

    321321File 2File 31

    SCTPReceive buffer in kernelServerClient

    SCTPReceive buffer in kernel23123

  • ConclusionsThe current SCTP implementation performs almost as well as TCP when there are no losses However, there is an extra overhead in sending messages instead of just a stream of bytes

    SCTP seems to perform better in the presence of losses, because it does not enforce strictly ordered delivery

    More graphs available at http://www.cs.wisc.edu/~raj/sctp

  • ImplicationsSCTP can be a viable transport protocol for HTTP traffic, because

    It helps reduce user-perceived latency and also improves throughputUses a 4-way handshake and also uses an encrypted cookie, which offer better protection against SYN floods and DoS attacksMultihoming feature can be exploited to transparently allow mobile users to switch between networks