The OSI Model & How Information Travels Through The Internet

A user tells their browser to fetch a page from techiess.com The browser makes an HTTPS request to techiess.com. To fetch the required web page it passes the request to its HTTP protocol handler, that is Layer 7 of the OSI model, the Application layer.

When the HTTP protocol handler at Layer 7 recognizes that the request is for a secure document, it passes the request to the TLS library at Layer 5 and 6 of the OSI model. These layers are called the Session and Presentation layers.

In order to open a secure channel, the TLS library needs to establish a connection to the destination. It passes a connection request to TCP which lives at Layer 4 of the OSI model, the Transport layer. The TCP handler receives the connection request. Then, it creates a packet with the “SYN” flag set — the first part of the three-way handshake with the remote server to establish a connection.

After the TCP handler has created a packet to initiate a connection, it passes the packet down to IP which lives at OSI Layer 3, also called the Network Layer. The network layer receives the packet and adds the correct IP information to its header. That informs the internet routers how to route the packet to its destination IP address.

Now that the network layer has a routable packet, it passes it down to Layer 2, the Data-Link layer. The data-link layer adds the router’s MAC address as the local destination address, allowing the router to send the packet out to the Internet.

In order for the packet to get onto the basic networking transmission technologies of the network, it is then passed to OSI Layer 1 or the Physical Layer to complete the task. The physical layer takes the binary packet and physically encodes it onto network cabling — or places it onto the airwaves in the case of a WiFi network — and the packet begins its journey across the local network and out to the wider Internet.

Once the packet reaches the destination server, the whole process reverses and the packet travels back up the layers of the OSI model.

This process happens constantly as your computer communicates with other remote servers on the Internet.

This article is from https://www.wordfence.com/learn/understanding-the-osi-model-video/

==========

OSI Model is 7 layers, Application, Presentation, Session, Transport, Network, Data-Link, Physical. Application layer is for application such as DNS, SMTP, FTP, Telnet, … Presentation layer is for format data, encryption/decryption, Session layer is start/stop session, Transport layer is TCP/UDP, Port Number, Network layer is IP address, Routers, Data-Link layer is MAC Address, switches, Physical layer is cable, Network Interface Cards(NIC), hub.

# How to internet works

For example via HTTPS, we open a page from browser and then browser makes an HTTPS request via HTTP protocol handler. This is application layer, layer 7 of OSI model.

HTTP protocol handler recognizes this request is a secure document. It passes to TLS library at Presentation layer, layer 6 of OSI model and start session at Session layer, layer 5 of OSI model.

TLS libray needs to establish a connection to the destination and it passes a connection request to TCP, Transport layer, layer 4 of OSI model. TCP handler receives and creates packet with “SYN” flag set – it is first part of three-way handshaking.

TCP handler created a packet to initiate a connection, it passes the packet down to IP address, Network Layer. This Network layer routes the packet to destination IP address.

Data-Link Layer, 2nd layer of OSI model, add router’s MAC address as local address, allowing the router to send the packet out to the internet.

And then Physical Layer to complete the task. It takes binary packet and physically encodes it onto network cable or wifi network.

Once the packet reaches the destination server, the whole process reverses and the packet travels back up the layers of the OSI Model.

Leave a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.