SlideShare a Scribd company logo
1 of 15
1 
My First PPT 
This Is my first ppt.
2 
Overview 
TCP = Transmission Control Protocol 
• Connection-oriented protocol 
• Provides a reliable unicast end-to-end byte stream over an 
unreliable internetwork. 
TCP 
IP Internetwork 
Byte Stream 
Byte Stream 
TCP
3 
Connection-Oriented 
• Before any data transfer, TCP establishes a connection: 
• One TCP entity is waiting for a connection (“server”) 
• The other TCP entity (“client”) contacts the server 
• The actual procedure for setting up connections is more 
complex. 
• Each connection is 
CLIENT SERVER 
full duplex 
waiting for 
connection 
request 
Request a connection 
Accept a connection 
Disconnect Data Transer
4 
Reliable 
• Byte stream is broken up into chunks which are called seg-ments 
• Receiver sends acknowledgements (ACKs) for segments 
• TCP maintains a timer. If an ACK is not received in time, 
the segment is retransmitted 
•Detecting errors: 
• TCP has checksums for header and data. Segments with 
invalid checksums are discarded 
• Each byte that is transmitted has a sequence number
5 
Byte Stream Service 
• To the lower layers, TCP handles data in blocks, the 
segments. 
• To the higher layers TCP handles data as a sequence of 
bytes and does not identify boundaries between bytes 
• So: Higher layers do not know about the beginning and 
end of segments ! 
TCP 
Application 
1. write 100 bytes 
2. write 20 bytes 
queue of 
bytes to be 
transmitted TCP 
queue of 
bytes that 
have been 
received 
Application 
1. read 40 bytes 
2. read 40 bytes 
3. read 40 bytes 
Segments
6 
TCP Format 
• TCP segments have a 20 byte header with >= 0 bytes of data. 
IP header TCP header TCP data 
Sequence number (32 bits) 
TCP checksum urgent pointer 
DATA 
20 bytes 20 bytes 
0 15 16 31 
Source Port Number Destination Port Number 
Acknowledgement number (32 bits) 
header window size 
length 0 Flags 
Options (if any) 
20 bytes
7 
TCP header fields 
• Port Number: 
• A port number identifies the endpoint of a connection. 
• A pair <IP address, port number> identifies one 
endpoint of a connection. 
• Two pairs <client IP address, server port number> 
and <server IP address, server port number> identify 
a TCP connection. 
Applications 
Ports: 23 80 104 
TCP 
IP 
Applications 
7 80 16 Ports: 
TCP 
IP
8 
TCP header fields 
• Sequence Number (SeqNo): 
– Sequence number is 32 bits long. 
– So the range of SeqNo is 
0 <= SeqNo <= 232 -1 » 4.3 Gbyte 
– Each sequence number identifies a byte in the byte 
stream 
– Initial Sequence Number (ISN) of a connection is set 
during connection establishment 
Q: What are possible requirements for ISN ?
9 
TCP header fields 
• Acknowledgement Number (AckNo): 
– Acknowledgements are piggybacked, I.e 
a segment from A -> B can contain an 
acknowledgement for a data sent in the B -> A direction 
Q: Why is piggybacking good ? 
– A hosts uses the AckNo field to send acknowledgements. 
(If a host sends an AckNo in a segment it sets the “ACK flag”) 
– The AckNo contains the next SeqNo that a hosts wants to 
receive 
Example: The acknowledgement for a segment with 
sequence numbers 0-1500 is AckNo=1501
10 
TCP header fields 
• Acknowledge Number (cont’d) 
– TCP uses the sliding window flow protocol (see CS 457) to 
regulate the flow of traffic from sender to receiver 
– TCP uses the following variation of sliding window: 
– no NACKs (Negative ACKnowledgement) 
– only cumulative ACKs 
• Example: 
Assume: Sender sends two segments with “1..1500” and 
“1501..3000”, but receiver only gets the second segment. 
In this case, the receiver cannot acknowledge the second 
packet. It can only send AckNo=1
11 
TCP header fields 
• Header Length ( 4bits): 
– Length of header in 32-bit words 
– Note that TCP header has variable length (with minimum 
20 bytes)
12 
TCP header fields 
• Flag bits: 
– URG: Urgent pointer is valid 
– If the bit is set, the following bytes contain an urgent message in 
the range: 
SeqNo <= urgent message <= SeqNo+urgent pointer 
– ACK: Acknowledgement Number is valid 
– PSH: PUSH Flag 
– Notification from sender to the receiver that the receiver should 
pass all data that it has to the application. 
– Normally set by sender when the sender’s buffer is empty
13 
TCP header fields 
• Flag bits: 
– RST: Reset the connection 
– The flag causes the receiver to reset the connection 
– Receiver of a RST terminates the connection and indicates 
higher layer application about the reset 
– SYN: Synchronize sequence numbers 
– Sent in the first packet when initiating a connection 
– FIN: Sender is finished with sending 
– Used for closing a connection 
– Both sides of a connection must send a FIN
14 
TCP header fields 
• Window Size: 
– Each side of the connection advertises the window size 
– Window size is the maximum number of bytes that a 
receiver can accept. 
– Maximum window size is 216-1= 65535 bytes 
• TCP Checksum: 
– TCP checksum covers over both TCP header and TCP 
data (also covers some parts of the IP header) 
• Urgent Pointer: 
– Only valid if URG flag is set
15 
TCP header fields 
• Options: 
End of 
Options kind=0 
1 byte 
NOP 
(no operation) kind=1 
1 byte 
Maximum 
Segment Size kind=2 
1 byte 
len=4 
1 byte 
maximum 
segment size 
2 bytes 
Window Scale 
Factor kind=3 
1 byte 
len=3 
1 byte 
shift count 
1 byte 
Timestamp kind=8 
1 byte 
len=10 
1 byte 
timestamp value 
4 bytes 
timestamp echo reply 
4 bytes

More Related Content

What's hot

Tcp header/IP Header/Authentication header
Tcp header/IP Header/Authentication headerTcp header/IP Header/Authentication header
Tcp header/IP Header/Authentication headerFaizan Shaikh
 
Chapter 01 - Overview
Chapter 01 - OverviewChapter 01 - Overview
Chapter 01 - Overviewphanleson
 
Tcp Analysis Through wiresshark
Tcp Analysis Through wiressharkTcp Analysis Through wiresshark
Tcp Analysis Through wiressharkSuman_kumari1
 
Tcp Immediate Data Transfer
Tcp Immediate Data TransferTcp Immediate Data Transfer
Tcp Immediate Data TransferRam Dutt Shukla
 
Computer network (Lecture 2)
Computer network (Lecture 2)Computer network (Lecture 2)
Computer network (Lecture 2)Vishwajit Nandi
 
Lecture 5
Lecture 5Lecture 5
Lecture 5ntpc08
 
Basic Programming concepts - Programming with C++
Basic Programming concepts - Programming with C++Basic Programming concepts - Programming with C++
Basic Programming concepts - Programming with C++Mohamed El Desouki
 
Vulnerabilities in IP Protocols
Vulnerabilities in IP ProtocolsVulnerabilities in IP Protocols
Vulnerabilities in IP Protocolsbabak danyal
 
08 module interconnecting cisco router
08 module interconnecting cisco router08 module interconnecting cisco router
08 module interconnecting cisco routerAsif
 
Chap2. ipv4-arp-icmp
Chap2. ipv4-arp-icmpChap2. ipv4-arp-icmp
Chap2. ipv4-arp-icmp東原 李
 

What's hot (20)

Tcp header/IP Header/Authentication header
Tcp header/IP Header/Authentication headerTcp header/IP Header/Authentication header
Tcp header/IP Header/Authentication header
 
Chapter 01 - Overview
Chapter 01 - OverviewChapter 01 - Overview
Chapter 01 - Overview
 
Chap 12 tcp
Chap 12 tcpChap 12 tcp
Chap 12 tcp
 
Tcp Analysis Through wiresshark
Tcp Analysis Through wiressharkTcp Analysis Through wiresshark
Tcp Analysis Through wiresshark
 
Tcp Immediate Data Transfer
Tcp Immediate Data TransferTcp Immediate Data Transfer
Tcp Immediate Data Transfer
 
Intake 38 11
Intake 38 11Intake 38 11
Intake 38 11
 
Framing
FramingFraming
Framing
 
Computer network (Lecture 2)
Computer network (Lecture 2)Computer network (Lecture 2)
Computer network (Lecture 2)
 
Lecture 5
Lecture 5Lecture 5
Lecture 5
 
Basic Programming concepts - Programming with C++
Basic Programming concepts - Programming with C++Basic Programming concepts - Programming with C++
Basic Programming concepts - Programming with C++
 
Week5 lec3-bscs1
Week5 lec3-bscs1Week5 lec3-bscs1
Week5 lec3-bscs1
 
Vulnerabilities in IP Protocols
Vulnerabilities in IP ProtocolsVulnerabilities in IP Protocols
Vulnerabilities in IP Protocols
 
Part 6 : Internet applications
Part 6 : Internet applicationsPart 6 : Internet applications
Part 6 : Internet applications
 
Working of TCP
Working of TCP Working of TCP
Working of TCP
 
Np unit iii
Np unit iiiNp unit iii
Np unit iii
 
