Algorithms Flashcards

1
Q

What is the Formula for Encryption for RSA

A

C = M^e % n

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

What is the Formula for Decryption for RSA

A

M=C^d % n = (M^e)^d % n

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

Explain Key Generation for RSA

A
  1. take distinct Prime Numbers p q, let n=p.q
  2. let phi(n) = (p-1)(q-1)
  3. calculate d so that de % phi(n) = 1

Public Key KU = {e ,n}
private Key KR = {d, n}

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

How can you break RSA

A

Brute Force Attacks
find p and q for n

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

Points about the security of RSA

A

Relies on factoring algorithms
big numbers cannot be factored easily

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

Requirements for DH algorithm

A

2 known numbers
1. Prime Number (q)
2. Primitive root of q (a)

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

Steps Of DH Encryption

A
  1. A and B Select random numbers secretly
  2. A Calculates Ya = alpha Xa% q
  3. B calculates Yb = alpha Xb% q
  4. send those over
  5. they calculate a common secret key using
    K = (Ya/bXb/Xa)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What does MAC Stand For

A

Message Authentication Code

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

How does MAC work

A

a hash is found for a message using a shared secret key and added to the end of the message by the sender, the receiver then also calculates the MAC and compares their results

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

Compare MAC to encryption

A

MAC is easier to implement and is less vunerable to being broken but cannot be reversed

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

Compare One-Way Hash functions and MAC

A
  • hash functions do not use a secret key to find the hash unlike MAC
  • both easy to implement
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Requirements for one way Hash Functions in message authentication

A
  • function must be able to be applied to a block of any size
  • function must produce a fixed length
    -H(x) must be easy to compute
    -for a given h it must be difficult to find x such that H(x) = h
    -Strong collision resistance
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q
A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly