

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!


CIS 3360 Homework 3 Due Date: September 27 Worth: 4% 1) A value g is known as a primitive root of a prime p if and only if the smallest positive integer n for which gn^ ≡ 1 (mod p) is n = p-1. Write a short C program that prompts the user for the value of p and prompts the user for the value of g and prints out whether or not g is a primitive root of p. Simply implement a brute force algorithm that successively computes g^1 (mod p), g^2 (mod p), etc. You may also write a function that checks to see whether or not the value entered by the user is prime. Simply turn in a printout of your source code. 2) The idea of hierarchical key control was briefly introduced in class. In this sort of system, if A wants to communicate with B, it may be the case that a different KDC has access to communication with B than with A. Sketch out the set of steps that would be necessary for A to obtain a secret key with which to communicate with B through a system of hierarchical key control. Keep the following sample situation in mind where A, B, …, J are end users and there are three KDCs arranged in a hierarchical structure as shown below, while putting together your protocol: Global KDC /
Local-1 KDC Local-2 KDC / / | \ \ / / | \
A C D E F G B H I J Also describe the keys that each of the three KDCs in the diagram above actually have access to. 3) Consider the following protocol for sending a plaintext M between A and B: a) A sends B the message (A, EB( M), B), b) B answers A with the message (B, EA(M), A). Can an adversary Z break this protocol? If yes then write the steps via which the adversary breaks this protocol. 4) Consider the following mutual authentication protocol in which two parties A and B authenticates each other by exchanging four messages:
The rest of the variables are as follows: N1, N2 = randomly generated numbers called Nonce. A, B = IDs of parties A and B. K = a symmetric-key already shared between A and B. A successfully authenticates B upon receiving the fourth message. B successfully authenticates A upon receiving the third message. Since K is a key already shared between parties A and B only, whoever encrypts a message using K assures that he/she possesses K, thereby gets authenticated. After sending its nonce, a participant waits for the response, that is, an encrypted message containing that nonce. Upon receiving the response, the participant simply decrypts it and compares it with the nonce it has previously sent for authentication. A match in the nonce values guarantees that authentication is achieved. Find an attack in the protocol such that a participant without the possession of key K could get authenticated. Hint: A participant has no mechanism to check whether N1=N2. 5) Needham and Schroeder suggest the following variant of their protocol: