Implementation of TEA Encryption Algorithm

(!!This is a graded assignment and is worth 25% of final grade)
Implement the Tiny Encryption Algorithm (TEA) using any preferred programming language.
a. Use your TEA algorithm to encrypt the 64-bit plaintext block
Plaintext 1 : 0x0123456789ABCDEF
using the 128-bit key
Key 1 : 0xA56BABCD00000000FFFFFFFFABCDEF01
Decrypt the resulting ciphertext and verify that you obtain the original
plaintext. Follow the same procedure for the below plaintexts and keys.
x Plaintext 2 : 106859140693170989536793383318618451778 (decimal)
o Key 2 : 50645267556B58703273357638792F42
x Plaintext 3 : Passwords are like underwear: don’t let people see it, change it
very often, and you shouldn’t share it with strangers
o Key 3 : 7336763979244226452948404D635166
b. Using the key in part a, encrypt and decrypt the following messages using each of
the three block cipher modes discussed in the course.
(ECB mode, CBC mode, and CTR mode).
Message 1 : Four score and seve n years ago our fathers brought forth on this
continent, a new nation, conceived in Liberty, and dedicated to the proposition
that all men are created equal.
Message 2 : Your time is limited, so don’t waste it living someone else’s life. Don’t
be trapped by dogma, which is living with the results of other people’s thinking.
For your submission, please prepare a 10 minutes recording of your presentation/
demonstration regarding your implementation. The recorded presentation should

  • 5 minutes discussion on your implementation on the source code of the
    algorithm for encryption and decryption. (i.e. Explain how you coded the
    encryption and decryption functions of TEA with the key integration)
  • 5 minutes presentation of your results for (a) and (b) (demonstration of
    algorithm execution)
    Submission : Please submit the executable files of your application and the recorded
    presentation/ demonstration in Brightspace before 19th October 10 am.

Exercise Sheet 3
Dr. Anca Jurcut Page 2
Submissions received after the deadline will be subjected to penalties. The penalties for late
submission are as follows:
x Less than 15 minutes past the deadline – no penalty.
x Greater than 15 minutes and less than 2 hou rs past the deadline – loss of 25% of the final
x Greater than 2 hours past the deadline – loss of 50% of the final mark.

Sample Solution