Hill cipher, stream ciphers and the One Time Pad Flashcards

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

What is the hill cipher?

A

Polygram cipher (polygraphic cipher)

Perform a linear transformation on d number of plaintext characters, to get d ciphertext characters.

Enc:
Multiply a d x d matrix K by the block of plaintext P
C = KP

Dec:
Multiply the matrix K⁻1 by the block of the ciphertext C
P = K⁻1C

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

What is a weakness of the Hill cipher?

A

It is linear, known plaintext attacks are easy

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

Do a cryptanalysis of the Hill cipher

A

Known plaintext are possible given d number of plaintext ciphertext matching blocks.

We are given d blocks of matching P and C,
Then we are able to C = KP for K

And use K to get rest of plaintext:
P = K⁻1*C

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

What are stream filters?

A

Characterised by the generation of a keystream of any required length.

Each element of the keystream encrypts one or more ciphertext characters

Usually symmetric ciphers

Keystream must have good randomness properties

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

What is a synchronous stream cipher?

A

Keystream generated independently of the P

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

How does enc and dec in synchronous stream ciphers work?

A

Enc: c(t) = p(t) XOR s(t)

Dec: p(t) = c(t) XOR s(t)

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

What is the one time pad?

A

Key: truly random sequence of characters, independently generated

Each character in key is used one time only

non-periodic binary synchronous stream cipher

Provides perfect secrecy

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

Define perfect secrecy

A

Message set: {M1, M2, …, Mk}
Ciphertext set: {C1, C2, …, CK}

P(Mi|Cj): Probability of Mi was encrypted given that Cj was observed

Perfect secrecy:
P(Mi|Cj) = P(Mi)

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

How does enc and dec work in the one time pad?

A

Enc:
ci = (pi + ki) mod 26

Dec:
pi = (ci -ki) mod 26

mod 26 when using roman alphabeth

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

With P = HELLO
K = EZABD

What is C?

A

LDLMR

Given C, note that P can be any 5-letter message

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

How does enc and dec work in binary one time pad?

A

Enc:
ci = pi XOR ki

Dec:
pi = ci XOR ki

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

What are some properties of perfect secrecy, in regards to the number of keys?

A

Any cipher with perfect secrecy, myst have as many keys as there are messages.

This makes one-time pad the only unbreakable cipher.

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

What is the main problem with one time pad?

A

Key distribution and random keys

Dealing with keys are difficult when these are so large

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

What is visual cryptography?

A

Application of one time pad

Split image into two shares

Dec: Overlaying the twoshares

Each pixel is shared in a random way

Each share reveals no information about the image

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

How does encryption work in visual cryptography?

A

Generate a one time pad P (random string of bits) with length equals to number of pixels in the image

Generate an image share by replacing each bit using these sub-pixels patterns:
0 bit: black-white
1 bit: white-black

Generate the other share as follows:
- The same as the first share for all the white pixels of the image
- The opposite of the first share for all black pixels of the image

17
Q

How do we decrypt in visul cryptography?

A

Overlay the two shares