Full Transcript

TOPIC 05 TCP/IP Objectives Describe the purpose of a network protocol and the layers in the TCP/IP architecture Edition Guide to Networking Essentials, 7th Describe TCP/IP Applicati...

TOPIC 05 TCP/IP Objectives Describe the purpose of a network protocol and the layers in the TCP/IP architecture Edition Guide to Networking Essentials, 7th Describe TCP/IP Application-layer protocols Describe TCP/IP Transport-layer protocols Describe TCP/IP Internetwork-layer protocols Describe TCP/IP Network access-layer protocols 2 TCP/IP’s Layered Architecture Protocols are rules and procedures for communication and behavior ⚫ Computers must “speak” the same language and agree on the rules of communication Edition Guide to Networking Essentials, 7th When a set of protocols works cooperatively it is called a protocol suite (or “protocol stack”) The most common protocol stack is Transmission Control Protocol/Internet Protocol (TCP/IP) TCP/IP is composed of more than a dozen 3 protocols operating at different levels of the communication process Guide to Networking Essentials, 7th Edition 4 TCP/IP’s Layered Architecture TCP/IP’s Layered Architecture Example of how the layers work together: ⚫ You start your Web browser and your home Edition Guide to Networking Essentials, 7th page is http://www.cengage.com ⚫ The web browser formats a request for your home page by using the Application layer protocol HTTP ⚫ The request looks something like: ⚫ The unit of information the Application layer works with is simply called “data” 5 TCP/IP’s Layered Architecture Example continued: ⚫ The Application-layer protocol HTTP passes the Edition Guide to Networking Essentials, 7th request down to the Transport-layer protocol (TCP) ⚫ TCP adds a header to the request that looks like: ⚫ The unit of information the Transport layer works with is called a segment ⚫ TCP passes the segment to the Internetwork layer protocol (IP) 6 TCP/IP’s Layered Architecture Example continued: ⚫ IP places its header on the segment: Edition Guide to Networking Essentials, 7th ⚫ The unit of information is now called a packet ⚫ The packet is passed down to the Network access layer, where the NIC operates ⚫ A frame header and trailer are added ⚫ The frame is delivered to the network medium as bits on its way to the www.cengage.com server ⚫ The web server processes it and returns a Web page7 Packet details The data part of an Ethernet packet can hold up to 1500 bytes. MAC-addresses (48bits) are 6 bytes wide each and the Number Of Bytes field is 2 byte wide. That gives the maximum size of an Ethernet frame to be 1514 bytes. Guide to Networking Essentials, 7th Edition 8 Application Layer 9 Remote Desktop Protocol Remote Desktop Protocol (RDP) is used to access a Windows computer remotely by Edition Guide to Networking Essentials, 7th using the Windows GUI ⚫ Used to run Windows applications remotely and network administrators use it to manage Windows workstations and servers remotely 10 11 Telnet and SSH Telnet and Secure Shell (SSH) ⚫ Used to connect to a device across a network Edition Guide to Networking Essentials, 7th via a command-line interface ⚫ Example: use to connect to a managed switch or router Telnet uses TCP port 23 ⚫ Is not a secure protocol SSH uses TCP port 22 ⚫ Provides an encrypted channel between the client and server 12 Domain Name System DNS is a name-to-address resolution protocol that keeps a list of computer names and their IP addresses Using DNS a user can use a computer’s name instead of using it’s IP address Example: – When you enter www.cengage.com in your Web browser, the DNS Client service contacts the DNS server specified in your OS’s IP configuration and requests that the name be resolved to an IP address – Once the IP address for the website is returned, your computer can contact Web server to request a Web page DNS uses UDP because DNS messages usually consist of a single packet of data DNS Explained Guide to Networking Essentials, 7th Edition 13 © Cengage Learning 2016 DNS Server Guide to Networking Essentials, 7th Edition 15 © Cengage Learning 2016 Guide to Networking Essentials, 7th 16 Edition Transport-Layer Protocols TCP Transport-Layer Protocols Transport-layer protocols are used with most Application- layer protocols because they: ⚫ Supply a header field to identify the Application layer Edition Guide to Networking Essentials, 7th ⚫ Provide reliability and flow control for applications that typically transfer a large amount of data 17 Guide to Networking Essentials, 7th 18 Edition TCP Header Role of the Transport Layer Transport layer has two protocols: ⚫ Transmission Control Protocol (TCP) Connection oriented and designed for reliable transfer of Edition Guide to Networking Essentials, 7th information in complex internetworks ⚫ User Datagram Protocol (UDP) Connectionless and designed for efficient communication of generally small amounts of data ⚫ TCP vs UDP ⚫ Both: Work with segments or datagrams Provide a means to identify the source and destination applications involved in a communication Protect data with a checksum 19 Working with Segments and Datagrams Transport-layer protocols work with units of data called segments (TCP) or datagrams Edition Guide to Networking Essentials, 7th (UDP) Both TCP and UDP add a header to data The Transport-layer protocol then passes the segment to the Internetwork protocol (IP) With incoming data, the Transport-layer receives the segment from the Internetwork protocol, processes it, de-encapsulates it 20 and sends the resulting data up to the Application layer Identifying Source and Destination Applications How do computers keep track of incoming data when a Web browser, email Edition Guide to Networking Essentials, 7th application, chat and a word processing program are all running at the same time? TCP and UDP use port numbers to specify the source and destination Application-layer protocols ⚫ Port numbers are 16-bit values assigned to specific applications running on a computer or network device Decimal 80 21 Binary 0000 0000 0101 0000 Hex 50 Port number 443 Edition Guide to Networking Essentials, 7th https://en.wikipedia.org/wiki/List_of_TCP_and_UDP_port_numbers Decimal 443 Binary 0000 0001 1011 0001 22 Hex 01BB Common port Numbers 23 Protecting Data with a Checksum To protect data integrity, TCP and UDP provide a checksum similar to the CRC Edition Guide to Networking Essentials, 7th Intermediate devices don’t recalculate the checksum in the Transport layer so if data corruption occurs during the transmission, the final receiving station detects the checksum error and discards the data 24 TCP: The Reliable Transport Layer If an application requires reliable data transfer, it uses TCP as the Transport-layer protocol How does TCP guarantee data delivery? Edition Guide to Networking Essentials, 7th TCP provides reliability by using these features: ⚫ Establishing a connection ⚫ Segmenting large chunks of data ⚫ Ensuring flow control with acknowledgements TCP is a connection-oriented protocol ⚫ It establishes a connection with the destination, data is transferred, and the connection is broken 25 Establishing a Connection: The TCP Handshake A client sends a TCP synchronization (SYN) segment to the destination device, usually a server ⚫ A destination port is specified and a source port is assigned dynamically Edition Guide to Networking Essentials, 7th When the server receives the SYN segment, it responds by sending either an acknowledgement-synchronization (ACK-SYN) segment or a reset connection (RST) segment ⚫ RST is sent when the server refused the request to open the session ⚫ If an ACK-SYN is returned, the client completes the three- way handshake by sending an ACK segment back to the server 26 Establishing a Connection: The TCP Handshake Edition Guide to Networking Essentials, 7th 27 Guide to Networking Essentials, 7th 28 Edition 3 Way Hand shake Example Establishing a normal TCP connection requires three separate steps: 1. The first host (Alice) sends the second host (Bob) a "synchronize" (SYN) message with its own sequence number which Bob receives. 2. Bob replies with a synchronize-acknowledgment (SYN-ACK) message with its own sequence number and acknowledgement number, which Alice receives. 3. Alice replies with an acknowledgment (ACK) message with acknowledgement number , which Bob receives and to which he doesn't need to reply. 29 Segmenting Data When TCP receives data from the Application layer, the size might be too large Edition Guide to Networking Essentials, 7th to send in one piece TCP breaks the data into smaller segments (max frame sent by Ethernet is 1518 bytes) Each segment is labeled with a sequence number so that if segments arrive out of order they can be reassembled in the correct order 30 Guide to Networking Essentials, 7th 31 Edition Segmentation Ensuring Flow Control with Acknowledgements Flow control prevents a destination from becoming overwhelmed by data, resulting in Edition Guide to Networking Essentials, 7th dropped packets TCP establishes a maximum number of bytes, called the “window size”, that can be sent before the destination must acknowledge the receipt of data If no acknowledgement is received within a specified period of time, the sending station will retransmit from the point at which an acknowledgement was last received 32 IP 33 Internetwork-Layer Protocols ▪ The Internetwork layer is where administrators usually do the most network configuration ▪ Where the IP protocol operates and is the heart of the TCP/IP protocol suite ▪ Responsible for four main tasks: ▪ Defines and verifies IP addresses ▪ Routes packets through an internetwork ▪ Resolves MAC addresses from IP addresses ▪ Delivers packets efficiently Guide to Networking Essentials, 7th Edition 34 © Cengage Learning 2016 IP Header Source: https://www.tutorialspoint.com/ipv4/ipv4_packet_structure.htm Guide to Networking Essentials, 7th Edition 35 © Cengage Learning 2016 Data link layer Layer 2 is the Data Link layer. This layer uses a Media Access Controller (MAC) to generate the frames that will be transmitted. As the name suggests, the MAC controls the physical transmission media. When transmitting data, this layer adds a header containing the source and destination MAC addresses to the packet received from the Network layer (layer 3). The frame it creates will then be forwarded to the Physical layer. 36 © Cengage Learning 2016 Physical Layer Layer 1 is the Physical layer. It sends and receives signals on the physical wire or antenna to transmit the bits found in frames. There is a PHY found at the end of every network interface (e.g. end of wire or antenna). 37 © Cengage Learning 2016 Data Encapsulation When a protocol on the sending system adds data to the packet header, the process is called data encapsulation. source: https://docs.oracle.com/cd/E19120-01/open.solaris/819-3000/ipov-32/index.html 38 © Cengage Learning 2016 Summary TCP/IP is the main protocol suite used in networks Edition Guide to Networking Essentials, 7th The Application layer consists of protocols such as HTTP and DNS and provides an interface for applications to access network services The Transport layer provides reliability and works with segments (TCP) and datagrams (UDP) The Internetwork layer is where most network configuration occurs and is composed of IP, ICMP, and ARP 39 Summary The Network access layer is composed of network technologies, such as Ethernet and Edition Guide to Networking Essentials, 7th WAN technologies 40 Guide to Networking Essentials, 7th 41 Edition Learn More: Introduction to TCP/IP Video 42

Use Quizgecko on...
Browser
Browser