Network-layer in the Internet Protocol Stack

Source: Internet
Author: User
Tags snmp file transfer protocol
Layer in Internet protocol stack

People have already discussed how to map TCP/IP reference models to OSI models. Because TCP/IP and OSI model groups cannot exactly match, there is no correct answer yet. In addition, the lower layer of the OSI model does not have the ability to truly occupy the real layer; another layer (Network Interconnection layer) is required between the transport layer and the network layer ). Some protocols dedicated to specific network types should run on the network layer, but on the basic hardware frame switching. Examples of similar protocols include the Address Resolution Protocol and the Spanning Tree Protocol (used to keep redundant bridges idle until they are actually needed ). However, they are local protocols and run under the network interconnection function. It is undeniable that putting two groups (not to mention that they are only part of the Logical Network Layer running on different interconnect network protocols such as ICMP) on the same layer will cause confusion, however, the OSI model is not complex enough to do better work. The following chart tries to display the positions of different TCP/IP and other protocols in the original OSI model:

7 Application Layer Such as HTTP, SMTP, SNMP, FTP, telnet, sip, ssh, NFS, RTSP, XMPP, Whois, ENRP
6 Presentation Layer For example, XDR, ASN.1, SMB, AFP, and NCP
5 Session Layer Such as ASAP, ssh, ISO 8327/CCITT x.225, RPC, NETBIOS, ASP, WinSock, BSD sockets
4 Transport Layer For example, TCP, UDP, TLS, RTP, sctp, SPX, ATP, and IL
3 Network Layer For example, IP, ICMP, IGMP, IPX, BGP, OSPF, Rip, IGRP, VPN, ARP, RARP, and X.25
2 Data Link Layer Such as Ethernet, licensing ring, HDLc, frame relay, ISDN, ATM, IEEE 802.11, FDDI, PPP
1 Entity Layer For example, line, radio, and optical fiber

