Protocols

13 min read2,407 words

Network Protocols

A network protocol is a set of rules that defines how devices communicate and exchange data over a network.

Simple definition

A network protocol is a set of rules and standards that devices follow to communicate with each other.

For example, when you open a website:

Browser ↓ HTTPS ↓ TCP ↓ IP ↓ Wi-Fi / Ethernet ↓ Internet ↓ Web Server

Different protocols perform different jobs.

1. Why Do We Need Protocols?

Imagine two people communicating:

Person A → ??? → Person B

If they don't agree on a language, format, timing, or rules, communication becomes difficult.

Networks work similarly.

Devices need rules for:

  • How data is formatted
  • How data is addressed
  • How data is transmitted
  • How errors are handled
  • How devices identify each other
  • How connections are established
  • How data is secured

Protocols provide these rules.

2. Example of Protocol Communication

Suppose you type:

https://example.com

Several protocols may participate:

DNS ↓ HTTPS ↓ TCP ↓ IP ↓ Ethernet / Wi-Fi

Each protocol has a different responsibility.

3. Major Network Protocols

Here are the most important protocols you should know:

ProtocolFull FormMain Purpose
HTTPHypertext Transfer ProtocolWeb communication
HTTPSHTTP SecureSecure web communication
FTPFile Transfer ProtocolFile transfer
SFTPSSH File Transfer ProtocolSecure file transfer
SSHSecure ShellSecure remote access
TelnetTeletype NetworkRemote access, insecure
SMTPSimple Mail Transfer ProtocolSending email
POP3Post Office Protocol 3Receiving/download email
IMAPInternet Message Access ProtocolAccessing email on server
DNSDomain Name SystemDomain → IP resolution
DHCPDynamic Host Configuration ProtocolAutomatic IP configuration
ARPAddress Resolution ProtocolIPv4 IP → MAC resolution on local network
ICMPInternet Control Message ProtocolNetwork diagnostics/control
TCPTransmission Control ProtocolReliable transport
UDPUser Datagram ProtocolConnectionless transport
IPInternet ProtocolLogical addressing/routing
SNMPSimple Network Management ProtocolNetwork device monitoring/management
NTPNetwork Time ProtocolTime synchronization
LDAPLightweight Directory Access ProtocolDirectory services
SMBServer Message BlockFile/printer sharing
MQTTMessage Queuing Telemetry TransportIoT messaging

4. HTTP

HTTP stands for:

Hypertext Transfer Protocol

It is used primarily for communication between web clients and web servers.

Example:

Browser ↓ HTTP Request ↓ Web Server ↓ HTTP Response ↓ Browser

Example request:

GET /index.html HTTP/1.1 Host: example.com

The server may respond:

HTTP/1.1 200 OK

Common HTTP methods:

MethodPurpose
GETRetrieve data
POSTSubmit/create data
PUTReplace/update data
PATCHPartially update data
DELETEDelete data
HEADRequest headers without normal response body

5. HTTPS

HTTPS stands for:

Hypertext Transfer Protocol Secure

It is HTTP protected using TLS.

HTTP + TLS = HTTPS

Instead of:

Browser ─── HTTP ───> Server

we have:

Browser ─── HTTPS/TLS ───> Server

HTTPS provides important security properties such as:

  • Encryption
  • Authentication of the server
  • Integrity protection

Default port:

TCP 443

6. FTP

FTP stands for:

File Transfer Protocol

It is used to transfer files between computers.

Client │ │ FTP ↓ FTP Server

Traditional FTP is not encrypted.

Common traditional FTP ports:

TCP 21 → Control connection TCP 20 → Traditional active-mode data connection

For secure file transfer, alternatives such as SFTP or FTPS are commonly used.

7. SFTP

SFTP stands for:

SSH File Transfer Protocol

It operates over SSH.

Client ↓ SSH ↓ SFTP ↓ Server

Common port:

TCP 22

Don't confuse:

FTP ≠ SFTP

SFTP is a different protocol built on SSH.

8. SSH

SSH stands for:

Secure Shell

It provides secure remote access to computers.

Example:

ssh user@192.168.1.10

You can use SSH to:

  • Log into a remote Linux server
  • Execute commands
  • Transfer files using SFTP
  • Create secure tunnels

Default port:

TCP 22

9. Telnet

Telnet is an older remote-access protocol.

Client ↓ Telnet ↓ Server

The major problem is that traditional Telnet does not provide encryption.

Default port:

TCP 23

For secure remote administration, SSH is normally preferred.

10. DNS

DNS stands for:

Domain Name System

DNS translates domain names into IP addresses and also supports other types of DNS information.

Example:

www.example.com ↓ DNS ↓ 93.184.216.34

Without DNS, users would have to remember IP addresses instead of domain names.

