What happens when you type Google.com in your browser and press Enter

What happens when you type Google.com in your browser and press Enter

Have you ever stopped to think about all of the behind-the-scenes activity that occurs when you perform this simple action? When you type "google.com" into your browser and hit "Enter," you initiate a series of events that ultimately leads to the Google homepage appearing on your screen. In this blog post, we will dive into the details of what happens during this process and explore the various technologies at play. From the role of DNS to the inner workings of a web server, we will break down all of the steps involved in getting you the information you requested. So sit back, relax, and join us on this journey through the world of the internet.

Beginning Concepts

Before getting started, I want to first explain what a web page is, a document that is displayed in a web browser, such as Google Chrome, Mozilla Firefox, or Microsoft Edge. It is written in a markup language called HTML (Hypertext Markup Language) and is accessed via the Internet or a local network. A web page can contain text, images, and other multimedia elements, as well as links to other web pages. It is one of the primary ways that people access and interact with the Internet. Bellow described major steps that happen when requesting a site from our browser, in order of their occurrence?

DNS Requests:

What is DNS is the phone book of the internet. Humans access information online through domain names, like google.com , Web browsers interact through internet protocol(IP) addresses,?DNS translates domain names to IP addresses so browsers can load internet resources. Each device connected to the Internet has a unique IP address which other machines use to find the device. DNS servers eliminate the need for humans to memorize IP addresses such as 192.168.1.1 (in IPv4), or more complex newer alphanumeric IP addresses such as 2400:cb00:2048:1::c629:d7a2 (in IPv6).

When a user types google.com into the browser and presses Enter, the browser first sends a DNS request or Domain Name System request to a DNS server. The role of a DNS is to translate domain names into IP addresses, so it can quickly route internet traffic to the exact location of the website the user is trying to reach. After the DNS server successfully translates the domain name, it then returns the IP address to the user’s browser for the website requested.

No alt text provided for this image

TCP/IP:

TCP and IP are separate protocols that work together to ensure data is delivered to its intended destination within a network. IP obtains and defines the address—the IP address—of the application or device the data must be sent to. TCP is then responsible for transporting and routing data through the network architecture and ensuring it gets delivered to the destination application or device that IP has defined.?

In other words, the IP address is akin to a phone number assigned to a smartphone. TCP is the computer networking version of the technology used to make the smartphone ring and enable its user to talk to the person who called them. The two protocols are frequently used together and rely on each other for data to have a destination and safely reach it, which is why the process is regularly referred to as TCP/IP.

Once the browser has retrieved the IP address for the requested website, it then makes a TCP/IP connection or Transmission Control Protocol/Internet Protocol connection. This is a connection-oriented protocol, which provides reliable transmission data.

TCP/IP?It breaks messages into packets to avoid having to resend the entire message in case it encounters a problem during transmission. Packets are automatically reassembled once they reach their destination. Every packet can take a different route between the source and the destination computer, depending on whether the original route used becomes congested or unavailable.

As a connection based protocol, the TCP establishes and maintains a connection between applications or devices until they finish exchanging data. It determines how the original message should be broken into packets, numbers and reassembles the packets, and sends them on to other devices on the network, such as routers, security gateways, and switches, then on to their destination. TCP also sends and receives packets from the network layer, handles the transmission of any dropped packets, manages flow control, and ensures all packets reach their destination.

Firewall:

A firewall is a security system that controls incoming and outgoing network traffic based on predetermined security rules. It is often used to protect a network from external threats, such as hackers or malware.

In the context of servers, a firewall can help to protect the server from unauthorized access and prevent malicious traffic from reaching the server. It can be configured to allow or block traffic based on various criteria, such as the source and destination of the traffic, the port number, and the protocol being used.

By setting up a firewall on a server, you can help to prevent unauthorized access and protect the server and the data it stores from cyber threats. It is an important component of a server's overall security posture, and it is recommended to use a firewall in conjunction with other security measures such as antivirus software, intrusion detection and prevention systems, and secure authentication methods.

HTTPS/SSL:

When a client, such as a web browser, connects to a server using HTTPS, the server sends a copy of its SSL certificate to the client. The client then uses this certificate to verify the identity of the server and to establish an encrypted connection. Once the connection is established, all data transmitted between the client and the server is encrypted using a secure cryptographic algorithm.

This encryption makes it very difficult for anyone to intercept and read the data being transmitted between the client and the server. Even if a hacker were able to intercept the data, they would not be able to decipher it without the proper decryption key.

In addition to encrypting data transmitted between the client and the server, HTTPS also provides authentication to ensure that the client is communicating with the intended server. This is important because it helps to prevent man-in-the-middle attacks, in which a hacker intercepts and modifies data transmitted between a client and a server.

Overall, HTTPS helps to protect the privacy and security of users by encrypting and authenticating data transmitted over the internet.

Load-balancer:

A load balancer is a device that evenly distributes network traffic across multiple servers or resources. When a client (such as a web browser) sends a request to a website, the request is typically routed through a load balancer before it reaches the server hosting the website. This allows the load balancer to distribute incoming requests to the various servers in a way that maximizes the use of their resources and minimizes response times for clients.

There are several types of load balancers, including hardware load balancers, software load balancers, and cloud-based load balancers. They can be used to distribute traffic across a variety of resources, including web servers, application servers, and databases.

Load balancers play a critical role in ensuring the availability and performance of websites and other online services. They help to prevent overloading of servers, allow for seamless scaling of resources, and provide a level of redundancy that helps to ensure that services remain available even if one or more servers fail.

Web server:

The load-balancer will then forward the request to the web server. A web server is a computer or server that provides web pages and other content on the World Wide Web. In this case, the web server will send the HTML, JavaScript, and other resources that make up the Google homepage to the user’s browser.

When a client (such as a web browser) sends a request to a website, the request is typically routed to a web server. The web server's job is to process the request and return the appropriate response to the client.

To do this, the web server first parses the request to determine what the client is asking for. It then looks for the requested resource (such as a web page or an image) in its file system or retrieves it from a database if necessary. Once the requested resource has been located, the web server formats the response according to the appropriate protocol (such as HTTP) and sends it back to the client.

Web servers are an essential part of the infrastructure that powers the internet. They are responsible for hosting websites and making them available to users around the world. There are many different types of web servers, including Apache, Nginx, and Microsoft IIS. They can be used to serve a wide variety of content, including static web pages, dynamic web pages generated by server-side scripts, and media files such as images, audio, and video.

Application server

An application server is a type of server that is designed to host applications and provide services to client applications. When a client (such as a web browser) sends a request to a website, the request is typically routed to a web server, which then passes the request to an application server if necessary.

The application server's job is to process the request and generate a response. It does this by running the code for the requested application, which may involve interacting with databases, performing calculations, or making requests to other servers or services. Once the response has been generated, the application server sends it back to the web server, which then sends it to the client. Application servers are often used to host complex, interactive applications that require a lot of processing power or that need to access a lot of data. They can be used to host applications built using a variety of technologies, including Java, .NET, and PHP.

Application servers can be used in a variety of contexts, including web-based applications, mobile apps, and backend systems for enterprise software. They are an important part of the infrastructure that powers the internet and other networks.

Database server:?The last step is when the application or web server sends a request to the database server. When a user requests a website, the web server receives the request and sends it to the database server to retrieve the necessary data. The database server then performs the necessary actions to retrieve the data, such as searching the database or executing a specific query. Once the data has been retrieved, the database server sends it back to the web server, which formats the data into an HTML page and sends it back to the user's web browser.

In this process, the database server plays a critical role in providing the data that is used to generate the website. It is responsible for efficiently storing and retrieving the data, as well as ensuring that the data is consistent and accurate.

Conclusion:

When a user types google.com into the browser, a lot of behind-the-scenes steps are taken to provide the user with the information they are looking for. Before any of the actual resources that make up the Google homepage are sent to the user’s browser, a DNS request is sent, a TCP/IP connection is made, a firewall is checked, HTTPS/SSL is used, a load-balancer assigns workloads, the web server sends resources, the application server handles interactive functions, and the database server queries the database for requested information. All of these steps are taken to ensure the user can securely access the website and have a smooth experience.

#programming?#technology?#informationtechnology?#fullstackdeveloper?Google

Resources

What is DNS? | How DNS works:?https://www.cloudflare.com/learning/dns/what-is-dns/

What Is a Firewall, and What Is It Used For:?https://www.parallels.com/blogs/ras/types-of-firewalls/

What is firewall :?https://www.checkpoint.com/cyber-hub/network-security/what-is-firewall/

What is Transmission Control Protocol TCP/IP? :?https://www.fortinet.com/resources/cyberglossary/tcp-ip

要查看或添加评论,请登录

Yiacob Kibret, MD的更多文章

社区洞察

其他会员也浏览了