KS4J277 1.3.2 30 min read 10 question quiz 20 exam marks

Wired and Wireless Networks, Protocols and Layers

Wi-Fi against Ethernet, IP and MAC addressing, every protocol on the specification with what it actually does, and why layering makes the internet possible.

Wired and wireless

Wired, usually Ethernet

  • Faster and more consistent speeds
  • More secure, since an attacker needs physical access to the cable
  • More reliable, no interference from walls or other devices
  • Lower latency, important for gaming and video calls
  • But: devices cannot move, and installing cabling is expensive and disruptive

Wireless, Wi-Fi or Bluetooth

  • Convenient, devices can move freely
  • Cheaper and quicker to install, no cabling needed
  • Many devices can connect easily
  • But: slower and less reliable, signal weakens with distance and is blocked by walls
  • Less secure, since the signal travels through the air and can be intercepted, so encryption is essential
The trade off in one line

Wired networks offer speed, reliability and security. Wireless offers convenience, mobility and lower installation cost.

Bluetooth is short range wireless, typically under 10 metres, designed for connecting a small number of devices directly, such as headphones to a phone. Wi-Fi is longer range and higher bandwidth, designed to connect devices to a network.

An Ethernet cable and its RJ45 plugThe end of an Ethernet cable, showing the transparent RJ45 plug with eight coloured copper wires visible inside it, twisted into four pairs.four twisted pairseach pair twists around its partnerRJ45 plugclear plastic: eight wires insidecable jacketgold contactstouch the pins in the socket
The pairs are twisted to cancel out interference. That is the whole reason for the name twisted pair.Drawn illustration
Fibre optic cable with the jacket cut backFibre optic cable with the jacket cut back, showing hair thin glass strands carrying points of light at their ends.outer jacketprotects the glass insidestrengthening layerglass strandsas thin as a hairlight pulsesthe data travels as light
Light down glass, not electricity down copper. It goes further and faster and nothing electrical nearby can interfere with it.Drawn illustration

IP addresses and MAC addresses

IP address

An IP address identifies a device on a network and is used to route data between networks.

  • IPv4 uses 32 bits, written as four denary numbers 0 to 255, for example 192.168.1.24
  • IPv6 uses 128 bits, written as eight groups of hexadecimal, because IPv4 addresses have run out
  • IP addresses are assigned by the network and can change, for example each time you join a different Wi-Fi network

MAC address

A MAC address, media access control, identifies a specific piece of hardware.

  • 48 bits, written as six pairs of hexadecimal digits, for example 00:1B:44:11:3A:B7
  • Assigned by the manufacturer and does not change
  • Used by switches to deliver data within a local network
IP addressMAC address
IdentifiesA device on a networkA specific piece of hardware
Assigned byThe networkThe manufacturer
ChangesYes, can changeNo, it is fixed
Used forRouting between networksDelivery within a local network
Format192.168.1.24 or IPv6 hex00:1B:44:11:3A:B7
Both are needed

A common misconception is that one replaces the other. The IP address gets the data to the right network, and the MAC address then gets it to the right device on that network.

A network interface cardA network interface card: a small circuit board with an Ethernet socket on its metal bracket and a controller chip on the board.CONTROLLER3C:22:FB:9A:41:7EEthernet socketthe cable plugs in herecontroller chipturns data into signalsMAC addressburned in at the factorygold edge connectorplugs into the motherboard
Every device on a network needs one of these, and the MAC address is burned into it at the factory.Drawn illustration
The same laptop on two networks: its MAC address stays, its IP address changesA laptop with a MAC address, 3C:22:FB:9A:41:7E, burned in by the manufacturer. At home the network gives it the IP address 192.168.1.23. At school the network gives it a different IP address, 10.4.7.52. The MAC address stays the same on both networks, but the IP address changes whenever it joins a different network. A table compares them. A MAC address is assigned by the manufacturer, never changes, looks like six pairs of hex digits and is 48 bits long, and is used for delivery inside one network. An IP address is assigned by the network, changes when you change network, is four numbers or 32 bits in IPv4, and is used for routing between networks.MAC 3C:22:FB:9A:41:7Eburned in by the manufacturerAt homethe network gives itIP 192.168.1.23At schoolthe network gives itIP 10.4.7.52same laptop, two networksMAC addressIP addressAssigned bythe manufacturerthe networkChanges?neverwhen you change networkLooks like6 hex pairs, 48 bits4 numbers, 32 bits (IPv4)Used fordelivery inside one networkrouting between networks123
  1. The MAC address belongs to the hardware, so it stays the same wherever the laptop goes.
  2. The IP address is given by the network, so the same laptop has a different one at home and at school.
  3. MAC: manufacturer, never changes, local delivery. IP: network, changes, routing between networks.
