The Protocol

5 min read

Image
How to communicate, so we can understand each other.

Can you remember the last time you asked someone for something? Let’s assume you went to the bakery and asked for a loaf of bread. How on earth the merchant knew, he needs to turn over, fetch a bread and give it to you? Because you have told him, you have used your mouth to make a few noises which happen to be the words. Because a bakery owner uses the same language as you, he knew exactly what your intentions were, but what if she speaks some different one, what then? In such situation, you two become incompatible when it comes to information exchange, so it makes it impossible for you feed yourself. Such a nasty situation.

I Know What You Mean

Speaking the same language, means sharing a common state of mind, all the idioms and sayings. We can communicate easily, because the other side generally knows the meaning of words we speak, and we all have learned our language the same way during school time. During a particular language’s creation and development processes, some folks have created a protocol for characters and words. All the parties agreed, that word “to apologize” says someone who feels sorry for a things or actions he or she did. Or when someone says “I’m hungry”, everyone knows that it’s time to get some snack or start making a dinner. Even silence, depending on the situation, may be very meaningful. Not answering questions, may be a way of saying you are not in the mood for conversation.

It is likely you have this term before, probably it was put in the context of diplomacy. You have learned about it as a set of special rules and procedures, which politicians need to follow in formal situations. It helps to prevent a common mistakes and possible faux pas made by officials during visits and communication. How it corresponds to the IT?

Where Are Protocols?

Basically everywhere. Look at the ASCII table for instance. Two talking computers know how to react on received byte, if it’s decimal number 72. They know the procedure which is to print a character on the screen, pixel-by-pixel, and move cursor to the next position. They were programmed to react to a non-printable char under decimal number 10, with removing the last typed character from the screen or text. But the Protocols we are interested in, are those concerning communication of our systems with an external world.

Communication Protocols

Now let’s review some of the most popular Communication Protocols used in the IT world. Each of them has been made to serve a different purpose, what makes them incompatible. As you can see, even systems speaks differently, just like us.

File Transfer Protocol (FTP)

This particular protocol is used during downloading and uploading files. It is based on a client-server model, what means there must be a computer sharing his files and clients who make a CRUD operations on them. You can browse and work on files anonymously or loging in with username and password.

HypertextTransfer Protocol (HTTP)

HTTP is used during a Web communication, where two types of operation take place. It handles receiving a text-based content in a form of HTML (HyperText Markup Language) code. Then, the content of the Web Page will be rendered inside user’s Web Browser. Next to conveying an HTML to the browser, it can also send a structured data to the server. To let the Web Server know our intention, we have to use a proper Method name in the request. To get some resource, we may use: GET, HEAD or OPTIONS, but when creating one, a proper will be: POST, PUT or PATCH. Also knows how to handle a file sending and receiving.

Simple Mail Transfer Protocol (SMTP)

When you need to send an email, your application will incorporate SMTP to make a connection with mail server. You are not sending en email directly to someone’s device, it is done with your mail provider’s server, which is a proxy between you and recipient’s mail server. Then your message is relayed between another mail servers, and finally it reaches its destination.

Universal Serial Bus (USB) Protocol

Whenever you connect a USB device to you computer, it knows how to transfer data from and to it. The protocol is dedicated to a two-wire communication between host computer and connected peripherals. What is interesting, USB devices can send data to the Bus, without user’s approval, that’s why it is so risky and dangerous to plug in those of unknown source. Never trust a found USB Drive or any other device, it may infect your computer and stole some fragile, private data.

Summary

Whenever we communicate, we make use of the whole stack of protocols. We speak to our friends and close-ones, we kiss and pet our pets, to communicate them our love. When playing or creating a music, we use notes to communicate with other musicians, experienced ones can hear a melody just by reading a few lines of black marks. Isn’t it fantastic? Protocols used in communication between computers are tailored to the kind of service they provide, so that’s what makes them incompatible with each other.