192.168.2.1

How TCP/IP and Routing Work

Modern computing applies the use of the Internet. Payment processing, online business transaction, chat, email, and etc. require the use of the Internet and are very common practices today. Do you know how your computer is able to access the Internet? For computers to communicate and understand each other, a standard implementation should be used which is the Transmission Control Protocol/Internet Protocol. This is the basic form of communication that allows computers over Internet to exchange information.

The Internet is composed of millions of computers connected to each other through networking devices. Before we take a look at some basic principles and theories used in computer networking, let us first get ourselves familiarized with some terms that we will need as we continue reading.

Packets - Are blocks of messages sent over the network. From a whole message, it is broken into blocks for easy transmission to the network through packet switching.

Before reaching the destination, packets have to pass through several layers or protocols in order for the recipient to properly interpret the packets that are sent. TCP is responsible for breaking the message into several packets to be sent over the Internet while on the receiving computer, the TCP then reassembles these packets to from the original message. The IP on the other hand is responsible for providing the proper address of the destination known as the IP Address. Each packet is packed with the sender's address and the recipient's address.

DoD reference model defines four layers to pass before a message can be sent. These layers include Application, Host-to-Host Transport, Internetwork, and Network Interface. Open Systems Interconnection (OSI) model is another protocol stack in computer networking that is composed of seven layers. These layes include: Application, Presentation, Session, Transport, Network, Data-Link, and Physical Layer. Each layer has something to do in order to proceed to the next step. Let's focus on the DoD reference model.

Network Interface layer, the lowest level, is responsible for sending and receiving packets in the network. This layer is also responsible for mapping IP addresses to physical hardware addresses (MAC ID) of a device. Most processes done on this layer involve the device driver of the Network Interface Card (NIC).

Internetwork layer handles the addressing, packaging, and routing of packets to reach its destination. The main protocol in this layer is the Internet Protocol (IP), a connectionless protocol that defines a datagram and the addressing scheme to be used. IP is considered as unreliable protocol since it does not process error checking and correction. This layer also handles the routing of packets to different networks by forwarding these packets to the right recipient through a gateway- a computer or device dedicated to checking the recipients IP Address.

Host-to-Host Transport layer provides the end-to-end connectivity of two devices that are communicating. This layer handles the Time-To-Live (TTL) for every connection. TTL is the considerable amount of time given to a packet before it is discarded. If a packet stays to long before being accepted by the recipient and has reached the TTL, it will then be discarded while requesting the sender to resend the packet. Protocols such as TCP and UDP are used in this layer.

Application layer is the higher level protocol that handles the request user programs make when making a connection. Your program looks for the appropriate protocol in this layer in order to send the packets. Most commonly used protocols in this layer are the Hyper Text Transmission Protocol (HTTP) for web browsing, File Transfer Protocol (FTP) for transferring files such as uploading to your web host, and Simple Mail Transfer Protocol (SMTP) for sending emails. Application layer provides the port number where a protocol can be accommodated. Common ports include Port 80 for HTTP, Port 21 for FTP and Port 25 for SMTP.

All four layers in DoD interface model are also being done in OSI Model. However, a single DoD layer can handle two layers of the OSI Model. When a user is browsing the Internet, the computer uses TCP/IP to communicate to the receiving computer. On the other hand the receiving computer then replies through TCP/IP.

Please refer to Wikipedia for more information.