Think of the MAC address as a serial number and the IP address as a postal address.

Standards and protocols

A standard is an agreed way of doing something, so that hardware and software from different manufacturers can work together.

A protocol is a set of rules governing how data is transmitted between devices. Without shared protocols, two computers would be talking different languages.

ProtocolFull nameWhat it does
TCPTransmission Control ProtocolSplits data into packets, checks they all arrive, requests any that are missing, and reassembles them in the right order
IPInternet ProtocolAddresses and routes packets across networks so they reach the right destination
HTTPHypertext Transfer ProtocolRequests and transfers web pages between a browser and a web server
HTTPSHTTP SecureThe same as HTTP but the data is encrypted, protecting it from being read if intercepted
FTPFile Transfer ProtocolSends and receives files between computers, typically uploading to a server
POPPost Office ProtocolRetrieves email from a server and normally deletes it from the server
IMAPInternet Message Access ProtocolRetrieves email but keeps it on the server, so it syncs across multiple devices
SMTPSimple Mail Transfer ProtocolSends email from a client to a server, and between mail servers
The email trio

SMTP sends. POP downloads and removes. IMAP downloads and keeps synced. If a question mentions reading the same emails on a phone and a laptop, the answer is IMAP.

TCP/IP working together

TCP and IP are almost always used as a pair.

  • TCP handles the reliability: breaking data into packets, numbering them, checking they arrive and reassembling them.
  • IP handles the addressing: making sure each packet is routed to the correct destination.
Packet switching across a networkA message travelling across a packet switched network. The sender on the left splits the message into numbered packets. Five routers, R1 to R5, sit between the sender and the receiver, joined by several possible links. Packet 1 travels the northern route through R1 and R4. Packet 2 travels the southern route through R2 and R5. Packet 3 takes a third route through R2, R3 and R4. Because each packet is routed independently according to which links are free at that moment, packets can arrive in a different order from the one they were sent in. Every packet carries a sequence number, so the receiver on the right can put them back into the right order and rebuild the message, and can request any packet that never arrived.Sendersplits the messageReceiverreassembles itR1R2R3R4R5packet 1packet 2packet 3Packets take whatever route is free, so they can arrive out of order.Each one carries a sequence number, so the receiver can rebuild the message in order.
The exam answer is: split into packets, each routed independently by the fastest free path, reassembled in sequence number order at the end.
Packet switching: a photo split into numbered packets that take different routesA message is far too big to send as one lump, so the sender splits it into packets: a three megabyte photograph becomes roughly two thousand of them. The picture shows four. Each packet carries the destination address, the address it came from, its own sequence number and a slice of the data, plus a checksum used to spot corruption. Each router it reaches reads the destination and chooses the next hop for itself, so packets from the same message can take different routes: in the picture a failed link is crossed out and one packet has gone around it. The packets arrive out of order, and the sequence numbers let the receiving computer put them back together into the complete photo. Nothing reserves a line for the whole message.routerrouter4123Sender1234Inside one packetTo93.184.216.34From81.2.69.160Number2 of 4Checkchecksuma slice of the photoReceiverArrive in any order2143numbers put them back1234each router chooses the next hop for itself1234
  1. Your message is too big to send in one go, so it is split into packets.
  2. Every packet carries the destination address and its own number.
  3. Each router picks the next hop, so packets can take different routes, even around a broken link.
  4. They arrive out of order, and the numbers put them back together.
Nothing reserves a line for you. Every packet is handled on its own, and that is why the internet copes when part of it fails.
How an email travels, and the difference between POP and IMAPThe journey of an email. The sender's laptop uses SMTP to send the message to the sender's mail server. SMTP is used again to pass it to the recipient's mail server. The recipient then collects it with POP or IMAP. Below, the two ways of collecting mail are compared. With POP the mail is downloaded to one device and then removed from the server, so it only exists on the device that downloaded it. With IMAP the mail stays on the server and every device, such as a phone and a laptop, shows the same mailbox, so they stay in sync.sendersender's mail serverrecipient's mail serverrecipientSMTPSMTPPOP or IMAP1POP: download, then deletemail serverone laptopdownloadremoved from the servermail is only on the device that downloaded itgood for: one device, little storage2IMAP: keep it on the servermail serverevery devicesame mailkept on the serverevery device shows the same mailboxgood for: phone and laptop together3
  1. SMTP sends email, from the sender to their server and between mail servers.
  2. POP downloads mail and normally deletes it from the server, so it lives on one device.
  3. IMAP keeps mail on the server, so a phone and a laptop both show the same mailbox.
