MAC addresses are given at manufacture

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

MAC addresses are given at manufacture

Name:
Date:
Class:

Quick Questions

Shade in the A or B circle for each question.

1. When is a MAC address normally given to a network interface card (NIC)?
A When the user joins a network for the first time
B When the NIC is made, before it is sold
2. Who normally sets the MAC address of a NIC?
A The router on the network
B The manufacturer of the NIC
3. A student takes a laptop from school to home. What normally happens to the laptop's MAC address?
A It stays the same
B It changes to match the home network
4. Where is a MAC address stored?
A In the network interface card (NIC)
B In the router that the device connects to
5. Which address normally changes when a phone moves from school Wi-Fi to home Wi-Fi?
A The IP address
B The MAC address

Match the Pairs

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

Left columnRight column
1MAC address set at manufacture AA MAC address is not given by the router or the network. The manufacturer sets it when the NIC is made. (A router assigns IP addresses.)
2MAC address stored in the NIC Bfactory: NIC made -> MAC 00:1A:2B:3C:4D:5E shop: device sold -> MAC 00:1A:2B:3C:4D:5E
3A laptop moves from home Wi-Fi to school Wi-Fi, and its MAC address normally stays the same CThe address belongs to the network interface card inside the device, not to the network it joins
4The MAC address is assigned before the device is sold, so it is already fixed when you buy it DA MAC address normally stays the same on every network because it is stored in the NIC and set at manufacture.
5The router gives a device its MAC address when it joins the network Ehome_mac = 3C:5A:B4:1F:92:E7 school_mac = 3C:5A:B4:1F:92:E7
6A MAC address changes each time the device joins a different network FThe manufacturer gives the NIC its MAC address when it is made, before the device is sold

Definitions

MAC address set at manufacture

Fill in the Blanks

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

1.
nic ← NewNIC() nic.__________ ← "3C-52-82-1A-9F-04"
2.
macBefore ← nic.macAddress moveToNetwork("Cafe WiFi") OUTPUT macBefore _ nic.macAddress
3.
stage ← "manufacture" IF stage = "manufacture" ____ nic.macAddress ← "00-1A-2B-3C-4D-5E"
4.
CALL makeNIC() CALL ______(nic) CALL sellDevice(nic)
5.
network ← "School" network ← "Home" OUTPUT laptop.___.macAddress

Spot the Error

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

Question 1
A stage = "first login"
B mac = "00:1A:2B:3C:4D:5E"
C print("MAC set at", stage)
Question 2
A mac = "00:1A:2B:3C:4D:5E"
B network = "School WiFi"
C network = "Home WiFi"
D print("MAC:", network)
Question 3
A def join_network(mac, name)
B print("Joining", name)
C return mac
Question 4
A nic = "WiFi adapter"
B mac = "A4:5E:60:C1:22:9G"
C print(nic, "stores", mac)
Question 5
A mac = "00:1A:2B:3C:4D:5E"
B place = "NIC"
C if place = "NIC":
D print("MAC is kept here")

Answer Key

MAC addresses are given at manufacture
Section A: Quick Questions
Q1
B — When the NIC is made, before it is sold
Q2
B — The manufacturer of the NIC
Q3
A — It stays the same
Q4
A — In the network interface card (NIC)
Q5
A — The IP address
Section B: Match the Pairs
Q1
MAC address set at manufacture → The manufacturer gives the NIC its MAC address when it is made, before the device is sold
Q2
MAC address stored in the NIC → The address belongs to the network interface card inside the device, not to the network it joins
Q3
A laptop moves from home Wi-Fi to school Wi-Fi, and its MAC address normally stays the same → home_mac = 3C:5A:B4:1F:92:E7 school_mac = 3C:5A:B4:1F:92:E7
Q4
The MAC address is assigned before the device is sold, so it is already fixed when you buy it → factory: NIC made -> MAC 00:1A:2B:3C:4D:5E shop: device sold -> MAC 00:1A:2B:3C:4D:5E
Q5
The router gives a device its MAC address when it joins the network → A MAC address is not given by the router or the network. The manufacturer sets it when the NIC is made. (A router assigns IP addresses.)
Q6
A MAC address changes each time the device joins a different network → A MAC address normally stays the same on every network because it is stored in the NIC and set at manufacture.
Section C: Definitions
Q1
MAC address set at manufacture — A MAC address is set by the manufacturer when the NIC is made and stored in the NIC, so it normally stays the same on any network the device uses.
Section D: Fill in the Blanks
Q1
nic ← NewNIC() nic.macAddress ← "3C-52-82-1A-9F-04"
Q2
macBefore ← nic.macAddress moveToNetwork("Cafe WiFi") OUTPUT macBefore = nic.macAddress
Q3
stage ← "manufacture" IF stage = "manufacture" THEN nic.macAddress ← "00-1A-2B-3C-4D-5E"
Q4
CALL makeNIC() CALL setMAC(nic) CALL sellDevice(nic)
Q5
network ← "School" network ← "Home" OUTPUT laptop.nic.macAddress
Section E: Spot the Error
Q1
A — A MAC address is set by the manufacturer when the NIC is made, not at first login. The line should be stage = "manufacture".
Q2
D — The program should print mac to show that the MAC stays the same after the device moves networks. Printing network shows the wrong value.
Q3
A — A function definition must end with a colon. It should be def join_network(mac, name): so the MAC is returned unchanged.
Q4
B — A MAC address is written in hexadecimal, which only uses 0-9 and A-F. G is not a hex digit, so the last pair should be 9B.
Q5
C — A single = assigns a value. An if statement needs == to compare. The MAC address is stored in the NIC, so the test should be if place == "NIC":.