Cryptography Final Quiz Answer
Final Quiz
Q1) What was your favorite part of this class?
- Learning about Hash And Encrypt
Q2) What is the most appropriate cryptographic primitive to use if a company wants to distribute authenticated software updates to its customers?
- Message authentication code.
- Pseudorandom function/block cipher.
- Hash function.
- Digital signature scheme.
- Public-key encryption scheme.
Q3) What is the most appropriate cryptographic primitive to use if an individual wants to ensure confidentiality of the files stored on her hard drive?
- Message authentication code.
- Private-key encryption.
- Hash function.
- Pseudorandom function/block cipher.
- Public-key encryption.
Q4) A user wants to design a CPA-secure public-key encryption scheme to be used for emailing large files. Of the following, which would be the best approach?
- To encrypt a file M, hash the file to a short value h = H(M), and then encrypt h using El Gamal encryption.
- To encrypt a file M break it into a sequence of blocks M1, M2, .... Then encrypt each block independently using El Gamal encryption.
- To encrypt a file, use El Gamal encryption to encrypt a random AES key; then use AES (with that key) in CBC mode to encrypt the file.
- To encrypt a file Muse DSS to encrypt a random key, and then use that key to encrypt M using HMAC
Q5) Consider the following "hybrid" signature scheme, which will give better efficiency when signing long messages. To sign message M using private key sk, choose a uniform keyk for a message authentication code and then sendk, Sign. (k), Mac (M). Verification is done in the natural way. Which of the following is true regarding this scheme?
- This is a secure signature scheme, if the underlying signature scheme and MAC are secure.
- This is not secure because given k, Sign.:(k), Mac (M) an attacker can forge k, Sign. (k), Mac (M') on any M' of its choice.
- This is not secure because it is very likely that a key k will be used twice by the signer.
- This is not secure because given the message/signature pair (k, Sign, (k)) an attacker can easily forge Sign.:(K) on a key k' of its choice.
Q7) Let G be a group, and consider the following private-key encryption scheme with message space G: The shared key is a uniform element k = G. To encrypt a message me G using key k, output the ciphertext k. m. To decrypt a ciphertext c E G using key k, output the message k-1.c. Which of the following is true about this scheme?
- The scheme is CCA-secure.
- The scheme is perfectly secret.
- The scheme is CPA-secure, but not CCA-secure.
- The scheme is computationally indistinguishable, but not perfectly secret.
Q7) Consider hybrid encryption using plain RSA and AES-128 in CTR mode, with public key N, e. Say a 128-bit message m is encrypted, ylelding ciphertext C, Co, C, with c e Zy and Co, € {0, 1}128. Which of the following would be an encryption of ñthe bitwise complement of m?
- C1, C0, C1.
Q8) Say El Gamal encryption is used in the subgroup of Zor generated by 4. The public key is 21 and the private key is 4. The ciphertext (34, 42) is an encryption of some message m. Which of the following is an encryption of 4m mod 47?
- (34, 27)
- (42, 42)
- (42, 27)
- (34,46)
Q9) Consider the plain RSA encryption scheme with public key N = 55, e = 3. Say the encryption of some unknown message m Is 6. What Is the encryption of [2m mod N]?
- 31
- 48
- 3
- 12
Q10) Say you have "oracle access to a plece of code that, given a message m, appends an unknown 8-byte password p, applies PKCS #7 padding, and then encrypts the result using AES-128 in ECB mode with an unknown key. Which of the following attacks can be used to confirm that the first byte of p is 'Z?
- Submit the 16-byte message "ZZZZZZZZZZZZZZZZ," and check whether the first byte of the first block of the resulting ciphertext is equal to the first byte of the second block of that ciphertext.
- Submit the null message and check whether the first byte of the ciphertext is equal to 'Z'.
- Submit the 15-byte message "ABCDEFGHIJKLMNO" and the 16-byte message "ABCDEFGHIJKLMNOZ," and check If the first blocks of the resulting ciphertexts are equal.
- Submit the 1-byte message "Z" and check whether any two bytes in the resulting ciphertext are equal.
2 Comments
What is the most appropriate cryptographic primitive to use if an individual wants to ensure confidentiality of the files stored on her hard drive?
ReplyDeletePrivate-key encryption.
very helpful article for me
ReplyDelete