GCSE · Computer Science · Eduqas · Spec C500QS
Encryption
Anything you send across a network could be copied on the way. So how can it be copied and still stay private?
Computer Science · Encryption
Be the encryption algorithm
You are the algorithm. Pick a run, then call each marked step before it appears. Move letters along the alphabet: A to B is one place.
text = input("Message: ")key = input("Key (a number): ")mode = input("encrypt or decrypt? ")result = ""for each letter in textif mode == "encrypt" thenresult = result + (letter moved forward key places in the alphabet)elseresult = result + (letter moved back key places in the alphabet)endifnext letterprint(result)
Variables
Step 1. The message (the plaintext) is stored in text. This first step is worked for you.
Computer Science · Encryption
Same ciphertext, different hands
Choose what the person holding the ciphertext has.
What they have
4 possible holders.
The ciphertext never changes. Pick who is holding it and see what they can do.
WHAT YOU'VE LEARNED
A quick recap of today's lesson.
How data can be taken and still stay private
What you need to know
- Encryption protects data by keeping it confidential, so only intended, authorised people can understand it.
- Plaintext is readable data. Ciphertext is the scrambled, unreadable version of it.
- An encryption algorithm and a key together turn plaintext into ciphertext.
- The key is a value the algorithm uses. Encrypt the same data with a different key and you get different ciphertext.
Have a goPriya says: "I encrypted my message twice, with two different keys, so the ciphertext must be identical. The message never changed!" Is Priya right?
No. Two different keys give two different ciphertexts.
The message stays the same, but the key is something the algorithm uses, so changing the key changes what comes out.
- Decryption is the reverse process: it turns ciphertext back into the original plaintext, and it needs the correct key.
Have a goYou hold ciphertext and you know which algorithm was used, but you try the wrong key. Do you get the original plaintext back?
No. Decryption needs the correct key.
Knowing the process is not enough: only the correct key reverses the encryption.
- Encryption does not stop data being intercepted or stolen. It makes whatever is taken meaningless without the key.
Have a goA thief copies an encrypted file off a laptop. Has encryption stopped the theft, or changed what the thief ended up with?
It changed what the thief has: they hold the file, but it is meaningless without the key.
Encryption does not stop data being stolen; it protects by making whatever is taken meaningless without the key.
- The key must be kept secret from unauthorised people, because anyone who obtains it can decrypt the data.
- In storage, if a device or files are lost or stolen, the encrypted contents cannot be read without the key.
- In transit, data can be intercepted on its way. The interceptor cannot understand it, but the recipient with the correct key can decrypt it.
The big picture
Encryption protects data by scrambling readable plaintext into unreadable ciphertext using an algorithm and a key. Without the correct key, whoever intercepts or steals the ciphertext cannot understand it, but the intended person with the correct key can decrypt it. It protects data in storage and in transit, and it only works while the key is kept secret.
Key points
Worked example
Problem
Using the letter-moving algorithm from the activity (move each letter forward by the key), encrypt BED with key 4. Then decrypt the ciphertext once with key 4 and once with key 1. What do you get each time?
⚠ Watch out
Thinking encryption means data cannot be stolen or intercepted. It can still be taken. The point is that what is taken is ciphertext, which is meaningless without the key.
Memory hook
The algorithm is the method; the key is the secret that changes the result. Lose control of the key and you lose the protection.
Check yourself
Cover the page. In your own words, say what the algorithm does, what the key does, and what a stranger holding only the ciphertext cannot do.
Flashcards
(11)What is the aim of encryption?
What is plaintext?
What is ciphertext?
What does an encryption algorithm do?
What is a key?
Same data, different key. What changes?
What is decryption?
Does encryption stop data being stolen or intercepted?
Why must the key be kept secret?
Why does encryption protect stored data?
Why does encryption protect data in transit?
Tap any card to flip it, or use Study as deck to go through them one at a time. In the full lesson these run as a spaced-repetition deck — you rate each card Hard, Good or Easy and the tricky ones keep coming back until they stick.
Learning with Lightbulb is opening soon
You can use this lesson now. Join the waitlist and we'll let you know when the full Lightbulb experience is ready.
Keep me postedMore Eduqas GCSE Computer Science topics
How this lesson was checked. This Eduqas GCSE Computer Science (specification C500QS)lesson was published through Lightbulb Learning's human-designed editorial process — the educational standards, accuracy rules and publication checks it must pass were authored and approved by Philip Halpin. It passed subject-specific assessment, automated educational checks and technical publication verification before going live (publication checks completed 15 November 2026). Published pages are monitored, human spot-checking is ongoing across the lesson library, and anything found wrong is corrected or withdrawn. How our lessons are made and checked. Spotted a mistake? Email hello@lightbulblearning.co and we'll review it.