Triple DES

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

Triple DES

Name:
Date:
Class:

Quick Questions

Shade in the A or B circle for each question.

1. How many times does Triple DES apply the DES algorithm to each block?
A Three times
B Twice
2. Which sequence of steps does Triple DES use?
A Encrypt, decrypt, encrypt
B Encrypt, hash, encrypt
3. Why was Triple DES created?
A To replace DES with a faster cipher
B To lengthen the effective key and strengthen DES
4. How many keys can Triple DES use?
A Always exactly one key
B Two or three keys
5. Compared with AES, Triple DES is...
A Slower
B Faster

Match the Pairs

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

Left columnRight column
1ciphertext = E(k3, D(k2, E(k1, plaintext))) AThis applies DES only once with one key, so it is just ordinary DES and not Triple DES. Triple DES needs three passes (encrypt, decrypt, encrypt) with two or three keys.
2keys = [k1, k2, k1] BTwo-key Triple DES: the first and third DES passes reuse the same key.
3Triple DES is slower than AES because it runs the DES algorithm three times on every block. CTriple DES encryption: encrypt with key 1, decrypt with key 2, then encrypt with key 3.
4Using three different keys lengthens the effective key and strengthens DES. DtimeTripleDES = 3 * timeDES
5ciphertext = DES(plaintext, k1) # Triple DES ETriple DES is slower than AES, not faster. It runs DES three times, and extra keys do not make it quicker.
6Triple DES is faster than AES because it uses three keys Fkeys = [k1, k2, k3]

Definitions

Triple DES

Fill in the Blanks

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

1.
s1 = ENCRYPT(data, key1) s2 = _______(s1, key2) s3 = ENCRYPT(s2, key3)
2.
keys = [key1, key2, ____]
3.
keyBits = _ * 56
4.
IF time3DES _ timeAES THEN OUTPUT "Slower than AES" ENDIF
5.
FOR pass = 1 TO _ data = DES(data, keys[pass]) NEXT pass

Spot the Error

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

Question 1
A c1 = DES_enc(plain, k1)
B c2 = DES_enc(c1, k2)
C cipher = DES_enc(c2, k3)
Question 2
A k1 = new_key(56)
B k2 = k1
C k3 = k1
D c = TDES(plain, k1, k2, k3)
Question 3
A keys = 2
B bits = 56
C total = keys + bits
D OUTPUT total
Question 4
A p1 = DES_dec(cipher, k3)
B p2 = DES_dec(p1, k2)
C plain = DES_dec(p2, k1)
Question 5
A des_ops = 1
B tdes_ops = 3 * des_ops
C slowdown = des_ops / tdes_ops
D OUTPUT slowdown

Answer Key

Triple DES
Section A: Quick Questions
Q1
A — Three times
Q2
A — Encrypt, decrypt, encrypt
Q3
B — To lengthen the effective key and strengthen DES
Q4
B — Two or three keys
Q5
A — Slower
Section B: Match the Pairs
Q1
ciphertext = E(k3, D(k2, E(k1, plaintext))) → Triple DES encryption: encrypt with key 1, decrypt with key 2, then encrypt with key 3.
Q2
keys = [k1, k2, k1] → Two-key Triple DES: the first and third DES passes reuse the same key.
Q3
Triple DES is slower than AES because it runs the DES algorithm three times on every block. → timeTripleDES = 3 * timeDES
Q4
Using three different keys lengthens the effective key and strengthens DES. → keys = [k1, k2, k3]
Q5
ciphertext = DES(plaintext, k1) # Triple DES → This applies DES only once with one key, so it is just ordinary DES and not Triple DES. Triple DES needs three passes (encrypt, decrypt, encrypt) with two or three keys.
Q6
Triple DES is faster than AES because it uses three keys → Triple DES is slower than AES, not faster. It runs DES three times, and extra keys do not make it quicker.
Section C: Definitions
Q1
Triple DES — Applies DES three times (encrypt, decrypt, encrypt) with two or three keys to lengthen the effective key and strengthen DES. It is slower than AES.
Section D: Fill in the Blanks
Q1
s1 = ENCRYPT(data, key1) s2 = DECRYPT(s1, key2) s3 = ENCRYPT(s2, key3)
Q2
keys = [key1, key2, key1]
Q3
keyBits = 3 * 56
Q4
IF time3DES > timeAES THEN OUTPUT "Slower than AES" ENDIF
Q5
FOR pass = 1 TO 3 data = DES(data, keys[pass]) NEXT pass
Section E: Spot the Error
Q1
B — Triple DES uses encrypt-decrypt-encrypt. The middle step must decrypt with DES_dec, not encrypt again.
Q2
B — Two-key Triple DES needs two different keys, with k3 reusing k1. Setting k2 = k1 makes all three keys the same, so it is no stronger than single DES. k2 should be new_key(56).
Q3
C — Each extra DES key adds its own 56 bits, so the total key length is keys multiplied by bits, not added. It should be keys * bits.
Q4
B — Decrypting Triple DES reverses the steps: decrypt with k3, encrypt with k2, decrypt with k1. The middle step must be DES_enc.
Q5
C — Triple DES does three DES operations, so it is about 3 times slower. The slowdown is tdes_ops / des_ops. The reversed division gives 1/3, which would wrongly suggest it is faster.