6.6 How TCP/IP works

What are protocols? And, more specifically, what is TCP/IP?

A protocol is a set of rules which determine how two or more entities interact and communicate. For example, in real life, when two English people are introduced to each other they will shake hands and say something like ‘How do you do?’ But if two Japanese people meet they will bow to one another. They have different protocols governing social behaviour. Similarly, in some societies it is considered aggressive to look people directly in the eye, while in others not looking them in the eye is taken as a sign of evasiveness. If people don't understand the protocols which govern a particular social interaction, all kinds of misunderstandings can result.

Much the same applies to computers. When two machines wish to communicate they also need a set of rules to govern how it is done. Protocols provide these rules. The Net is governed by scores of such protocols. To read this page, for example, you have used the Hypertext Transfer Protocol (HTTP) to request and receive it, and the TCP/IP to transfer the data that make up the request and the page.

Every computer connected to the internet has a unique IP address, or IP number, such as Permanently connected computers, such as those in a university computer laboratory, will have permanent addresses. Those connected via a modem will have a temporary (but still unique) IP address assigned each time the user dials into their ISP. We've seen in the Warriors of the Net animation that the IP program (‘Mr IP’) sticks the address of the target computer on each packet. TCP tells the computer how the information transmitted gets disassembled into packets at the sending computer and reassembled at the receiving computer.

6.5.1 TCP/IP key lessons

6.6.1 TCP/IP at the code layer