SlideShare une entreprise Scribd logo
1  sur  16
1




Introduction to TCP/IP
2
       OSI and Protocol Stack                             OSI: Open Systems Interconnect



        OSI Model             TCP/IP Hierarchy               Protocols

           7th
    Application Layer

           6th
    Presentation Layer       Application Layer

           5th
      Session Layer

           4th
                              Transport Layer
     Transport Layer

          3rd
                              Network Layer
     Network Layer

            2nd
        Link Layer
                                Link Layer
            1st
      Physical Layer


Link Layer             : includes device driver and network interface card
Network Layer          : handles the movement of packets, i.e. Routing
Transport Layer        : provides a reliable flow of data between two hosts
Application Layer      : handles the details of the particular application
3
      Packet Encapsulation
 The data is sent down the protocol stack
 Each layer adds to the data by prepending headers




                 22Bytes 20Bytes 20Bytes            4Bytes

                                 64 to 1500 Bytes
4
       Ethernet

      Computer <-> Computer communication on
       same network
      Each device has unique MAC address (48-bit)
       example: 00-C0-4F-48-47-93


Ethernet Packet:
 Preamble    Dest.    Source    Type         Data         CRC
            address   address

  8bytes    6bytes     6bytes   2bytes   64 - 1500bytes    4bytes


                                                    MAC: Media Access Control
5
     ARP : Address Resolution Protocol
   ARP provides mapping
    32bit IP address <-> 48bit MAC address
    128.97.89.153 <-> 00-C0-4F-48-47-93
   ARP cache
    maintains the recent mappings from IP addresses to MAC addresses


Protocol
4.  ARP request broadcast on Ethernet
5.  Destination host ARP layer responds
6
       IP: Internet Protocol
     Unreliable … connectionless datagram delivery service
     Responsible for routing of data through intermediate
      networks and computers


                              11   1111   1111   2222   2222   2233
IP header:    0123   4567   8901   2345   6789   0123   4567   8901



 1 :ICMP
 6 :TCP
 17 :UDP
7
    IP Routing
       Source                            Destination
     Application                         Application
      Transport         Router           Transport
      Network          Network            Network
        Link             Link               Link




   Routing Table
       Destination IP address
       IP address of a next-hop router
       Flags
       Network interface specification
8
       ICMP : Internet Control Message Protocol
   Used to report problems with delivery of IP Datagrams
    within an IP network
   Used by Ping, Tracerout commands
                                               ICMP Message
                                         20bytes   4bytes


                                            IP     ICMP     ICMP
                                          Header   Header    Data

Types and Codes
 Echo Request (type=8, code=0)         Type  Code Checksum

 Echo Reply(type=0, code=0)           1byte  1byte  2bytes

 Destination Unreachable(type=3, code=0)

 Time Exceeded(type=11, code=0) : Time-to-Live =0
9
        TCP : Transmission Control Protocol
           Connection-Oriented, Reliable, Byte Stream Service
Protocol
3.   Set up connection
4.   Transfer data
5.   Close connection

    TCP Header Format
    0   1   2    3   4   5   6   7   8    9    1    1   1   1     1      1     1   1   1   1   2   2    2    2   2   2   2   2   2   2   3   3
                                               0    1   2   3     4      5     6   7   8   9   0   1    2    3   4   5   6   7   8   9   0   1
                             Source Port                                                           Destination Port
                                                            Sequence Number
                                                        Acknowledgement Number
                     -   -   -   -
        Data                                                                                                Window
        Offset
                                                    
                             Checksum  
                                                                                                       Urgent Pointer
                                                                           
                                                 
                                                 
                                                    Options  (0
                                                      
                                                      
                                                          
                                                             
                                                                     
                                                                  to 
                                                                           
                                                                        10 
                                                                              Words of 32 Bits)
                                                                TCP Payload
 
10
TCP : State Diagram
11
              TCP : Connection


     Client             Host                     Client              Host

Send SYN seq=x                              Send FIN seq=x
                   Receive SYN segment                         Receive FIN segment
                   Send SYN seq=y,                             Send ACK x+1
                                         Receive ACK segment
Receive SYN        ACK x+1
+ACK segment                                                   Send FIN seq=y,
                                             Receive FIN       ACK x+1
                                             + ACK segment
Send ACK y+1
                                             Send ACK y+1
                   Receive ACK segment                         Receive ACK segment




    Establishing a TCP Connection              Closing a TCP Connection