SMTP sends. POP downloads and removes. IMAP keeps it on the server and in sync. Two devices means IMAP.

Layers

Network protocols are organised into layers. Each layer has a specific job and only interacts with the layers directly above and below it.

The four layer TCP/IP model:

LayerJobExample protocols
ApplicationProvides services to the user's softwareHTTP, HTTPS, FTP, SMTP, IMAP
TransportSplits data into packets and ensures reliable deliveryTCP, UDP
InternetAdds addresses and routes packets across networksIP
LinkHandles the physical transmission over the mediumEthernet, Wi-Fi

Why layering is used

  • It breaks a complex problem into manageable parts, so each layer can be designed and understood separately.
  • Layers can be changed independently. Switching from copper to fibre changes only the link layer, and everything above it carries on unchanged.
  • It allows interoperability, because manufacturers only need to follow the rules of the layer they are working in.
  • It makes fault finding easier, since a problem can be isolated to one layer.
  • Different protocols can be used at the same layer without affecting the rest, for example choosing IMAP instead of POP.
The exam answer

Layers divide the complexity of network communication into self contained parts, so each layer can be developed, changed or replaced without affecting the others.

The four layer TCP/IP model and packet encapsulationThe four layer TCP/IP model, drawn top to bottom with the growing packet beside it. The application layer handles protocols such as HTTP, HTTPS, FTP, SMTP and IMAP, and produces the raw data. The transport layer, using TCP, splits that data into packets and adds a header carrying port numbers, so the packet is now a TCP header followed by data. The internet layer adds an IP header carrying the source and destination IP addresses, so the packet is an IP header, a TCP header and the data. The link layer, Ethernet or Wi-Fi, adds a frame header carrying MAC addresses and a frame end, giving frame header, IP header, TCP header, data, frame end. Each layer wraps the one above it in its own header, and the receiving computer unwraps the layers in reverse order.ApplicationHTTP, HTTPS, FTP, SMTP, IMAPTransportTCP splits data into packets, adds port numbersInternetIP adds source and destination IP addressesLinkEthernet or Wi-Fi, adds MAC addressessendingDataTCPDataIPTCPDataFrameIPTCPDataEndeach layer wraps the layer above in its own headerthe receiver unwraps them in the reverse order
Layers are independent. Changing from Wi-Fi to Ethernet swaps the link layer only, and nothing above it has to change.
The TCP/IP model: a message wrapped on the way down and unwrapped on the way upTwo stacks of four layers, the sender's on the left and the receiver's on the right, with the data between them. At the application layer, where HTTP, HTTPS, SMTP, IMAP and FTP live, the data is just the message. The transport layer splits it into segments and adds a TCP or UDP header carrying the port number. The internet layer wraps each segment in a packet and adds the source and destination IP addresses used for routing. The link layer wraps the packet in a frame carrying MAC addresses and a check value, and puts it on the cable or the wireless link. At the receiving computer the same four layers run in reverse: each strips off the wrapper it recognises and hands the rest up, so the application receives exactly the message that was sent. No layer needs to know how another layer does its job, which is the whole reason the model is split up this way.chatSenderchatReceiverWhat is on the wireApplicationHTTP · SMTP · DNSApplicationshows the pageDATAmessage80TransportTCP · UDP · ports80Transportputs the pieces in orderTCPDATAsegmentInternetIP · addressesInternetchecks it is for meIPTCPDATApacketLinkWi-Fi · Ethernet · MACLinkreads the frameMACIPTCPDATAFCSframecable or Wi-Fi: bits on the wire12345
  1. Your message starts at the top, in the application.
  2. Transport splits it into segments and adds a port number.
  3. Internet wraps each segment in a packet and adds IP addresses.
  4. Link turns the packet into a frame with MAC addresses, and it goes out.
  5. At the other end the same four layers run in reverse, unwrapping it.
Each layer wraps what the layer above handed it, and knows nothing about what is inside. That is why you can change the wifi for a cable without rewriting the web browser.

Key terms you must be able to define