08 module interconnecting cisco router
08 module interconnecting cisco router08 module interconnecting cisco router
08 module interconnecting cisco router
 
TCP/IP
TCP/IPTCP/IP
TCP/IP
 
Ftp tftp
Ftp tftpFtp tftp
Ftp tftp
 
Chap2. ipv4-arp-icmp
Chap2. ipv4-arp-icmpChap2. ipv4-arp-icmp
Chap2. ipv4-arp-icmp
 
Meeting 6 : ftp
Meeting 6 : ftpMeeting 6 : ftp
Meeting 6 : ftp
 

Similar to TCP Protocol Overview

Transmission control protocol ...............................
Transmission control protocol ...............................Transmission control protocol ...............................
Transmission control protocol ...............................SwatiHans10
 
tcp-ippresentation-150614172243-lva1-app6892.pptx
tcp-ippresentation-150614172243-lva1-app6892.pptxtcp-ippresentation-150614172243-lva1-app6892.pptx
tcp-ippresentation-150614172243-lva1-app6892.pptxAlphaKoiSylvester
 
13_TCP_Attack.pptx
13_TCP_Attack.pptx13_TCP_Attack.pptx
13_TCP_Attack.pptxAlmaOraevi
 
TCP - IP Presentation
TCP - IP PresentationTCP - IP Presentation
TCP - IP PresentationHarish Chand
 
Networking essentials lect3
Networking essentials lect3Networking essentials lect3
Networking essentials lect3Roman Brovko
 
TCP_NISCHAYBAHL.pptx
TCP_NISCHAYBAHL.pptxTCP_NISCHAYBAHL.pptx
TCP_NISCHAYBAHL.pptxNischayBahl1
 
5-LEC- 5.pptxTransport Layer. Transport Layer Protocols
5-LEC- 5.pptxTransport Layer.  Transport Layer Protocols5-LEC- 5.pptxTransport Layer.  Transport Layer Protocols
5-LEC- 5.pptxTransport Layer. Transport Layer ProtocolsZahouAmel1
 
Transport protocols
Transport protocolsTransport protocols
Transport protocolsOnline
 
1.1.2 - Concept of Network and TCP_IP Model (2).pptx
1.1.2 - Concept of Network and TCP_IP Model (2).pptx1.1.2 - Concept of Network and TCP_IP Model (2).pptx
1.1.2 - Concept of Network and TCP_IP Model (2).pptxVINAYTANWAR18
 
Transport Layer in Computer Networks (TCP / UDP / SCTP)
Transport Layer in Computer Networks (TCP / UDP / SCTP)Transport Layer in Computer Networks (TCP / UDP / SCTP)
Transport Layer in Computer Networks (TCP / UDP / SCTP)Hamidreza Bolhasani
 
Unit-4 (1).pptx
Unit-4 (1).pptxUnit-4 (1).pptx
Unit-4 (1).pptxpoonamsngr
 
CCNA (R & S) Module 01 - Introduction to Networks - Chapter 9
CCNA (R & S) Module 01 - Introduction to Networks - Chapter 9CCNA (R & S) Module 01 - Introduction to Networks - Chapter 9
CCNA (R & S) Module 01 - Introduction to Networks - Chapter 9Waqas Ahmed Nawaz
 
TCP & UDP ( Transmission Control Protocol and User Datagram Protocol)
TCP & UDP ( Transmission Control Protocol and User Datagram Protocol)TCP & UDP ( Transmission Control Protocol and User Datagram Protocol)
TCP & UDP ( Transmission Control Protocol and User Datagram Protocol)Kruti Niranjan
 

Similar to TCP Protocol Overview (20)

Transmission control protocol ...............................
Transmission control protocol ...............................Transmission control protocol ...............................
Transmission control protocol ...............................
 
tcp-ippresentation-150614172243-lva1-app6892.pptx
tcp-ippresentation-150614172243-lva1-app6892.pptxtcp-ippresentation-150614172243-lva1-app6892.pptx
tcp-ippresentation-150614172243-lva1-app6892.pptx
 
13_TCP_Attack.pptx
13_TCP_Attack.pptx13_TCP_Attack.pptx
13_TCP_Attack.pptx
 
TCP - IP Presentation
TCP - IP PresentationTCP - IP Presentation
TCP - IP Presentation
 
Networking essentials lect3
Networking essentials lect3Networking essentials lect3
Networking essentials lect3
 
TCP_NISCHAYBAHL.pptx
TCP_NISCHAYBAHL.pptxTCP_NISCHAYBAHL.pptx
TCP_NISCHAYBAHL.pptx
 
Osi model
Osi modelOsi model
Osi model
 
