Series of Network Fundamentals #5 (Ports & Protocols),to get started in Cyber Security.

C M UPPIN
InfoSec Write-ups
Published in
5 min readApr 6, 2022

--

Hola Hacker’s, today we are going to discuss about “Well known Port Numbers and Protocols”, which are used in Cyber Security industry everyday, in the last blog we learned about IPv4 and IPv6 make sure to read the previous blog.

Let’s Start,

What are Ports?

Ports are used to communicate to a particular service/protocol on the server over the internet, because in the server many services/protocols are running like FTP, SMTP, SSH, HTTP, HTTPS etc, for every services/protocols the unique port number is assigned by this, the server will redirect your request to the particular service.

Port numbers and its ranges:

Port number is a 16-bit value and ranged from 0 to 65535, assigned by “Internet Corporation for Assigned Names and Numbers” (ICANN), which are divided into 3 types.
1) 0–1023 Well Known Ports
2) 1024–49151 Registered Ports
3) 49152–65535 Dynamic Ports

Image from Google

1) Well Known Ports (0–1023)

Well known Ports are basically assigned for a particular services or protocols like FTP, SMTP, SSH, HTTP, HTTPS etc.
We will talk about these protocols down below in detail way.

2) Registered Ports (1024–49151)

These Ports are basically registered by companies and users for a different network functions, Application specific and other services by ICANN.

3) Dynamic Ports (49152–65535)

Dynamic port is used to setup a outbound connection, like if you want communicate to the web server from your browser you need a destination port and source port.

Example :-

Netstat is CLI tool which is installed in every OS, it displays the TCP Connections, routing tables etc. by using this netstat utility we can see the TCP connections. (netstat -h) -h to list the options.

Port numbers and Protocols

Image by Google

1) File Transfer Protocol (FTP) Port no — 20 & 21

This is the protocol which is used transfer the files from server to client device vice-versa using the Command Line Interface, which is rarely used in the organization’s nowadays because it doesn’t encrypt any files or data while communicating between server and client and the data travels in a plain text.

Commands for FTP

2) Secure Shell (SSH) Port Num: 22

This is the protocol used to connect to the device remotely, where it provides encrypted connection between the remote devices.

3) Telenet Port Num: 23

This is the protocol used to connect between the devices remotely, it is very basic protocol and which is very insecure because the data transfers in plain text.

4) Simple Mail Transfer Protocol (SMTP) Port num: 25

This is the protocol used to transmit the emails over the internet to the destination server.

5) Post Office Protocol3 (POP3) Port num: 110

This is the protocol used by email client to retrieve the email from the servers.

6) Domain Name System (DNS) Port num: 53

This is the protocol used to convert Domain names to the IP address and vice versa.
Example:- amazon.com to 95.418.46.46.

7) Dynamic Host Transfer Protocol (DHCP) Port num: 67 & 68

This is the protocol used to assign the IP address dynamically in the network.

8) Trivial File Transfer Protocol (TFTP) Port num: 69

This is the protocol used to transfer the files between the devices, and it is mainly is used in configuring the routers.

9) Hyper Text Transfer Protocol (HTTP) Port num: 80

This is the protocol used to fetch or load the web pages using hypertext links. and it is the foundation of the World Wide Web (WWW).

10) Hyper Text Transport Secure (HTTPS) Port num: 443

The HTTPS protocol functionality same as HTTP, but the main difference is HTTPS uses the additional security features, which gives the authentication and encryption that provides secure communication with the use of Secure Socket layer (SSL) over the internet.

11) Remote Desktop Protocol (RDP) Port num: 3389

This is the protocol which provides the graphical interface to the user to connect to another remote device over the internet.

12) Server Message Block (SMB) Port num: 445

This is the protocol used to access network resource such as shared files and printers in the network.

13) Internet Message Access Protocol (IMAP) Port num: 143

IMAP is the protocol used by email clients to retrieve the email messages from a mail server over a TCP/IP connection.

14) NetBIOS Port num: 137 & 139

NetBIOS stands for Network Basic Input/Output System, it is used to establish a connection and access the shared resources between the computers over the local area network.

In this article, we learned about Port numbers, Protocols and their uses, apart from this there are some other protocols you should definitely check out i will give the link down below.

I hope you understood, if there is anything to add or to correct something, please let me know in the comment section, because there is always room for improvement.

If you liked the content hit the Follow button and every week ill post informative and amazing content make sure to follow onLinked-in & Twitter

--

--