Protocol
A set of rules governing how data is transmitted between devices.
Standard
An agreed specification that allows equipment from different manufacturers to work together.
IP address
An address identifying a device on a network, used to route data between networks.
MAC address
A unique address assigned to network hardware by its manufacturer, used within a local network.
TCP
Transmission Control Protocol. Splits data into packets and guarantees they arrive and are reassembled correctly.
IP
Internet Protocol. Addresses and routes packets across networks.
HTTPS
The encrypted version of HTTP, protecting web traffic from being read if intercepted.
SMTP
The protocol used to send email.
POP
A protocol that retrieves email and normally deletes it from the server.
IMAP
A protocol that retrieves email while keeping it on the server so it syncs across devices.
Layer
A distinct level of network functionality with a defined job, interacting only with adjacent layers.

Flashcards

Say the definition out loud before you flip the card. Retrieving it from memory is what builds recall, reading it again is not.

DefineProtocol
AnswerA set of rules governing how data is transmitted between devices.
DefineStandard
AnswerAn agreed specification that allows equipment from different manufacturers to work together.
DefineIP address
AnswerAn address identifying a device on a network, used to route data between networks.
DefineMAC address
AnswerA unique address assigned to network hardware by its manufacturer, used within a local network.
DefineTCP
AnswerTransmission Control Protocol. Splits data into packets and guarantees they arrive and are reassembled correctly.
DefineIP
AnswerInternet Protocol. Addresses and routes packets across networks.
DefineHTTPS
AnswerThe encrypted version of HTTP, protecting web traffic from being read if intercepted.
DefineSMTP
AnswerThe protocol used to send email.

Reach the top grade on this topic

Two things earn the top marks here.

Never define a protocol as 'a set of rules' and stop. Every protocol is a set of rules. Say what the rules are for. TCP is the set of rules for splitting data into packets and ensuring they arrive complete and in order.

On layering, give a consequence not just a description. The strongest phrasing names a change and says what is unaffected: "Because Wi-Fi and Ethernet both sit at the link layer, a network can switch from cable to wireless without any change to HTTP, TCP or IP above it."

The email protocols come up almost every year, and the discriminator is IMAP against POP. Learn the scenario: multiple devices means IMAP.

  • Match all eight protocols to their function without hesitation
  • Explain the IP against MAC distinction using assignment and purpose, not just format
  • Give three benefits of layering, each with a consequence
  • Choose wired or wireless for a scenario and justify with the specific constraint in the question

Mistakes that cost marks here

Avoid these
  • Saying HTTPS 'is more secure' with no mechanism. It encrypts the data so that intercepted traffic cannot be read.
  • Saying POP and IMAP send email. They retrieve it. SMTP sends.
  • Saying a MAC address can be assigned by the network. It is set by the manufacturer.
  • Describing layers as 'to make it faster'. Layering is about manageability and interoperability, not speed.
  • Giving TCP the job of addressing. TCP handles packets and reliability, IP handles addressing and routing.
Fun fact

Your MAC address is burned into the network card at the factory and the first half identifies the manufacturer. Given only a MAC address, you can look up who made the device, which is why some phones now randomise it for privacy.

Knowledge check

0 of 10 answered
1Which protocol is responsible for splitting data into packets and ensuring they all arrive?
2Which protocol is used to send an email?
3A user reads the same emails on their phone and laptop and wants them to stay in sync. Which protocol should be used?
4Which statement about MAC addresses is correct?
5What is the main advantage of HTTPS over HTTP?
6Why are network protocols organised into layers?
7Which is an advantage of a wired connection over wireless?
8Which protocol is used to transfer files to a web server?
9An IPv4 address is how many bits long?
10At which layer would you find HTTP and SMTP?
Score 0 / 10

Exam-style questions

Five written questions in the style of the real paper. Write a full answer, then let the marker check it against the mark scheme.

20 marks
1State what is meant by a protocol.2 marks
State

Mark scheme0 / 2
  • LA set of rules
  • LGoverning how data is transmitted or communicated between devices
Model answer

A protocol is an agreed set of rules that governs how data is transmitted and communicated between devices on a network, covering things such as how the data is formatted, how it is addressed and how errors are handled, so that different systems can understand each other.

The marker looks for key phrases. If you said it another way and it is still right, give yourself the mark.
2Explain two differences between an IP address and a MAC address.4 marks
Explain

