Week 2 Flashcards

1
Q

What is cryptography?

A

Describes how to transfer messages between participants without anyone else being able to read/modify.

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

What is a code?

A

Any way to represent data.

E.g. Bit strings, morse code.

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

What is a cipher?

A

A code which is difficult to derive data from.

Plain text encodes to cipher text via encryption.

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

What does the UNIX command xxd do?

A

Allows us to see hex representation (on disk) of a file.

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

How does the Caesar Cipher work?

A

Replaces each letter of the alphabet with the character three letters to the right.

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

What is Kerckoffs’ Principle?

A

A cipher should be secure even if the attacker knows everything about it apart from the key.

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

What is Frequency Analysis?

A

Counts number of times each symbol, pair of symbols occurs and draws conclusion from this.

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

Explain Symmetric Cryptography?

A

When the same key is used for encryption and decryption.

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

Explain Symmetric Cryptography?

A

When the same key is used for encryption and decryption.

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

What are the advantages and disadvantages with One Time Pads?

A

+ Perfect encryption.

  • They key needs to be as long as the message.
  • Must use key only once.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Explain Block Ciphers?

A

Work on blocks of plain text, not just single symbols.

Made up of a series of permutations and substitutions repeated on each block.

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

Describe AES block cipher?

A

Advanced Encryption Standard.

Works on blocks of 128 bits (4x4 matrix) by generating ten round keys from a 128 bit key.

Uses one permutation (ShiftRows) and three substitutions (SubBytes, MixColumns, AddRoundKey).

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

Describe 3-DES?

A

Takes 3 keys:

Ek1,k2,k3(M) = Ek3(Dk2(Ek1(M)))

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

Explain a mechanism for Padding?

A

PKCS (5/7).

If one byte of space write 01, and so on up until filled block (16….16).

5 - 8 byte block, 7 - 16 byte block.

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

Explain the Electronic Codebook Mode of block ciphers?

A

Each block encrypted individually, and assembled in same order.

If blocks are repeated in plain text, this is revealed in cipher text.

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

Explain the Cipher Block Chaining Mode of block ciphers?

A

Utilizes probabilistic encryption.

Each block XOR’d with previous block, starting with random initialization vector.

Cn = encrypt(Bn XOR Cn-1)

This helps overcome replay attack.

16
Q

Explain CTR Mode of block ciphers?

A

Counter Mode.

Cn = Bn XOR encrypt(IV + n - 1)

17
Q

Explain XOR?

A

Binary addition modulo 2.

0 XOR 0 = 0
0 XOR 1 / 1 XOR 0 = 1
1 XOR 1 = 0