5-LEC- 5.pptxTransport Layer. Transport Layer Protocols
5-LEC- 5.pptxTransport Layer.  Transport Layer Protocols5-LEC- 5.pptxTransport Layer.  Transport Layer Protocols
5-LEC- 5.pptxTransport Layer. Transport Layer Protocols
 
Transport protocols
Transport protocolsTransport protocols
Transport protocols
 
lecturer3.pptx
lecturer3.pptxlecturer3.pptx
lecturer3.pptx
 
1.1.2 - Concept of Network and TCP_IP Model (2).pptx
1.1.2 - Concept of Network and TCP_IP Model (2).pptx1.1.2 - Concept of Network and TCP_IP Model (2).pptx
1.1.2 - Concept of Network and TCP_IP Model (2).pptx
 
Transport Layer in Computer Networks (TCP / UDP / SCTP)
Transport Layer in Computer Networks (TCP / UDP / SCTP)Transport Layer in Computer Networks (TCP / UDP / SCTP)
Transport Layer in Computer Networks (TCP / UDP / SCTP)
 
Lecture set 7
Lecture set 7Lecture set 7
Lecture set 7
 
Unit-4 (1).pptx
Unit-4 (1).pptxUnit-4 (1).pptx
Unit-4 (1).pptx
 
User Datagram Protocol
User Datagram ProtocolUser Datagram Protocol
User Datagram Protocol
 
4. tcp header.ppt
4. tcp header.ppt4. tcp header.ppt
4. tcp header.ppt
 
TCP /IP
TCP /IPTCP /IP
TCP /IP
 
CCNA (R & S) Module 01 - Introduction to Networks - Chapter 9
CCNA (R & S) Module 01 - Introduction to Networks - Chapter 9CCNA (R & S) Module 01 - Introduction to Networks - Chapter 9
CCNA (R & S) Module 01 - Introduction to Networks - Chapter 9
 
Mod4
Mod4Mod4
Mod4
 
TCP & UDP ( Transmission Control Protocol and User Datagram Protocol)
TCP & UDP ( Transmission Control Protocol and User Datagram Protocol)TCP & UDP ( Transmission Control Protocol and User Datagram Protocol)
TCP & UDP ( Transmission Control Protocol and User Datagram Protocol)
 

More from Amit Ranjan

Sanjeev ghai irs
Sanjeev ghai irsSanjeev ghai irs
Sanjeev ghai irsAmit Ranjan
 
Eschol tech solutions a
Eschol tech solutions aEschol tech solutions a
Eschol tech solutions aAmit Ranjan
 
Olumide adeola pidan c
Olumide adeola pidan cOlumide adeola pidan c
Olumide adeola pidan cAmit Ranjan
 
Olumide adeola pidan b
Olumide adeola pidan bOlumide adeola pidan b
Olumide adeola pidan bAmit Ranjan
 
Olumide adeola pidan a
Olumide adeola pidan aOlumide adeola pidan a
Olumide adeola pidan aAmit Ranjan
 
Sanjeev ghai irs
Sanjeev ghai irsSanjeev ghai irs
Sanjeev ghai irsAmit Ranjan
 

More from Amit Ranjan (14)

Purva season b
Purva season bPurva season b
Purva season b
 
Purva season a
Purva season aPurva season a
Purva season a
 
Sanjeev ghai irs
Sanjeev ghai irsSanjeev ghai irs
Sanjeev ghai irs
 
Sanjeev ghei
Sanjeev gheiSanjeev ghei
Sanjeev ghei
 
Eschol tech solutions a
Eschol tech solutions aEschol tech solutions a
Eschol tech solutions a
 
Olumide pidan c
Olumide pidan cOlumide pidan c
Olumide pidan c
 
Olumide pidan a
Olumide pidan aOlumide pidan a
Olumide pidan a
 
Olumide adeola pidan c
Olumide adeola pidan cOlumide adeola pidan c
Olumide adeola pidan c
 
Olumide adeola pidan b
Olumide adeola pidan bOlumide adeola pidan b
Olumide adeola pidan b
 
Olumide adeola pidan a
Olumide adeola pidan aOlumide adeola pidan a
Olumide adeola pidan a
 
Sanjeev ghei
Sanjeev ghei Sanjeev ghei
Sanjeev ghei
 
Sanjeev ghai irs
Sanjeev ghai irsSanjeev ghai irs
Sanjeev ghai irs
 
Amrapali
AmrapaliAmrapali
Amrapali
 
Amrapali Group
Amrapali GroupAmrapali Group
Amrapali Group
 

Recently uploaded

Deconstructing Gendered Language; Feminist World-Making 2024
Deconstructing Gendered Language; Feminist World-Making 2024Deconstructing Gendered Language; Feminist World-Making 2024
Deconstructing Gendered Language; Feminist World-Making 2024samlnance
 
The First Date by Daniel Johnson (Inspired By True Events)
The First Date by Daniel Johnson (Inspired By True Events)The First Date by Daniel Johnson (Inspired By True Events)
The First Date by Daniel Johnson (Inspired By True Events)thephillipta
 
Young⚡Call Girls in Uttam Nagar Delhi >༒9667401043 Escort Service
Young⚡Call Girls in Uttam Nagar Delhi >༒9667401043 Escort ServiceYoung⚡Call Girls in Uttam Nagar Delhi >༒9667401043 Escort Service
Young⚡Call Girls in Uttam Nagar Delhi >༒9667401043 Escort Servicesonnydelhi1992
 
Lucknow 💋 Russian Call Girls Lucknow | Whatsapp No 8923113531 VIP Escorts Ser...
Lucknow 💋 Russian Call Girls Lucknow | Whatsapp No 8923113531 VIP Escorts Ser...Lucknow 💋 Russian Call Girls Lucknow | Whatsapp No 8923113531 VIP Escorts Ser...
Lucknow 💋 Russian Call Girls Lucknow | Whatsapp No 8923113531 VIP Escorts Ser...anilsa9823
 
Indira Nagar Lucknow #Call Girls Lucknow ₹7.5k Pick Up & Drop With Cash Payme...
Indira Nagar Lucknow #Call Girls Lucknow ₹7.5k Pick Up & Drop With Cash Payme...Indira Nagar Lucknow #Call Girls Lucknow ₹7.5k Pick Up & Drop With Cash Payme...
Indira Nagar Lucknow #Call Girls Lucknow ₹7.5k Pick Up & Drop With Cash Payme...akbard9823
 
Lucknow 💋 Call Girls in Lucknow | Service-oriented sexy call girls 8923113531...
Lucknow 💋 Call Girls in Lucknow | Service-oriented sexy call girls 8923113531...Lucknow 💋 Call Girls in Lucknow | Service-oriented sexy call girls 8923113531...
Lucknow 💋 Call Girls in Lucknow | Service-oriented sexy call girls 8923113531...anilsa9823
 
Call Girl Service In Dubai #$# O56521286O #$# Dubai Call Girls
Call Girl Service In Dubai #$# O56521286O #$# Dubai Call GirlsCall Girl Service In Dubai #$# O56521286O #$# Dubai Call Girls
Call Girl Service In Dubai #$# O56521286O #$# Dubai Call Girlsparisharma5056
 
Jeremy Casson - Top Tips for Pottery Wheel Throwing
Jeremy Casson - Top Tips for Pottery Wheel ThrowingJeremy Casson - Top Tips for Pottery Wheel Throwing
Jeremy Casson - Top Tips for Pottery Wheel ThrowingJeremy Casson
 
exhuma plot and synopsis from the exhuma movie.pptx
exhuma plot and synopsis from the exhuma movie.pptxexhuma plot and synopsis from the exhuma movie.pptx
exhuma plot and synopsis from the exhuma movie.pptxKurikulumPenilaian
 
Young⚡Call Girls in Lajpat Nagar Delhi >༒9667401043 Escort Service
Young⚡Call Girls in Lajpat Nagar Delhi >༒9667401043 Escort ServiceYoung⚡Call Girls in Lajpat Nagar Delhi >༒9667401043 Escort Service
Young⚡Call Girls in Lajpat Nagar Delhi >༒9667401043 Escort Servicesonnydelhi1992
 
Lucknow 💋 Escorts Service Lucknow Phone No 8923113531 Elite Escort Service Av...
Lucknow 💋 Escorts Service Lucknow Phone No 8923113531 Elite Escort Service Av...Lucknow 💋 Escorts Service Lucknow Phone No 8923113531 Elite Escort Service Av...
Lucknow 💋 Escorts Service Lucknow Phone No 8923113531 Elite Escort Service Av...anilsa9823
 
Lucknow 💋 Call Girls in Lucknow ₹7.5k Pick Up & Drop With Cash Payment 892311...
Lucknow 💋 Call Girls in Lucknow ₹7.5k Pick Up & Drop With Cash Payment 892311...Lucknow 💋 Call Girls in Lucknow ₹7.5k Pick Up & Drop With Cash Payment 892311...
Lucknow 💋 Call Girls in Lucknow ₹7.5k Pick Up & Drop With Cash Payment 892311...anilsa9823
 