Mark scheme0 / 4
  • LAn IP address identifies a device on a network, a MAC address identifies a specific piece of hardware
  • LIP addresses are assigned by the network, MAC addresses by the manufacturer
  • LAn IP address can change, a MAC address is fixed
  • LIP addresses route data between networks, MAC addresses deliver data within a local network
Model answer

The first difference is what they identify and who assigns them. An IP address identifies a device's position on a network and is assigned by the network itself, which means it can change, for example when a laptop joins a different Wi-Fi network. A MAC address identifies one specific piece of network hardware, is assigned by the manufacturer when the network interface card is made, and does not change. The second difference is their purpose. IP addresses are used to route data between different networks across the internet, whereas MAC addresses are used by switches to deliver data to the correct device within a single local network once it has arrived.

The marker looks for key phrases. If you said it another way and it is still right, give yourself the mark.
3Explain why network protocols are organised into layers.4 marks
Explain

Mark scheme0 / 4
  • LIt breaks a complex process into smaller self contained parts
  • LEach layer has a specific role and only interacts with adjacent layers
  • LA layer can be changed or replaced without affecting the others
  • LIt allows equipment and software from different manufacturers to work together
Model answer

Network communication is a very complex process, and layering divides it into smaller self contained parts so that each part can be designed, understood and maintained separately. Each layer is given one specific responsibility and only interacts with the layers immediately above and below it, which means a layer can be changed or replaced entirely without the rest of the stack being affected. For example, a network can switch from Ethernet cabling to Wi-Fi at the link layer while HTTP, TCP and IP continue to work exactly as before. Layering also allows manufacturers to build hardware and software that only has to comply with the rules of one layer, which means equipment from different companies can interoperate, and it makes fault finding easier because a problem can be isolated to a single layer.

The marker looks for key phrases. If you said it another way and it is still right, give yourself the mark.
4A hotel is installing a network for its guests. Discuss whether it should use a wired or a wireless network.6 marks
Discuss

Mark scheme0 / 6
  • LRecommends wireless
  • LGuests need mobility and use their own devices in rooms and public areas
  • LCheaper and less disruptive than running cable to every room
  • LWireless is slower and less reliable, with signal weakened by walls and distance
  • LWireless is less secure as the signal can be intercepted, so encryption is essential
  • LReaches a justified conclusion, possibly a hybrid with wired backbone
Model answer

The hotel should provide a wireless network for guests. Guests arrive with their own phones, tablets and laptops and expect to use them in their rooms, in the lobby and in the restaurant, so mobility is essential and a wired connection that ties a device to one socket would not meet that need. Installing wireless access points is also considerably cheaper and far less disruptive than running Ethernet cable to every guest room in an existing building, where floors and walls would have to be opened up. There are real disadvantages. Wireless is slower and less consistent than cable, and the signal is weakened by the thick walls and long corridors typical of hotels, so careful placement of multiple access points is needed to avoid dead spots. It is also less secure, because the signal travels through the air and can be intercepted by anyone in range, so strong encryption such as WPA3 and an isolated guest network are necessary to stop guests seeing each other's traffic or reaching the hotel's own systems. The sensible solution is a hybrid: a wired backbone connecting the access points, the reception computers and the booking system, since those machines never move and benefit from the speed and security of cable, with wireless provided throughout the building for guests. This gives guests the mobility they expect while keeping the hotel's own critical systems on the faster and more secure wired network.

The marker looks for key phrases. If you said it another way and it is still right, give yourself the mark.
5Describe the roles of the TCP and IP protocols and explain why they are used together.4 marks
Describe

Mark scheme0 / 4
  • LTCP splits data into packets and numbers them
  • LTCP checks all packets arrive and reassembles them in the correct order
  • LIP addresses each packet and routes it to the correct destination
  • LTogether they provide addressing and reliable delivery, which are both needed
Model answer

TCP, the Transmission Control Protocol, takes the data being sent and splits it into numbered packets. At the receiving end it checks that every packet has arrived, requests the retransmission of any that are missing or corrupted, and then reassembles the packets back into the original data in the correct order. IP, the Internet Protocol, is responsible for addressing: it attaches the source and destination IP addresses to each packet and determines the route the packet should take across the networks between them. They are used together because each solves only half the problem. IP can get a packet to the right destination but offers no guarantee that it arrives or that packets arrive in order, while TCP can guarantee complete, correctly ordered delivery but has no mechanism for finding the destination in the first place. Combined as TCP/IP they provide both reliable delivery and correct routing.

The marker looks for key phrases. If you said it another way and it is still right, give yourself the mark.
Machine mark 0 / 20