Generally, the top layer (application layer, presentation layer, and Session Layer) of the OSI model is an application layer in a TCP/IP group. Because TCP/IP has a relatively weak Session Layer, it consists of opening and closing connections under TCP and RTP, and different applications under TCP and UDP provide different port numbers, these features can be added to a single application (or databases used by those applications. Similarly, the IP address is designed based on the idea of treating the network below it as a black box, so that it can be considered as an independent layer when discussing TCP/IP.

4

Application Layer
(OSI
Layer 5 to Layer 7)
Such as HTTP, FTP, DNS
(For routing protocols such as BGP and rip, although they run on TCP and UDP respectively for various reasons, they can still be seen as part of the network layer)
3 Transport Layer
(OSI
Layer 4)
For example, TCP, UDP, RTP, and sctp
(A routing protocol such as OSPF can be considered as part of the network layer even if it runs on an IP address)
2 Network Interconnection layer
(OSI
Layer 3)
For TCP/IP, This is the Internet Protocol (IP)
(A required protocol such as ICMP and IGMP can be considered as part of the Network Interconnection layer even though it runs on an IP address; ARP does not run on an IP address)
1 Network Interface Layer
(OSI
Layer 1 and Layer 2)
For example, Ethernet, Wi-Fi, MPLS, etc.
Application Layer

This layer includes all protocols for working with applications to exchange application-specific data using the basic network. The application layer is the layer used by most common network-related programs to communicate with other programs through the network. The processing process at this layer is unique to the application. Data is transmitted from Network-related programs in the internal format used by the application and then encoded into the standard protocol format. Some specific programs are considered to run on this layer. They provide services to directly support user applications. These programs and their corresponding protocols include HTTP (World Wide Web Service), FTP (file transfer), SMTP (email), SSH (secure remote login), DNS (name <-> ip address search), and many other protocols. Once the data from the application is encoded into a standard application layer protocol, it will be transferred to the next layer of the IP stack. At the transport layer, TCP or UDP is the most common application, and the server application is often associated with a public port number. The Port Number of the server application is officially allocated by the internet number assignment board (IANA). However, developers of some new protocols often choose their own port number. Because there are few or more server applications on the same system, there are few problems caused by port conflicts. Application Software usually allows users to forcibly specify the port number as a running parameter. Client programs that connect to the outside usually use a random port number allocated by the system. Applications that listen to a port and send that port to another copy of the application through the server to establish a peering connection (such as DCC File Transfer on IRC) can also use a random port, however, applications generally allow defining a specification for a specific port range to allow a port to be mapped to an internal vro that implements network address translation (NAT. Each application layer (the top layer of the TCP/IP Reference Model) Protocol generally uses one of the two transport layer protocols: connection-oriented TCP transmission control protocol and connectionless packet transmission UDP user data packet protocol. Common application layer protocols include:

Protocol running on TCP:
  • HTTP (Hypertext Transfer Protocol) is mainly used for common browsing.
  • HTTPS (Hypertext Transfer Protocol over Secure Socket Layer, or HTTP over SSL, Secure Hypertext Transfer Protocol), secure version of HTTP protocol.
  • FTP (file transfer protocol, file transfer protocol), known as, is used for file transfer.
  • POP3 (Post Office Protocol, version 3, Post Office Protocol), used for receiving emails.
  • SMTP (Simple Mail Transfer Protocol) is used to send emails.
  • Telnet (teletype over the network, network telex), through a terminal (terminal) login to the network.
  • SSH (Secure Shell, used to replace Telnet with poor security) for encrypted secure login.
Protocol running on UDP:
  • BOOTP (Boot Protocol) is applied to diskless devices.
  • NTP (Network Time Protocol) is used for network synchronization.
Others:
  • DNS (Domain Name Service) is used for address search and Email Forwarding (running on TCP and UDP protocols ).
  • Echo (echo Protocol) is used to identify errors and measure the response time (running on TCP and UDP protocols ).
  • SNMP (Simple Network Management Protocol) is used to collect network information and manage networks.
  • DHCP (Dynamic Host Configuration Protocol) and dynamic IP Address Configuration.
  • ARP (Address Resolution Protocol) is used to dynamically resolve the IP address of the Ethernet hardware.
Transport Layer

The transport layer protocol can solve problems such as end-to-end reliability ("has data arrived at the destination ?") And ensure that the data arrives in the correct order. In TCP/IP protocol groups, the transmission protocol also includes the application to which the data is sent. Technically, dynamic routing protocols at this layer are generally considered part of the network layer in TCP/IP protocol groups. One example is OSPF (IP Protocol 89 ). TCP (ipprotocol 6) is a "reliable" and link-oriented transmission mechanism. It provides a reliable byte stream to ensure data integrity, lossless, and arrive in order. TCP tries its best to continuously test network load and control the speed of data transmission to avoid network overload. In addition, TCP tries to send data in the specified order. This is different from UDP, which may become a defect when real-time data streams or applications with high network-layer loss rate are used. The newer sctp is also a "reliable" and link-oriented transmission mechanism. It is record-oriented rather than byte-oriented. It provides multiple substreams Through multiplexing on a single link. It also provides multi-channel self-addressing support, in which the link terminal can be expressed by multiple IP addresses (representing multiple physical interfaces), so that even if one of the connection fails, it will not be interrupted. It was initially developed for telephone applications (SS7 is transmitted over IP addresses), but it can also be used for other applications. UDP (IP Protocol 17) is a connectionless datagram protocol. It is a "best effort to pass" or "unreliable" protocol-not because it is particularly unreliable, but because it does not check whether the data packet has reached its destination, they are not guaranteed to arrive in order. If an application requires these features, it must detect and determine the features by itself, or use the TCP protocol. The typical application of UDP is to arrive at an application that is more important than reliability such as streaming media (audio and video) on time, or a simple query/response application such as DNS lookup, the additional work required to establish a reliable connection is not proportional. DCCP is currently being developed by Ieft. It provides TCP Flow Control semantics, but retains the UDP datagram service model for users. Both TCP and UDP are used to support some high-level applications. Applications of any given network address use their TCP or UDPPort NumberYes. By conventionKnown PortAssociate with a specific application. RTP is a datagram protocol designed for real-time data such as audio and video streams. RTP uses the UDP packet format as the basic Session Layer. However, it is said to be located at the transport layer of the Internet protocol stack.

Network Interconnection layer

As originally defined, the network layer solves the problem of packet transmission on a single network. Similar protocols include X.25 and ARPANET host/IMP protocol. With the emergence of the Internet idea, additional features are added on this layer, that is, data is transmitted from the source network to the destination network. This involves selecting a path on the network to transfer data packets, that is, the Internet. In an Internet Protocol group, IP addresses complete the basic task of sending data from the source to the destination. The IP address can carry data from multiple high-level protocols. These protocols use a uniqueIP Protocol Number. ICMP and IGMP are respectively 1 and 2. Some IP protocols, such as ICMP (used to send diagnostic information about IP sending) and IGMP (used to manage multicast data), are located on the IP layer but complete the functions at the network layer, this shows the incompatibility between the Internet and the OSI model. All routing protocols, such as BGP, OSPF, and rip, are actually part of the network layer, although they should belong to a higher protocol stack.

Network Interface Layer

The network interface layer is not actually part of the Internet Protocol group, but it is a method for transmitting data packets from the network layer of a device to the network layer of another device. This process can be controlled in the software driver of the NIC, or in the firmware or dedicated chip. This completes some data link functions such as adding a header to prepare for sending and actually sending through the entity media. At the other end, the link layer receives data frames, removes headers, and transmits received packets to the network layer. However, the link layer is not always so simple. It may also be a virtual private network (VPN) or tunnel, where packets from the network layer use tunnel protocol and others (or the same) send the Protocol group instead of sending it to the interface of the entity. VPN and tunnel are usually pre-built, and they have some special features that are directly sent to the physical interface (for example, it can encrypt the data passing through it ). Since the link "layer" is a complete network, recursive use of such protocol groups may cause confusion. However, it is an excellent way to implement common complex functions. (Although it is important to prevent a packet that has been encapsulated and sent through the tunnel from being encapsulated and sent again ).

 

Network-layer in the Internet Protocol Stack

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.