12
        TCP : Data transfer

                  Client                           Host

            Send Packet 1
            Start Timer        Packet Lost   Packet should arrive
Timer                                        ACK should be sent
         ACK would normally
         Arrive at this time


             Time Expires

          Retransmit Packet1
Timer     Start Timer                        Receive Packet 1
                                             Send AXK 1
            Receive ACK 1
            Cancel Timer
13
    HTTP : Hyper Text Transfer Protocol

   Stateless Transaction Protocol
    Each transaction creates a new connection
Steps in Transaction
4.  Establish connection
5.  Request
      Method <URL> <CR>
7.  Response
      Response Code <Data> <CR>
9.  Close connection
14
    HTTP

   Common Request Methods
    GET, PUT, POST
   Response Categories
    Informational       :100
    Successful          :200
    Redirection         :300
    Client Error        :400 (eg. 404 Not found)
    Server Error        :500
15
       Example: Access www.ee.ucla.edu

Client                                                                 Server
            Http request
Appl        GET “http://www.ee.ucla.edu”<CR>                          Appl
            Http response
   HTTP     200 “” <CR> <html file in MIME format>                       HTTP
Transp                     Initiate connection (hdshk)                Transp
            Package data (add TCP header)
            send http request packet
   TCP                                          Assemble response        TCP
                                       (break into several packets)
                                       Send http response packets
                            Close connection (hdshk)
           send data to next hop
Net                                          Net                      Net
                                Relay data
   IP      ARP to provide                       IP                       IP
           IP/MAC translation
Link                                         Link                     Link
ethernet                                     ethernet                 ethernet
                                             Router(s)
