FINAL EXAM Flashcards

(43 cards)

1
Q

What is the difference between stream and block ciphers?

A

Stream cipher encrypts one element at a time.

Block Ciphers encrypts encrypt the plaintext multiple elements at time

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is confusion ?

A

obscures the relationship between the key and ciphertext

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is diffusion?

A

obscures the relationship between the plaintext and the ciphertext

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Why are confusion and diffusion important when designing a block cipher? Give an example

A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

How is confusion achieved?

A

through substitution , replacing elements of plaintext with elements of cipher text

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Consider a block cipher with a property where if one bit of the key changes,
many bits of the ciphertext change. Is this example of confusion or diffusion? Explain

A

Confusion, since its obscuring the relationship between the key and cipher text

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

How is diffusion achieved?

A

through premutation, shuffling the elements up.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What makes a block cipher reversible?

A

Each block of plaintext must give you a distinct block of cipher text.

Example:
00 -> 11
01 -> 10
10 -> 00
11 -> 01

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

How many possible keys can I have in an ideal block cipher which encrypts
64-bit text blocks?

A

(2^64)!

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is the size of the key in a 64-bit ideal block cipher?

A

64 * (2^64)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

How does Feistel cipher perform substitution and permutation

A

Substitution is applied on the left half,

permutation occurs when we swap the two half’s

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What are the advantages of the Feistel cipher network?

A

Encryption and decryption are very smilar

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Consider binary key string:
0011000110110111000000111001111011101111000010100111100101110100

What will be the first five bits after running this key through PC-1 table?

A

use python, don’t forget to do -1

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What will be the output of S-Box 8 given input 111011

A

row: 11 -> 0b11 -> 3
col: 1101 -> 0b1101 -> 13

find the intercept, of row, col and then get the output, and make it into binary.

intercept: 5 -> bin(5) -> 0101

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

How do you do left circular shift?

Ex:
0000100011000110101001011111 1111001100111100111111110000

A

take first bit add it to the end
0000100011000110101001011111 => 0001000110001101010010111110

1111001100111100111111110000 => 111001100111100111111110001

Combine the two 0001000110001101010010111110 + 111001100111100111111110001

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What important function do S-Boxes perform in DES encryption?

A

substitution

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

Do not need to know all of the S-Box design criteria but need to know at least a
few and describe them.

A

Any change to an input => results in random looking changes in the output

No output bit of any S-box should be linear

Each row should have 0-16

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

What is the important property of block cipher security achieved by swapping two halves
of the text block after every round

19
Q

What is the avalanche effect? Why is it important?

A

Small changes in plaintext or key => significant change in the cipher text

Making attempts of guessing keys impossible

20
Q

Why not double DES? What is the method of breaking double DES?

A

Meet-in-the-middle, the attacker creates two tables, The Encryption and Decryption. If one value within the encryption table matches with one in the decryption.

21
Q

Understand why when using 3DES, it’s better to use
EDE instead of EEE?

A

EDE, encrypt using key1, decrypt using key2, and encrypt again using key 1

Its backwards compatible with Single DES

22
Q

What is the difference between differential and linear cryptoanalysis?

A

Differential: Trying to derive the secret key by studying how the input plaintext affects the ciphertext

Linear: Attacker tries to find a linear function tries to find a linear function that can approximate the relationship between the plaintext key inputs, and the encryption

23
Q

What key sizes and block sizes does Twofish support?

24
Q

What is the distinguishing feature of Twofish S-Boxes? How do they compare with, say,
DES S-Boxes.

A

They are dynamically generated based on the key

25
What is the distinguishing feature of Twofish key scheduling algorithm?
It uses half of the key to do scheduling and the rest is used for deriving the keys
26
Compare and contrast AES and DES in terms of security, key size, block size, structure, and the number of rounds.
AES, has not been broken Key Size: 128(10 rounds) , 192(12 Rounds), 256(14 rounds) bit keys Block Size: 128
27
Is AES based on the Feistel cipher network?
Based on Substitution Permutation network
28
Be able to compare and contrast the Fiestal cipher framework to the Substitution Permu- tation framework.
S.P.F, is mainly focused on S-boxes and P-boxes. Fiestal takes input and splits it in half, with the right hand going through the round function
29
Know basic structure of the single AES round.
1. First round key XOR O.G P.T 2. P.T => SubBytes. 3. ShiftRows & MixColumns 4. AddRoundKey makes new key for next round , and XOR matrix
30
What sequence of operations does the first AES round perform?
SubBytes Permutation, Shift Rows, Mix Column, AddroundKey
31
How does the last round of AES differ from all other rounds?
It drops the mixColumn Step
32
In DES, the number of rounds is fixed. Is the same true of AES?
AES rounds are dependent on the size of the key.
33
Are Decryption and Encryption the same for the S.P.F?
No they are not the same
34
What happens to the plaintext block in AES?
it's put into a 4x4 matrix, known as the state
35
What are the main differences between public key and symmetric cryptography?
Symmetric does not provide digital signature.
36
Is public cryptography inherently more secure than symmetric?
No public key is not more secure. Its only advantage is if one party looses their key the other end is still secure
37
Does the invention of public key cryptography render symmetric obsolete?
no, because public has a much greater over head than symmetric
38
What is public key cryptography good for?
Key distribution and digital signatures
39
what are the requirements for secure public key algo?
Attacker isn't able to start with cipher text, and derive private key or p.T
40
What key do you use for confidentiality
You use public key of reciever
41
What key do you use for digital Signature
Sign using the private key of the sender
42
What can public key cryptography be used for?
Encryption / Decryption Digital Signatures Key Exchange
43