4 - Public Key Cryptography Flashcards
RSA
Who first introduced the idea of Public key crypto?
Diffe & Hellman 1976/77
RSA 1977 still used
Public-key crypto relies on operations that are…
easy to do but hard to “undo”
RSA is based on the difficulty of…
factoring (easy to multiply, hard to factor)
Steps of public key
Each person has public/private
Alice -> Bob, encrypt with Bob public key and Bob decrypt with own private key
Possible attack, specific to pub0key
When there are not many possible plaintext,
attacker can encrypt all possible plaintext using Bob pub key and see what they intercept then match.
Setting up RSA Keys
p, q are large primes (150 digits plus)
n is p * q
r is (p-1)(q-1)
e is chosen between 2 and r-1 such that gcd(e,r) = 1
d such that ed mod r =1
Pub = (e,n)
Priv = (d,p,q)
Out of e,n,d,p,q, which of these are allocated to public/private key?
pub = (e,n)
priv = (d,p,q)
RSA - Plaintext and ciphertexts are integers between …
0 and n-1
To send message m to Bob (RSA), it should be encrypted as…
c = m^e mod n
e and n are from RSA steps
TO decrypt a message (RSA), Bob uses…
c^d mod n
d and n are from RSA steps
RSA’s current main use
Digital signatures
Not encryption or key exchange