Port numbers

Tip: Choose Save as PDF in the print dialog to download. Use A4 paper size.

Port numbers

Name:
Date:
Class:

Quick Questions

Shade in the A or B circle for each question.

1. In 192.168.1.10:80, what does the number after the colon tell the receiving device?
A Which device on the network should get the data
B Which program or service the data is for
2. Which port number is normally used for HTTP web traffic?
A 80
B 443
3. Which port number is normally used for HTTPS?
A 25
B 443
4. A server at 10.0.0.5 runs a web server and a mail server. How do they share one IP address?
A Each service listens on its own port number
B Each service needs its own IP address
5. Which port number does the DNS service normally use?
A 53
B 80

Match the Pairs

Draw a line connecting each item on the left to its match on the right.

Left columnRight column
1192.168.1.10:443 A192.168.1.10:80
2192.168.1.10:25 BSend data to the device at 192.168.1.10, for its HTTPS (secure web) service
3One device can run several services at once. The port number picks which service gets the data CThe port is joined with a dot instead of a colon. It reads like a five-part address, so the device cannot tell which service is wanted. It should be 192.168.1.10:80.
4A DNS server is reached by using the DNS port number after its IP address DPort 25 is for SMTP email, not web pages. A secure web page uses HTTPS on port 443, so it should be 192.168.1.10:443.
5192.168.1.10.80 E192.168.1.1:53
6192.168.1.10:25 for a secure web page FSend data to the device at 192.168.1.10, for its SMTP (sending email) service

Definitions

192.168.1.10:80

Fill in the Blanks

Complete each line of code by filling in the missing parts.

1.
192.168.1.10:__
2.
192.168.1.10:80 192.168.1.10:___
3.
192.168.1.20:__
4.
8.8.8.8:__
5.
192.168.1.10_80

Spot the Error

Shade in the letter of the line that contains an error.

Question 1
A HTTP: 192.168.1.10:443
B HTTPS: 192.168.1.10:443
C SMTP: 192.168.1.10:25
Question 2
A DNS: 192.168.1.20:53
B Web: 192.168.1.20:80
C Mail: 192.168.1.20:53
Question 3
A url = https://shop.com
B port = 80
C send to 192.168.1.10:port
Question 4
A address = 192.168.1.10;80
B service = HTTP
C send(address, data)
Question 5
A query = lookup(shop.com)
B send query to 192.168.1.1:25
C print(reply)

Answer Key

Port numbers
Section A: Quick Questions
Q1
B — Which program or service the data is for
Q2
A — 80
Q3
B — 443
Q4
A — Each service listens on its own port number
Q5
A — 53
Section B: Match the Pairs
Q1
192.168.1.10:443 → Send data to the device at 192.168.1.10, for its HTTPS (secure web) service
Q2
192.168.1.10:25 → Send data to the device at 192.168.1.10, for its SMTP (sending email) service
Q3
One device can run several services at once. The port number picks which service gets the data → 192.168.1.10:80
Q4
A DNS server is reached by using the DNS port number after its IP address → 192.168.1.1:53
Q5
192.168.1.10.80 → The port is joined with a dot instead of a colon. It reads like a five-part address, so the device cannot tell which service is wanted. It should be 192.168.1.10:80.
Q6
192.168.1.10:25 for a secure web page → Port 25 is for SMTP email, not web pages. A secure web page uses HTTPS on port 443, so it should be 192.168.1.10:443.
Section C: Definitions
Q1
192.168.1.10:80 — An IP address followed by a port number. The IP finds the device and the port (80 = HTTP) tells it which service gets the data. Others: 443 HTTPS, 25 SMTP, 53 DNS.
Section D: Fill in the Blanks
Q1
192.168.1.10:80
Q2
192.168.1.10:80 192.168.1.10:443
Q3
192.168.1.20:25
Q4
8.8.8.8:53
Q5
192.168.1.10:80
Section E: Spot the Error
Q1
A — HTTP uses port 80. Port 443 is for HTTPS. The line should be HTTP: 192.168.1.10:80.
Q2
C — Email sent with SMTP uses port 25. Port 53 belongs to DNS. The line should be Mail: 192.168.1.20:25.
Q3
B — An https:// address is sent to port 443, because port 80 is plain HTTP. The line should be port = 443.
Q4
A — A port number is written after the IP address with a colon, not a semicolon. It should be 192.168.1.10:80.
Q5
B — DNS queries go to port 53. Port 25 is for SMTP email. The line should end in :53.