What happens when you type https://www.google.com in your browser and press Enter
P.Eng.Tech. Beatrice T.
Scada Engineer @ Kenya Electricity | Substation Automation Expert
Introduction
Ever wondered what unfolds behind the scenes when you type "www.google.com " into your browser and press Enter? It's a journey that takes us through the layers of the OSI model, a conceptual framework governing the functions of computing systems. In this exploration, our focus will be on the upper layers—Transport, Session, Presentation, and Application—unravelling the intricacies of what happens during this seemingly simple act.
Before we dive into the layers, let's demystify how the internet works in the context of your browser request. This journey commences with the translation of the user-friendly domain name "www.google.com " into an IP address through the Domain Name System (DNS). Following this, your browser establishes a secure connection, ensuring the confidentiality of the data exchanged.
The objective is to dissect the step-by-step process that occurs when you hit Enter after typing a web address, shedding light on the collaborative interaction between your browser and the internet's infrastructure using the LAMP stack.
?
DNS Request
The journey begins at the Application Layer (Layer 7) when you type "google.com " in your browser. This action triggers a DNS request. The DNS request is sent to a DNS resolver, which is typically provided by your Internet Service Provider (ISP) or a public DNS resolver like Google's 8.8.8.8. The DNS resolver is responsible for translating the human-readable domain name "google.com " into an IP address.
?
TCP/IP Handshake
Once armed with the IP address, your browser shifts to the Transport Layer (Layer 4). Here, the Transmission Control Protocol (TCP) ensures a reliable connection with a three-way handshake. This handshake involves the client sending a SYN packet, the server responding with a SYN-ACK packet, and finally, the client acknowledging with an ACK packet.
?
Firewall
In the Network Layer (Layer 3), specifically during the TCP/IP handshake, your connection encounters a firewall. Firewalls act as vigilant gatekeepers, inspecting and filtering incoming and outgoing traffic. At this stage, the firewall ensures that the connection is secure and compliant with predefined rules, allowing only authorized and safe data to proceed.
?
HTTPS/SSL Handshake
Having navigated the firewall, the journey ascends to the Session (Layer 5) and Presentation (Layer 6) layers. Here, the browser and the server engage in an HTTPS/SSL handshake, HTTPS/SSL is a protocol that ensures secure and encrypted communication between a web browser and a server, safeguarding data from potential eavesdropping and unauthorized access.
领英推荐
?
Load-Balancer
A load balancer is a technology that evenly distributes incoming network traffic among multiple servers to optimize resource utilization and ensure high availability of a website or application. In the dynamic world of popular websites like Google, the Load-Balancer becomes a key player, positioned at both the Transport (Layer 4) and Application (Layer 7) layers. Acting as a traffic manager, it distributes incoming requests among multiple servers, preventing overload and optimizing performance.
?
Web Server
Arriving at the pinnacle of the OSI model, the Application Layer (Layer 7), your connection meets the Web Server. This server, often running on Apache, is part of the front end – the user interface that you interact with. It processes your request, retrieving the requested web page or resource and presenting it to you.
?
Application Server
For interactive or dynamic content, the Web Server may collaborate with an Application Server within the same Application Layer (Layer 7). In the realm of the OSI model, this server handles complex business logic and executes database queries. In the LAMP stack, common in web development, this layer often utilizes PHP. This is the back end – the behind-the-scenes functionality that powers the dynamic aspects of the website.
?
Database
In the final act, the Application Server communicates with the Database, still operating within the Application Layer (Layer 7). Here, data is retrieved or stored, completing the digital exchange. In the LAMP stack, MySQL is frequently used for database management. The database is a crucial component of the back end, storing and managing the data that the front end presents to the user.
?
Conclusion
Breaking down the steps from typing "google.com " to seeing information, we've uncovered the complex layers and terminologies that control this digital adventure. The front end, represented by the web server, provides the user interface, while the back end, comprising the application server and database, handles the behind-the-scenes functionality. Understanding this process offers a comprehensive view of the orchestration of technologies that make our online experiences seamless and secure.