Lucknow 💋 Call Girl in Lucknow Phone No 8923113531 Elite Escort Service Avail...
Lucknow 💋 Call Girl in Lucknow Phone No 8923113531 Elite Escort Service Avail...Lucknow 💋 Call Girl in Lucknow Phone No 8923113531 Elite Escort Service Avail...
Lucknow 💋 Call Girl in Lucknow Phone No 8923113531 Elite Escort Service Avail...anilsa9823
 
Turn Lock Take Key Storyboard Daniel Johnson
Turn Lock Take Key Storyboard Daniel JohnsonTurn Lock Take Key Storyboard Daniel Johnson
Turn Lock Take Key Storyboard Daniel Johnsonthephillipta
 
Best Call girls in Lucknow - 9548086042 - with hotel room
Best Call girls in Lucknow - 9548086042 - with hotel roomBest Call girls in Lucknow - 9548086042 - with hotel room
Best Call girls in Lucknow - 9548086042 - with hotel roomdiscovermytutordmt
 
Bridge Fight Board by Daniel Johnson dtjohnsonart.com
Bridge Fight Board by Daniel Johnson dtjohnsonart.comBridge Fight Board by Daniel Johnson dtjohnsonart.com
Bridge Fight Board by Daniel Johnson dtjohnsonart.comthephillipta
 
Islamabad Call Girls # 03091665556 # Call Girls in Islamabad | Islamabad Escorts
Islamabad Call Girls # 03091665556 # Call Girls in Islamabad | Islamabad EscortsIslamabad Call Girls # 03091665556 # Call Girls in Islamabad | Islamabad Escorts
Islamabad Call Girls # 03091665556 # Call Girls in Islamabad | Islamabad Escortswdefrd
 
AaliyahBell_themist_v01.pdf .
AaliyahBell_themist_v01.pdf             .AaliyahBell_themist_v01.pdf             .
AaliyahBell_themist_v01.pdf .AaliyahB2
 

Recently uploaded (20)

Deconstructing Gendered Language; Feminist World-Making 2024
Deconstructing Gendered Language; Feminist World-Making 2024Deconstructing Gendered Language; Feminist World-Making 2024
Deconstructing Gendered Language; Feminist World-Making 2024
 
The First Date by Daniel Johnson (Inspired By True Events)
The First Date by Daniel Johnson (Inspired By True Events)The First Date by Daniel Johnson (Inspired By True Events)
The First Date by Daniel Johnson (Inspired By True Events)
 
Young⚡Call Girls in Uttam Nagar Delhi >༒9667401043 Escort Service
Young⚡Call Girls in Uttam Nagar Delhi >༒9667401043 Escort ServiceYoung⚡Call Girls in Uttam Nagar Delhi >༒9667401043 Escort Service
Young⚡Call Girls in Uttam Nagar Delhi >༒9667401043 Escort Service
 
Lucknow 💋 Russian Call Girls Lucknow | Whatsapp No 8923113531 VIP Escorts Ser...
Lucknow 💋 Russian Call Girls Lucknow | Whatsapp No 8923113531 VIP Escorts Ser...Lucknow 💋 Russian Call Girls Lucknow | Whatsapp No 8923113531 VIP Escorts Ser...
Lucknow 💋 Russian Call Girls Lucknow | Whatsapp No 8923113531 VIP Escorts Ser...
 
Pakistani Deira Call Girls # 00971589162217 # Pakistani Call Girls In Deira D...
Pakistani Deira Call Girls # 00971589162217 # Pakistani Call Girls In Deira D...Pakistani Deira Call Girls # 00971589162217 # Pakistani Call Girls In Deira D...
Pakistani Deira Call Girls # 00971589162217 # Pakistani Call Girls In Deira D...
 
Indira Nagar Lucknow #Call Girls Lucknow ₹7.5k Pick Up & Drop With Cash Payme...
Indira Nagar Lucknow #Call Girls Lucknow ₹7.5k Pick Up & Drop With Cash Payme...Indira Nagar Lucknow #Call Girls Lucknow ₹7.5k Pick Up & Drop With Cash Payme...
Indira Nagar Lucknow #Call Girls Lucknow ₹7.5k Pick Up & Drop With Cash Payme...
 
Lucknow 💋 Call Girls in Lucknow | Service-oriented sexy call girls 8923113531...
Lucknow 💋 Call Girls in Lucknow | Service-oriented sexy call girls 8923113531...Lucknow 💋 Call Girls in Lucknow | Service-oriented sexy call girls 8923113531...
Lucknow 💋 Call Girls in Lucknow | Service-oriented sexy call girls 8923113531...
 
Call Girl Service In Dubai #$# O56521286O #$# Dubai Call Girls
Call Girl Service In Dubai #$# O56521286O #$# Dubai Call GirlsCall Girl Service In Dubai #$# O56521286O #$# Dubai Call Girls
Call Girl Service In Dubai #$# O56521286O #$# Dubai Call Girls
 
