Under the Hood of HTTP

HTTP is a generic, stateless, object-oriented protocol. It is a client/server protocol located in the Application layer of the Internet protocol stack and communicates with WinSock. WinSock, or the Windows Sockets API, is a transport-level application programming interface created by Microsoft to allow third-party vendors to create applications that can easily communicate with the Windows operating system. WinSock is an extension to Berkeley Sockets, a core API developed in the UNIX environment. Moving down the protocol stack, WinSock communicates with the communication protocols on the Windows operating system, including TCP/IP. Figure 5.1 diagrams this communication.

Figure 5.1. A Web client accesses a Web server by using HTTP, TCP, and IP.


The remainder of this section provides a detailed discussion of how different technologies play a role in Web communication. First, it looks at the components of a URL, and then covers the steps required to access a Web server.

Web clients attempt to access a Web server by typing a URL into a Web browser. For example, the complete URL to the ConnectOS Corporation home page is http://www.connectos.com/default.htm.

However, you could type the following into most browsers and receive the same results: connectos.com.

What happened to the other pieces of information? It takes several technologies to slim down this amount of typing. The following list briefly describes the role of each technology in this process.

  • Most Web browsers, including Internet Explorer, assume that HTTP is the protocol if none is specified.

  • A DNS server can be configured to reference a specific IP address if no host name, such as www, is specified.

  • Internet Information Services can be configured to return a specific Web page, such as default.htm, if none is specified.

Most users don't like to type long addresses, so knowing how to take advantage of the different technologies can ease this burden for everyone.

After a client types a URL into a Web browser, Internet Explorer formulates the data into a request. For example, a user types http://www.msn.com/default.asp into the Web browser. Several steps occur, and many more packets are sent before the client sees the returned Web page. The following list summarizes the typical steps a Web client takes to access an Internet Web site:

  1. Internet Explorer formulates an HTTP/Request and passes it to the WinSock API.

  2. WinSock determines that the destination is a fully qualified domain name (FQDN). DNS then requests and receives the IP address mapped to the FQDN.

  3. WinSock passes the request to TCP using the newly discovered IP address of the destination server.

  4. TCP assigns the connection a client port number and passes the request to IP.

  5. IP evaluates the destination subnet against the source subnet and refers to the routing table, if necessary.

  6. IP requests that the Address Resolution Protocol (ARP) determine the network adapter address of either the destination server, if it is on the local subnet, or the next router, if the destination server is on a remote subnet.

  7. The data is formulated into a data packet and is passed to the Network Interface layer.

This process jumps into the depths of TCP/IP and protocol communication. If you read through it and thought, "What is a client port number?", "Isn't it TCP/IP—why do you mention TCP and IP separately?", or "What routing table?", then you should read up on TCP/IP. Understanding the lower levels of HTTP communication are fundamental to your ability to manage and troubleshoot Internet Information Services.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset