Tutorial1
Tutorial1
Q1) Using the extended Euclidean algorithm, find the greatest common
divisor of the
following pairs.
a. 4 and 7
b. 291 and 42
Solution
a. 38
b. 7
Q4) A small private club has only 100 members. Answer the following
questions:
a. How many secret keys are needed if all members of the club need to
send secret
messages to each other?
b. How many secret keys are needed if everyone trusts the president of
the club? If a member needs to send a message to another member, she
first sends it to the president; the president then sends the message to
the other member.
c. How many secret keys are needed if the president decides that the two
members who need to communicate should contact him first. The
president then creates a temporary key to be used between the two. The
temporary key is encrypted and sent to both members.
Q5) Encrypt the message “this is an exercise” using one of the following
ciphers. Ignore
the space between words. Decrypt the message to get the original
plaintext.
a. Additive cipher with key = 20
b. Multiplicative cipher with key = 15
c. Affine cipher with key = (15, 20)
Q6) Use the Playfair cipher to encipher the message “The key is hidden
under the door
pad”. The secret key can be made by filling the first and part of the
second row
with the word “GUIDANCE” and filling the rest of the matrix with the rest
of the
alphabet.
Q7) Encrypt the plain text “HELP” using the hill cipher using following
key, also show the decryption