16
     References
   “TCP/IP Illustrated, Volume 1 The Protocols “
    by W. Richard Stevens (http://yenigul.net/tcpip)

   “Internet Working with TCP/IP Volume 1”
    by Douglas E. Comer

   “Sams Teach Yourself TCP/IP in 24 Hours”
    by Joe Casad. Published by Sams. (
    http://www.informit.com)

Contenu connexe

Tendances

Razin Kabir (063452556)
Razin Kabir (063452556)Razin Kabir (063452556)
Razin Kabir (063452556)mashiur
 
Lecture1, TCP/IP
Lecture1, TCP/IPLecture1, TCP/IP
Lecture1, TCP/IPcsyuhk
 
IPv6 - Neighbour Discovery
IPv6 - Neighbour DiscoveryIPv6 - Neighbour Discovery
IPv6 - Neighbour DiscoveryHeba_a
 
Ipv6 cheat sheet
Ipv6 cheat sheetIpv6 cheat sheet
Ipv6 cheat sheetSwarup Hait
 
Internet control message protocol
Internet control message protocolInternet control message protocol
Internet control message protocolasimnawaz54
 
Ports & sockets
Ports  & sockets Ports  & sockets
Ports & sockets myrajendra
 
An Efficient Black Hole Attack Securing Mechanism in Ad Hoc On Demand Distanc...
An Efficient Black Hole Attack Securing Mechanism in Ad Hoc On Demand Distanc...An Efficient Black Hole Attack Securing Mechanism in Ad Hoc On Demand Distanc...
An Efficient Black Hole Attack Securing Mechanism in Ad Hoc On Demand Distanc...MINTUKAN RABHA
 
RARP, BOOTP, DHCP and PXE Protocols
RARP, BOOTP, DHCP and PXE ProtocolsRARP, BOOTP, DHCP and PXE Protocols
RARP, BOOTP, DHCP and PXE ProtocolsPeter R. Egli
 
Ix1000 Pro-MPEG/SMPTE 2022 FEC Inserter MPEG over IP
Ix1000 Pro-MPEG/SMPTE 2022 FEC Inserter MPEG over IPIx1000 Pro-MPEG/SMPTE 2022 FEC Inserter MPEG over IP
Ix1000 Pro-MPEG/SMPTE 2022 FEC Inserter MPEG over IPPath 1
 
Normas y Estándares
Normas y EstándaresNormas y Estándares
Normas y Estándaresguestc07d512a
 
Lec 12(Transport Layer)
Lec 12(Transport Layer)Lec 12(Transport Layer)
Lec 12(Transport Layer)maamir farooq
 
CS 6390 Project design report
CS 6390 Project design reportCS 6390 Project design report
CS 6390 Project design reportAbhishek Datta
 
CS 6390 Project design report
CS 6390 Project design reportCS 6390 Project design report
CS 6390 Project design reportRaj Gupta
 
Leonardo Nve Egea - Playing in a Satellite Environment 1.2
Leonardo Nve Egea - Playing in a Satellite Environment 1.2Leonardo Nve Egea - Playing in a Satellite Environment 1.2
Leonardo Nve Egea - Playing in a Satellite Environment 1.2Jim Geovedi
 

Tendances (20)

Mobile IP
Mobile IPMobile IP
Mobile IP
 
Razin Kabir (063452556)
Razin Kabir (063452556)Razin Kabir (063452556)
Razin Kabir (063452556)
 
Lecture1, TCP/IP
Lecture1, TCP/IPLecture1, TCP/IP
Lecture1, TCP/IP
 
IPv6 - Neighbour Discovery
IPv6 - Neighbour DiscoveryIPv6 - Neighbour Discovery
IPv6 - Neighbour Discovery
 
Ipv6 cheat sheet
Ipv6 cheat sheetIpv6 cheat sheet
Ipv6 cheat sheet
 
Network and DNS Vulnerabilities
Network and DNS VulnerabilitiesNetwork and DNS Vulnerabilities
Network and DNS Vulnerabilities
 
Osi model
Osi modelOsi model
Osi model
 
IPv6_Quick_Start_Guide
IPv6_Quick_Start_GuideIPv6_Quick_Start_Guide
IPv6_Quick_Start_Guide
 
Internet control message protocol
Internet control message protocolInternet control message protocol
Internet control message protocol
 
Ports & sockets
Ports  & sockets Ports  & sockets
Ports & sockets
 
An Efficient Black Hole Attack Securing Mechanism in Ad Hoc On Demand Distanc...
An Efficient Black Hole Attack Securing Mechanism in Ad Hoc On Demand Distanc...An Efficient Black Hole Attack Securing Mechanism in Ad Hoc On Demand Distanc...
An Efficient Black Hole Attack Securing Mechanism in Ad Hoc On Demand Distanc...
 
RARP, BOOTP, DHCP and PXE Protocols
RARP, BOOTP, DHCP and PXE ProtocolsRARP, BOOTP, DHCP and PXE Protocols
RARP, BOOTP, DHCP and PXE Protocols
 
Ix1000 Pro-MPEG/SMPTE 2022 FEC Inserter MPEG over IP
Ix1000 Pro-MPEG/SMPTE 2022 FEC Inserter MPEG over IPIx1000 Pro-MPEG/SMPTE 2022 FEC Inserter MPEG over IP
Ix1000 Pro-MPEG/SMPTE 2022 FEC Inserter MPEG over IP
 
Normas y Estándares
Normas y EstándaresNormas y Estándares
Normas y Estándares
 
Lec 12(Transport Layer)
Lec 12(Transport Layer)Lec 12(Transport Layer)
Lec 12(Transport Layer)
 
CS 6390 Project design report
CS 6390 Project design reportCS 6390 Project design report
CS 6390 Project design report
 
CS 6390 Project design report
CS 6390 Project design reportCS 6390 Project design report
CS 6390 Project design report
 
Part 12 : Local Area Networks
Part 12 : Local Area Networks Part 12 : Local Area Networks
Part 12 : Local Area Networks
 
Day-3 PowerPoint
Day-3 PowerPointDay-3 PowerPoint
Day-3 PowerPoint
 
Leonardo Nve Egea - Playing in a Satellite Environment 1.2
Leonardo Nve Egea - Playing in a Satellite Environment 1.2Leonardo Nve Egea - Playing in a Satellite Environment 1.2
Leonardo Nve Egea - Playing in a Satellite Environment 1.2
 

En vedette

Pcm pulse codemodulation-2
Pcm pulse codemodulation-2Pcm pulse codemodulation-2
Pcm pulse codemodulation-2Akshay Nagpurkar
 
Implementation of FSM Based Automatic Dispense Machine with Expiry Date Feat...
Implementation of FSM Based Automatic Dispense Machine with  Expiry Date Feat...Implementation of FSM Based Automatic Dispense Machine with  Expiry Date Feat...
Implementation of FSM Based Automatic Dispense Machine with Expiry Date Feat...IJMER
 
RIP - Routing Information Protocol
RIP - Routing Information ProtocolRIP - Routing Information Protocol
RIP - Routing Information Protocolselvakumar_b1985
 

En vedette (6)

Pcm pulse codemodulation-2
Pcm pulse codemodulation-2Pcm pulse codemodulation-2
Pcm pulse codemodulation-2
 
4.osi model
4.osi model4.osi model
4.osi model
 
1 multiplexing
1 multiplexing1 multiplexing
1 multiplexing
 
Rip ospf and bgp
Rip ospf and bgpRip ospf and bgp
Rip ospf and bgp
 
Implementation of FSM Based Automatic Dispense Machine with Expiry Date Feat...
Implementation of FSM Based Automatic Dispense Machine with  Expiry Date Feat...Implementation of FSM Based Automatic Dispense Machine with  Expiry Date Feat...
Implementation of FSM Based Automatic Dispense Machine with Expiry Date Feat...
 
RIP - Routing Information Protocol
RIP - Routing Information ProtocolRIP - Routing Information Protocol
RIP - Routing Information Protocol
 

Similaire à Tcp ip

Your app lives on the network - networking for web developers
Your app lives on the network - networking for web developersYour app lives on the network - networking for web developers
Your app lives on the network - networking for web developersWim Godden
 
CCNA Interview.pdf
CCNA Interview.pdfCCNA Interview.pdf
CCNA Interview.pdfhoang971
 
Clase 1 Direccionamiento IPv4.pdf
Clase 1 Direccionamiento IPv4.pdfClase 1 Direccionamiento IPv4.pdf
Clase 1 Direccionamiento IPv4.pdfFERNANDOBONILLA43
 
Lecture 5 internet-protocol_assignments
Lecture 5 internet-protocol_assignmentsLecture 5 internet-protocol_assignments
Lecture 5 internet-protocol_assignmentsSerious_SamSoul
 
Networking Fundamentals: Transport Protocols (TCP and UDP)
Networking Fundamentals: Transport Protocols (TCP and UDP)Networking Fundamentals: Transport Protocols (TCP and UDP)
Networking Fundamentals: Transport Protocols (TCP and UDP)Andriy Berestovskyy
 
Networking interview questions
Networking interview questionsNetworking interview questions
Networking interview questionszahadath
 
Efficient Telecommunication Infrastructure with Internet Telephony (VoIP)
Efficient Telecommunication Infrastructure with Internet Telephony (VoIP)Efficient Telecommunication Infrastructure with Internet Telephony (VoIP)
Efficient Telecommunication Infrastructure with Internet Telephony (VoIP)Thomas Siegers
 

Similaire à Tcp ip (20)

Your app lives on the network - networking for web developers
Your app lives on the network - networking for web developersYour app lives on the network - networking for web developers
Your app lives on the network - networking for web developers
 
Introduction to TCP/IP
Introduction to TCP/IPIntroduction to TCP/IP
Introduction to TCP/IP
 
CCNA Interview.pdf
CCNA Interview.pdfCCNA Interview.pdf
CCNA Interview.pdf
 
Multipath TCP
Multipath TCPMultipath TCP
Multipath TCP
 
Clase 1 Direccionamiento IPv4.pdf
Clase 1 Direccionamiento IPv4.pdfClase 1 Direccionamiento IPv4.pdf
Clase 1 Direccionamiento IPv4.pdf
 
Tcp
TcpTcp
Tcp
 
TCP Model
TCP ModelTCP Model
TCP Model
 
Lecture 5 internet-protocol_assignments
Lecture 5 internet-protocol_assignmentsLecture 5 internet-protocol_assignments
Lecture 5 internet-protocol_assignments
 
TCP/IP – Transmission Control Protocol/ Internet Protocol
TCP/IP – Transmission Control Protocol/ Internet ProtocolTCP/IP – Transmission Control Protocol/ Internet Protocol
TCP/IP – Transmission Control Protocol/ Internet Protocol
 
Polyraptor
PolyraptorPolyraptor
Polyraptor
 
Networking Fundamentals: Transport Protocols (TCP and UDP)
Networking Fundamentals: Transport Protocols (TCP and UDP)Networking Fundamentals: Transport Protocols (TCP and UDP)
Networking Fundamentals: Transport Protocols (TCP and UDP)
 
Internet Protocol
Internet ProtocolInternet Protocol
Internet Protocol
 
Internetworking
InternetworkingInternetworking
Internetworking
 
Networking interview questions
Networking interview questionsNetworking interview questions
Networking interview questions
 
TCP/IP Basics
TCP/IP BasicsTCP/IP Basics
TCP/IP Basics
 
Efficient Telecommunication Infrastructure with Internet Telephony (VoIP)
Efficient Telecommunication Infrastructure with Internet Telephony (VoIP)Efficient Telecommunication Infrastructure with Internet Telephony (VoIP)
Efficient Telecommunication Infrastructure with Internet Telephony (VoIP)
 
QSpiders - Upper layer-protocols
QSpiders - Upper layer-protocolsQSpiders - Upper layer-protocols
QSpiders - Upper layer-protocols
 
Clase 4. Routing IP.pdf
Clase 4. Routing IP.pdfClase 4. Routing IP.pdf
Clase 4. Routing IP.pdf
 
Chapter4 Network
Chapter4 NetworkChapter4 Network
Chapter4 Network
 
lecture-2-tcp-ip.ppt
lecture-2-tcp-ip.pptlecture-2-tcp-ip.ppt
lecture-2-tcp-ip.ppt
 

Plus de Akshay Nagpurkar (20)

L6 mecse ncc
L6 mecse nccL6 mecse ncc
L6 mecse ncc
 
1 ip address
1 ip address1 ip address
1 ip address
 
1.network topology
1.network topology1.network topology
1.network topology
 
1.lan man wan
1.lan man wan1.lan man wan
1.lan man wan
 
Dcunit4 transmission media
Dcunit4 transmission mediaDcunit4 transmission media
Dcunit4 transmission media
 
Ppl for students unit 4 and 5
Ppl for students unit 4 and 5Ppl for students unit 4 and 5
Ppl for students unit 4 and 5
 
Ppl for students unit 1,2 and 3
Ppl for students unit 1,2 and 3Ppl for students unit 1,2 and 3
Ppl for students unit 1,2 and 3
 
Ppl for students unit 4 and 5
Ppl for students unit 4 and 5Ppl for students unit 4 and 5
Ppl for students unit 4 and 5
 
234 rb trees2x2
234 rb trees2x2234 rb trees2x2
234 rb trees2x2
 
Ppl home assignment_unit4
Ppl home assignment_unit4Ppl home assignment_unit4
Ppl home assignment_unit4
 
Ppl home assignment_unit5
Ppl home assignment_unit5Ppl home assignment_unit5
Ppl home assignment_unit5
 
3 multiplexing-wdm
3 multiplexing-wdm3 multiplexing-wdm
3 multiplexing-wdm
 
2 multiplexing
2 multiplexing2 multiplexing
2 multiplexing
 
Modulation techniq of modem
Modulation techniq of modemModulation techniq of modem
Modulation techniq of modem
 
Ppl home assignment_unit3
Ppl home assignment_unit3Ppl home assignment_unit3
Ppl home assignment_unit3
 
Ppl home assignment_unit2
Ppl home assignment_unit2Ppl home assignment_unit2
Ppl home assignment_unit2
 
Ppl home assignment_unit1
Ppl home assignment_unit1Ppl home assignment_unit1
Ppl home assignment_unit1
 
Ppl syllabus new
Ppl syllabus newPpl syllabus new
Ppl syllabus new
 
Ppl for students unit 1,2 and 3
Ppl for students unit 1,2 and 3Ppl for students unit 1,2 and 3
Ppl for students unit 1,2 and 3
 
Pentium
PentiumPentium
Pentium
 

Dernier

Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slidevu2urc
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Igalia
 

Dernier (20)

Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 

Tcp ip

  • 2. 2 OSI and Protocol Stack OSI: Open Systems Interconnect OSI Model TCP/IP Hierarchy Protocols 7th Application Layer 6th Presentation Layer Application Layer 5th Session Layer 4th Transport Layer Transport Layer 3rd Network Layer Network Layer 2nd Link Layer Link Layer 1st Physical Layer Link Layer : includes device driver and network interface card Network Layer : handles the movement of packets, i.e. Routing Transport Layer : provides a reliable flow of data between two hosts Application Layer : handles the details of the particular application
  • 3. 3 Packet Encapsulation  The data is sent down the protocol stack  Each layer adds to the data by prepending headers 22Bytes 20Bytes 20Bytes 4Bytes 64 to 1500 Bytes
  • 4. 4 Ethernet  Computer <-> Computer communication on same network  Each device has unique MAC address (48-bit) example: 00-C0-4F-48-47-93 Ethernet Packet: Preamble Dest. Source Type Data CRC address address 8bytes 6bytes 6bytes 2bytes 64 - 1500bytes 4bytes MAC: Media Access Control
  • 5. 5 ARP : Address Resolution Protocol  ARP provides mapping 32bit IP address <-> 48bit MAC address 128.97.89.153 <-> 00-C0-4F-48-47-93  ARP cache maintains the recent mappings from IP addresses to MAC addresses Protocol 4. ARP request broadcast on Ethernet 5. Destination host ARP layer responds
  • 6. 6 IP: Internet Protocol  Unreliable … connectionless datagram delivery service  Responsible for routing of data through intermediate networks and computers 11 1111 1111 2222 2222 2233 IP header: 0123 4567 8901 2345 6789 0123 4567 8901 1 :ICMP 6 :TCP 17 :UDP
  • 7. 7 IP Routing Source Destination Application Application Transport Router Transport Network Network Network Link Link Link  Routing Table Destination IP address IP address of a next-hop router Flags Network interface specification
  • 8. 8 ICMP : Internet Control Message Protocol  Used to report problems with delivery of IP Datagrams within an IP network  Used by Ping, Tracerout commands ICMP Message 20bytes 4bytes IP ICMP ICMP Header Header Data Types and Codes  Echo Request (type=8, code=0) Type Code Checksum  Echo Reply(type=0, code=0) 1byte 1byte 2bytes  Destination Unreachable(type=3, code=0)  Time Exceeded(type=11, code=0) : Time-to-Live =0
  • 9. 9 TCP : Transmission Control Protocol  Connection-Oriented, Reliable, Byte Stream Service Protocol 3. Set up connection 4. Transfer data 5. Close connection TCP Header Format 0 1 2 3 4 5 6 7 8 9 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2 3 3 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 Source Port Destination Port Sequence Number Acknowledgement Number - - - - Data Window Offset                 Checksum                        Urgent Pointer                                        Options  (0                to     10  Words of 32 Bits) TCP Payload  
  • 10. 10 TCP : State Diagram
  • 11. 11 TCP : Connection Client Host Client Host Send SYN seq=x Send FIN seq=x Receive SYN segment Receive FIN segment Send SYN seq=y, Send ACK x+1 Receive ACK segment Receive SYN ACK x+1 +ACK segment Send FIN seq=y, Receive FIN ACK x+1 + ACK segment Send ACK y+1 Send ACK y+1 Receive ACK segment Receive ACK segment Establishing a TCP Connection Closing a TCP Connection
  • 12. 12 TCP : Data transfer Client Host Send Packet 1 Start Timer Packet Lost Packet should arrive Timer ACK should be sent ACK would normally Arrive at this time Time Expires Retransmit Packet1 Timer Start Timer Receive Packet 1 Send AXK 1 Receive ACK 1 Cancel Timer
  • 13. 13 HTTP : Hyper Text Transfer Protocol  Stateless Transaction Protocol Each transaction creates a new connection Steps in Transaction 4. Establish connection 5. Request Method <URL> <CR> 7. Response Response Code <Data> <CR> 9. Close connection
  • 14. 14 HTTP  Common Request Methods GET, PUT, POST  Response Categories Informational :100 Successful :200 Redirection :300 Client Error :400 (eg. 404 Not found) Server Error :500
  • 15. 15 Example: Access www.ee.ucla.edu Client Server Http request Appl GET “http://www.ee.ucla.edu”<CR> Appl Http response HTTP 200 “” <CR> <html file in MIME format> HTTP Transp Initiate connection (hdshk) Transp Package data (add TCP header) send http request packet TCP Assemble response TCP (break into several packets) Send http response packets Close connection (hdshk) send data to next hop Net Net Net Relay data IP ARP to provide IP IP IP/MAC translation Link Link Link ethernet ethernet ethernet Router(s)
  • 16. 16 References  “TCP/IP Illustrated, Volume 1 The Protocols “ by W. Richard Stevens (http://yenigul.net/tcpip)  “Internet Working with TCP/IP Volume 1” by Douglas E. Comer  “Sams Teach Yourself TCP/IP in 24 Hours” by Joe Casad. Published by Sams. ( http://www.informit.com)

Notes de l'éditeur

  1. Connection connection must be established before data is transferred Reliable Data guaranteed to eventually arrive with no errors