Jeremy Casson - Top Tips for Pottery Wheel Throwing
Jeremy Casson - Top Tips for Pottery Wheel ThrowingJeremy Casson - Top Tips for Pottery Wheel Throwing
Jeremy Casson - Top Tips for Pottery Wheel Throwing
 
exhuma plot and synopsis from the exhuma movie.pptx
exhuma plot and synopsis from the exhuma movie.pptxexhuma plot and synopsis from the exhuma movie.pptx
exhuma plot and synopsis from the exhuma movie.pptx
 
Young⚡Call Girls in Lajpat Nagar Delhi >༒9667401043 Escort Service
Young⚡Call Girls in Lajpat Nagar Delhi >༒9667401043 Escort ServiceYoung⚡Call Girls in Lajpat Nagar Delhi >༒9667401043 Escort Service
Young⚡Call Girls in Lajpat Nagar Delhi >༒9667401043 Escort Service
 
Lucknow 💋 Escorts Service Lucknow Phone No 8923113531 Elite Escort Service Av...
Lucknow 💋 Escorts Service Lucknow Phone No 8923113531 Elite Escort Service Av...Lucknow 💋 Escorts Service Lucknow Phone No 8923113531 Elite Escort Service Av...
Lucknow 💋 Escorts Service Lucknow Phone No 8923113531 Elite Escort Service Av...
 
Lucknow 💋 Call Girls in Lucknow ₹7.5k Pick Up & Drop With Cash Payment 892311...
Lucknow 💋 Call Girls in Lucknow ₹7.5k Pick Up & Drop With Cash Payment 892311...Lucknow 💋 Call Girls in Lucknow ₹7.5k Pick Up & Drop With Cash Payment 892311...
Lucknow 💋 Call Girls in Lucknow ₹7.5k Pick Up & Drop With Cash Payment 892311...
 
Lucknow 💋 Call Girl in Lucknow Phone No 8923113531 Elite Escort Service Avail...
Lucknow 💋 Call Girl in Lucknow Phone No 8923113531 Elite Escort Service Avail...Lucknow 💋 Call Girl in Lucknow Phone No 8923113531 Elite Escort Service Avail...
Lucknow 💋 Call Girl in Lucknow Phone No 8923113531 Elite Escort Service Avail...
 
Turn Lock Take Key Storyboard Daniel Johnson
Turn Lock Take Key Storyboard Daniel JohnsonTurn Lock Take Key Storyboard Daniel Johnson
Turn Lock Take Key Storyboard Daniel Johnson
 
Best Call girls in Lucknow - 9548086042 - with hotel room
Best Call girls in Lucknow - 9548086042 - with hotel roomBest Call girls in Lucknow - 9548086042 - with hotel room
Best Call girls in Lucknow - 9548086042 - with hotel room
 
RAJKOT CALL GIRL 76313*77252 CALL GIRL IN RAJKOT
RAJKOT CALL GIRL 76313*77252 CALL GIRL IN RAJKOTRAJKOT CALL GIRL 76313*77252 CALL GIRL IN RAJKOT
RAJKOT CALL GIRL 76313*77252 CALL GIRL IN RAJKOT
 
Bridge Fight Board by Daniel Johnson dtjohnsonart.com
Bridge Fight Board by Daniel Johnson dtjohnsonart.comBridge Fight Board by Daniel Johnson dtjohnsonart.com
Bridge Fight Board by Daniel Johnson dtjohnsonart.com
 
Islamabad Call Girls # 03091665556 # Call Girls in Islamabad | Islamabad Escorts
Islamabad Call Girls # 03091665556 # Call Girls in Islamabad | Islamabad EscortsIslamabad Call Girls # 03091665556 # Call Girls in Islamabad | Islamabad Escorts
Islamabad Call Girls # 03091665556 # Call Girls in Islamabad | Islamabad Escorts
 
AaliyahBell_themist_v01.pdf .
AaliyahBell_themist_v01.pdf             .AaliyahBell_themist_v01.pdf             .
AaliyahBell_themist_v01.pdf .
 

