Home > Sample chapters

CompTIA Network+ Rapid Review: Network Concepts

Objective 1.5: Identify common TCP and UDP default ports

One of the important functions of a transport layer protocol is to identify the protocol or process that generated the data it carries so that the receiving system can deliver the data to the correct application. Both TCP and UDP do this by specifying the number of a port that has been assigned to a particular process by the Internet Assigned Numbers Authority (IANA).

When a TCP/IP packet arrives at its destination, the transport layer protocol receiving the IP datagram from the network layer reads the value in the Destination Port field and delivers the information in the Data field to the program or protocol associated with that port.

All of the common Internet applications have particular port numbers associated with them, called well-known ports. The IANA has designated all of the port numbers less than 1024 as well-known ports, but not all of them are assigned to applications. TCP and UDP both maintain their own separate lists of well-known port numbers.

Exam need to know

  • SMTP – 25

    For example: What well-known port number does SMTP use?

  • HTTP – 80

    For example: What well-known port number does HTTP use?

  • HTTPS – 443

    For example: What well-known port number does HTTPS use?

  • FTP – 20, 21

    For example: What well-known port number does FTP use?

  • TELNET – 23

    For example: What well-known port number does TELNET use?

  • IMAP – 143

    For example: What well-known port number does IMAP use?

  • RDP – 3389

    For example: What well-known port number does RDP use?

  • SSH – 22

    For example: What well-known port number does SSH use?

  • DNS – 53

    For example: What well-known port number does DNS use?

  • DHCP – 67, 68

    For example: What well-known port numbers does DHCP use?

Ports

The well-known port numbers associated with some of the major application layer protocols in the TCP/IP suite are listed in Table 1-2.

Table 1-2 Well-known port numbers.

PROTOCOL

ACRONYM

TRANSPORT LAYER PROTOCOL

PORT NUMBER

Simple Mail Transfer Protocol

SMTP

TCP

25

Hypertext Transfer Protocol

HTTP

TCP

80

Hypertext Transfer Protocol Secure

HTTPS

TCP

443

File Transfer Protocol

FTP

TCP

20 (Data), 21 (Control)

TELNET

TELNET

TCP

23

Internet Mail Access Protocol

IMAP

TCP

143

Remote Desktop Protocol

RDP

TCP

3389

Secure Shell

SSH

TCP, UDP

22

Domain Name System

DNS

UDP, TCP

53

Dynamic Host Configuration Protocol

DHCP

UDP. TCP

67 (Server), 68 (Client)

True or false: FTP is an unusual protocol in that it uses two different port numbers on the server for a single transaction.

Answer: True. FTP servers use port 21 for control traffic, and port 20 for data. When a client sends a request for a file, it sends it to port 21. The server then opens port 20 and uses it to actually transmit the file.

True or false: HTTP servers use port 80, but HTTP clients can select their own port numbers.

Answer: True. HTTP and many other protocols require clients to select a port number, called an ephemeral port number, for their side of the transaction.

Can you answer these questions?

Find the answers to these questions at the end of this chapter.

  1. Which of the protocols listed in this objective uses well-known ports for both the server and the client?
  2. When configuring an email client that will use IMAP and SMTP, what port numbers would you use for incoming and outgoing traffic?
  3. What port does a client browser use when establishing an encrypted connection to a web server?
  4. What is the number of well-known ports the IANA designates at this time?

Related resources

There are currently no related titles.