Common DNS record types:

RecordPurpose
ADomain → IPv4
AAAADomain → IPv6
CNAMEAlias for another name
MXMail server
NSAuthoritative name server
TXTText information, often used for verification/security policies
PTRReverse DNS

DNS commonly uses:

UDP 53

It can also use:

TCP 53

TCP is important for certain DNS operations, including zone transfers and responses that require TCP.

Modern DNS can also be transported through technologies such as DNS over HTTPS (DoH) and DNS over TLS (DoT).

11. DHCP

DHCP stands for:

Dynamic Host Configuration Protocol

It automatically provides network configuration to clients.

For example:

Laptop ↓ DHCP Request ↓ DHCP Server ↓ IP Address Subnet Mask Gateway DNS Server

A typical DHCP process is remembered as:

D → Discover O → Offer R → Request A → Acknowledgment

This is called DORA.

Common ports:

UDP 67 → DHCP Server UDP 68 → DHCP Client

12. ARP

ARP stands for:

Address Resolution Protocol

In IPv4 local networks, ARP helps discover the MAC address associated with an IPv4 address.

Suppose:

IP = 192.168.1.20

The computer needs to know the corresponding MAC address.

It sends an ARP request:

"Who has 192.168.1.20?"

The device replies:

"192.168.1.20 is at AA:BB:CC:DD:EE:FF"

Then the sender can use the MAC address for local Ethernet communication.

IPv6 does not use ARP; it uses Neighbor Discovery Protocol (NDP) through ICMPv6.

13. ICMP

ICMP stands for:

Internet Control Message Protocol

It is used for network diagnostics and control/error messages.

A famous example is:

ping 8.8.8.8

Traditional ping uses:

ICMP Echo Request ↓ ICMP Echo Reply

Another important tool is:

traceroute

or on many Linux systems:

tracepath

These can use ICMP, UDP, or other mechanisms depending on the implementation and options.

14. TCP

TCP stands for:

Transmission Control Protocol

TCP provides a reliable, connection-oriented transport service.

Features include:

  • Connection establishment
  • Reliable delivery
  • Ordering
  • Retransmission
  • Flow control
  • Congestion control

Example:

Client Server SYN ──────────────────> <──────────────── SYN-ACK ACK ──────────────────>

This is the TCP three-way handshake.

15. UDP

UDP stands for:

User Datagram Protocol

UDP is connectionless and has much less protocol overhead than TCP.

It does not provide TCP-style guarantees of:

  • Delivery
  • Ordering
  • Retransmission

Examples of applications that may use UDP include:

  • DNS
  • DHCP
  • Real-time applications
  • Online games
  • QUIC-based applications

16. IP

IP stands for:

Internet Protocol

Its primary responsibilities include logical addressing and forwarding packets between networks.

There are two major versions:

IPv4 IPv6

Example IPv4:

192.168.1.10

Example IPv6:

2001:db8::10

Routers use IP addressing to forward packets toward their destinations.

17. SMTP

SMTP stands for:

Simple Mail Transfer Protocol

It is primarily used to send and relay email.

Example:

Email Client ↓ SMTP ↓ Mail Server ↓ Destination Mail Server

Common SMTP ports include:

25 → Server-to-server mail relay 587 → Message submission 465 → Commonly used for implicit TLS submission

18. POP3

POP3 stands for:

Post Office Protocol version 3

It is used to retrieve email.

Traditionally, POP3 is designed around downloading messages from the mail server to a client.

Common ports:

110 → POP3 995 → POP3 over TLS

19. IMAP

IMAP stands for:

Internet Message Access Protocol

It allows email clients to access and synchronize messages stored on a mail server.

Common ports:

143 → IMAP 993 → IMAP over TLS

POP3 vs IMAP

POP3IMAP
Download-orientedServer synchronization
Less suited to multiple devicesExcellent for multiple devices
Messages may be stored locallyMessages generally remain on server
SimplerMore feature-rich

20. NTP

NTP stands for:

Network Time Protocol

It synchronizes clocks over a network.

Example:

Computer ↓ NTP ↓ Time Server ↓ Correct time

Common port:

UDP 123

Accurate time is especially important for:

  • Logs
  • Authentication
  • Certificates
  • Distributed systems
  • Security monitoring

21. SNMP

SNMP stands for:

Simple Network Management Protocol

It is used to monitor and manage network devices.

For example:

Network Monitoring Server │ ├── Router ├── Switch ├── Access Point └── Firewall

A monitoring system can collect information such as:

  • CPU usage
  • Memory
  • Interface traffic
  • Errors
  • Device status

Common ports:

UDP 161 → SNMP queries UDP 162 → SNMP traps

22. MQTT

MQTT stands for:

Message Queuing Telemetry Transport

It is very important in IoT.

Instead of devices communicating directly, MQTT commonly uses a broker.

ESP32 │ │ Publish ↓ MQTT Broker │ │ Subscribe ↓ Web Dashboard

Example:

Topic: home/room1/temperature

ESP32 publishes:

28.5°C

A dashboard subscribed to that topic receives the value.

MQTT is popular because it is lightweight and works well with constrained devices.

23. SMB

SMB stands for:

Server Message Block

It is commonly used for:

  • File sharing
  • Printer sharing
  • Network resources

Example:

Windows PC ↓ SMB ↓ File Server

SMB commonly uses:

TCP 445

24. LDAP

LDAP stands for:

Lightweight Directory Access Protocol

It is used to access and manage directory information.

For example, an organization can maintain:

Users Groups Computers Permissions

LDAP is commonly associated with centralized identity and directory services.

25. Protocols by TCP/IP Layer

A useful way to organize everything:

┌──────────────────────────────────────┐ │ APPLICATION │ │ HTTP HTTPS DNS DHCP FTP SSH SMTP │ │ POP3 IMAP SNMP NTP MQTT SMB LDAP │ ├──────────────────────────────────────┤ │ TRANSPORT │ │ TCP UDP │ ├──────────────────────────────────────┤ │ INTERNET │ │ IPv4 IPv6 ICMP IPsec │ ├──────────────────────────────────────┤ │ NETWORK ACCESS │ │ Ethernet Wi-Fi │ └──────────────────────────────────────┘

Some protocols, especially security and link/network mechanisms, don't fit perfectly into a single simplified layer. For learning, the above grouping is useful.

26. Protocol + Port

A protocol and a port are not the same thing.

For example:

HTTPS → Application protocol 443 → Port number TCP → Transport protocol

So:

HTTPS ↓ TCP 443 ↓ IP ↓ Ethernet/Wi-Fi

Another example:

SSH ↓ TCP 22 ↓ IP

27. Protocol Stack Example

When you access a secure website:

Application │ └── HTTPS │ Transport │ └── TCP │ Internet └── IP │ Network Access └── Ethernet/Wi-Fi

When an ESP32 sends sensor data using MQTT:

DHT11 ↓ ESP32 ↓ MQTT ↓ TCP ↓ IP ↓ Wi-Fi ↓ MQTT Broker

This is a very good real-world example of networking protocols in IoT.

28. Protocol vs Service vs Port

These concepts are often confused.

Protocol

Defines communication rules.

HTTP TCP DNS MQTT

Port

Identifies a transport-layer endpoint.

80 443 22 53

Service

The application or network function being provided.

Web service SSH service DNS service Mail service

For example:

Web Service ↓ HTTPS ↓ TCP ↓ Port 443

29. Important Protocols to Remember

For networking and cybersecurity, prioritize these:

HTTP / HTTPS DNS DHCP ARP ICMP TCP UDP IP SSH FTP / SFTP SMTP POP3 IMAP SNMP NTP MQTT

Especially remember:

HTTP → Web HTTPS → Secure Web DNS → Domain → IP DHCP → Automatic network configuration ARP → IPv4 → MAC on local network ICMP → Diagnostics/control TCP → Reliable transport UDP → Connectionless transport IP → Addressing/routing SSH → Secure remote access MQTT → IoT messaging

30. Cybersecurity Perspective

Understanding protocols is extremely important in cybersecurity.

For example, when examining a system, you may encounter:

22/tcp SSH 53/tcp DNS 80/tcp HTTP 443/tcp HTTPS 445/tcp SMB

A tool such as Nmap may show:

PORT STATE SERVICE 22/tcp open ssh 80/tcp open http 443/tcp open https

This does not automatically mean a service is vulnerable. It simply tells you that the corresponding port appears accessible and a service may be listening there. Further authorized assessment is required to determine what is actually running and whether it is secure.

31. Final Revision

Protocol ↓ Rules for communication

Application

HTTP → Web HTTPS → Secure Web DNS → Name resolution DHCP → IP configuration FTP → File transfer SSH → Secure remote access SMTP → Sending email IMAP → Email access/synchronization MQTT → IoT messaging SNMP → Network management NTP → Time synchronization

Transport

TCP → Reliable, connection-oriented UDP → Connectionless, low overhead

Internet

IP → Addressing/routing ICMP → Diagnostics/control

Network Access

Ethernet Wi-Fi

Most important concept:

Application Protocol ↓ Transport Protocol ↓ Internet Protocol ↓ Network Access

For example:

HTTPS ↓ TCP ↓ IP ↓ Wi-Fi

That is the protocol stack working together to move data across a network.

Keep learning. Keep building. Keep growing.

© 2026 Ugenz Academy