TCP Protocol Overview

  • 1. 1 My First PPT This Is my first ppt.
  • 2. 2 Overview TCP = Transmission Control Protocol • Connection-oriented protocol • Provides a reliable unicast end-to-end byte stream over an unreliable internetwork. TCP IP Internetwork Byte Stream Byte Stream TCP
  • 3. 3 Connection-Oriented • Before any data transfer, TCP establishes a connection: • One TCP entity is waiting for a connection (“server”) • The other TCP entity (“client”) contacts the server • The actual procedure for setting up connections is more complex. • Each connection is CLIENT SERVER full duplex waiting for connection request Request a connection Accept a connection Disconnect Data Transer
  • 4. 4 Reliable • Byte stream is broken up into chunks which are called seg-ments • Receiver sends acknowledgements (ACKs) for segments • TCP maintains a timer. If an ACK is not received in time, the segment is retransmitted •Detecting errors: • TCP has checksums for header and data. Segments with invalid checksums are discarded • Each byte that is transmitted has a sequence number
  • 5. 5 Byte Stream Service • To the lower layers, TCP handles data in blocks, the segments. • To the higher layers TCP handles data as a sequence of bytes and does not identify boundaries between bytes • So: Higher layers do not know about the beginning and end of segments ! TCP Application 1. write 100 bytes 2. write 20 bytes queue of bytes to be transmitted TCP queue of bytes that have been received Application 1. read 40 bytes 2. read 40 bytes 3. read 40 bytes Segments
  • 6. 6 TCP Format • TCP segments have a 20 byte header with >= 0 bytes of data. IP header TCP header TCP data Sequence number (32 bits) TCP checksum urgent pointer DATA 20 bytes 20 bytes 0 15 16 31 Source Port Number Destination Port Number Acknowledgement number (32 bits) header window size length 0 Flags Options (if any) 20 bytes
  • 7. 7 TCP header fields • Port Number: • A port number identifies the endpoint of a connection. • A pair <IP address, port number> identifies one endpoint of a connection. • Two pairs <client IP address, server port number> and <server IP address, server port number> identify a TCP connection. Applications Ports: 23 80 104 TCP IP Applications 7 80 16 Ports: TCP IP
  • 8. 8 TCP header fields • Sequence Number (SeqNo): – Sequence number is 32 bits long. – So the range of SeqNo is 0 <= SeqNo <= 232 -1 » 4.3 Gbyte – Each sequence number identifies a byte in the byte stream – Initial Sequence Number (ISN) of a connection is set during connection establishment Q: What are possible requirements for ISN ?
  • 9. 9 TCP header fields • Acknowledgement Number (AckNo): – Acknowledgements are piggybacked, I.e a segment from A -> B can contain an acknowledgement for a data sent in the B -> A direction Q: Why is piggybacking good ? – A hosts uses the AckNo field to send acknowledgements. (If a host sends an AckNo in a segment it sets the “ACK flag”) – The AckNo contains the next SeqNo that a hosts wants to receive Example: The acknowledgement for a segment with sequence numbers 0-1500 is AckNo=1501
  • 10. 10 TCP header fields • Acknowledge Number (cont’d) – TCP uses the sliding window flow protocol (see CS 457) to regulate the flow of traffic from sender to receiver – TCP uses the following variation of sliding window: – no NACKs (Negative ACKnowledgement) – only cumulative ACKs • Example: Assume: Sender sends two segments with “1..1500” and “1501..3000”, but receiver only gets the second segment. In this case, the receiver cannot acknowledge the second packet. It can only send AckNo=1
  • 11. 11 TCP header fields • Header Length ( 4bits): – Length of header in 32-bit words – Note that TCP header has variable length (with minimum 20 bytes)
  • 12. 12 TCP header fields • Flag bits: – URG: Urgent pointer is valid – If the bit is set, the following bytes contain an urgent message in the range: SeqNo <= urgent message <= SeqNo+urgent pointer – ACK: Acknowledgement Number is valid – PSH: PUSH Flag – Notification from sender to the receiver that the receiver should pass all data that it has to the application. – Normally set by sender when the sender’s buffer is empty
  • 13. 13 TCP header fields • Flag bits: – RST: Reset the connection – The flag causes the receiver to reset the connection – Receiver of a RST terminates the connection and indicates higher layer application about the reset – SYN: Synchronize sequence numbers – Sent in the first packet when initiating a connection – FIN: Sender is finished with sending – Used for closing a connection – Both sides of a connection must send a FIN
  • 14. 14 TCP header fields • Window Size: – Each side of the connection advertises the window size – Window size is the maximum number of bytes that a receiver can accept. – Maximum window size is 216-1= 65535 bytes • TCP Checksum: – TCP checksum covers over both TCP header and TCP data (also covers some parts of the IP header) • Urgent Pointer: – Only valid if URG flag is set
  • 15. 15 TCP header fields • Options: End of Options kind=0 1 byte NOP (no operation) kind=1 1 byte Maximum Segment Size kind=2 1 byte len=4 1 byte maximum segment size 2 bytes Window Scale Factor kind=3 1 byte len=3 1 byte shift count 1 byte Timestamp kind=8 1 byte len=10 1 byte timestamp value 4 bytes timestamp echo reply 4 bytes