Twofish
A symmetric block cipher and Blowfish's successor. It encrypts 128-bit blocks with keys up to 256 bits and was a finalist in the competition that chose AES.
Understanding Twofish in QCE Digital Solutions Unit 4
What it does: The list shows Twofish as an AES competition finalist, alongside the algorithm (Rijndael) that was chosen as AES. The same key is used in both encrypt() and decrypt(), which is how symmetric ciphers like Twofish work. Twofish uses 128-bit blocks. Blowfish, its predecessor, used 64-bit blocks. Twofish accepts keys up to 256 bits. A 56-bit key is the weak size used by DES. Twofish is symmetric, so sender and receiver share one secret key. This is why key sharing is the main risk. This is a wrong value for the block size. It should be 128 because Twofish encrypts 128-bit blocks.
Common mistakes: Twofish encrypts 128-bit blocks. 64-bit blocks belong to older ciphers such as Blowfish and DES. The line should be block_bits = 128. Twofish keys can be up to 256 bits, not 512. The line should be max_bits = 256.
Free printable worksheet with full answer key — or add this module to a class and your students practise it interactively.
This module's key terms are also in a printable crossword (Modules 17–88) and word search (Modules 17–125).
Take this worksheet further — free with Cloodit
Each concept is reinforced from every angle — learned, then applied, then tested.
Cloodit turns curriculum-aligned coding content into journeys students work through one biome at a time.
Over 100 of them, across seven natural biomes.
Turns their work into revision material ready for Flash Cards and Exam study.
Live, competitive practice for the start of the lesson or a teacher-led lesson finisher.
Honour your top performers, or encourage a student who's trying hard — ready to print in seconds.
Quick Questions
Match the Pairs
Key Term
TwofishFill in the Blanks
Spot the Error
Student with a class code? Join your class →