3. RSA
RSA was first described in 1977 by Ron Rivest, Adi Shamir and
Leonard Adleman of the Massachusetts Institute of Technology and
published in 1978.Rivest and Shamir, as computer scientists,
proposed many potential functions while Adleman, as a
mathematician, was responsible for finding their weaknesses.
The RSA scheme is a block cipher in which the plaintext and
ciphertext are integers between 0 and n - 1. A typical size for n is
1024 bits, or 309 dec- imal digits. That is, n is less than 21024
4. Cont…
It is also known as Public-key cryptography, uses two different but
mathematically linked keys, one public and one private. The public
key can be shared with everyone, whereas the private key must be kept
secret. In RSA cryptography, both the public and the private keys can
encrypt a message; the opposite key from the one used to encrypt a
message is used to decrypt it.
5. Cont…
This attribute is one reason why RSA has become the most widely used
asymmetric algorithm. It provides a method of declaring the confidentiality,
integrity, authenticity and non-reputability of electronic communications and
data storage.
Many protocols like SSH(Secure Socket Shell ) and SSL(Secure Sockets
Layer)/TSL(Transport Layer Security ) rely on RSA for encryption and digital
signature functions. It is also used in software programs like browser are an
obvious example, which need to establish a secure connection over an
insecure network like the Internet or validate a digital signature. RSA
signature verification is one of the most commonly performed operations in
IT.
7. RSA Algo
Plaintext: This is the readable message or data that is fed into the
algorithm as input.
Encryption algorithm:The encryption algorithm performs various
transformations on the plaintext.
Public and private keys:This is a pair of keys that have been selected so
that if one is used for encryption, the other is used for decryption.The
exact transformations performed by the algorithm depend on the public or
private key that is provided as input.
Ciphertext:This is the scrambled message produced as output. It
depends on the plaintext and the key. For a given message, two different
keys will produce two different ciphertexts.
Decryption algorithm:This algorithm accepts the ciphertext and the
matching key and produces the original plaintext.
9. Essential steps
The essential steps are the following.
Each user generates a pair of keys to be used for the encryption and
decryption of messages.
Each user places one of the two keys in a public register or other
accessible file.This is the public key.The companion key is kept private,
each user maintains a collection of public keys obtained from others.
If Bob wishes to send a confidential message to Alice, Bob encrypts the
message using Alice’s public key.
When Alice receives the message, she decrypts it using her private key.
No other recipient can decrypt the message because only Alice knows
Alice’s private key.
11. Description of RSA
Generate two prime Numbers ‘P’ and ‘Q’ [P != Q]
Calculate ‘N’ [N = P*Q]
Calculate ‘M’[M = (P-1)(Q-1)]
Choose a number ‘E’ [‘E’ is a small number Co-prime to ‘M’]
Find ‘D’ such that [ (E*D) mod M = 1]
17. RSA Security
The security of RSA relies on the computational
difficulty of factoring large integers. As computing
power increases and more efficient factoring algorithms
are discovered, the ability to factor larger and larger
numbers also increases. Encryption strength is directly
tied to key size, and doubling key length delivers an
exponential increase in strength, although it does
impair performance.
18. Continue…..
RSA keys are typically 1024- or
2048-bits long, but experts believe that 1024-bit keys
could be broken in the near future, which is why
government and industry are moving to a minimum key
length of 2048-bits.
19. RSA Attacks
Four possible approaches to attacking the RSA algorithm are
• Brute force:This involves trying all possible private keys.(hit and trial)
• Mathematical attacks:There are several approaches, all equivalent in effort to
factoring the product of two primes.
• Timing attacks:
developed in mid-1990’s
These depend on the running time of the decryption algorithm.
• Chosen ciphertext attacks:This type of attack exploits properties of the RSA
algorithm.
21. Timing Attacks
developed in mid-1990’s
exploit timing variations in operations
eg. multiplying by small vs large number
or IF's varying which instructions executed
infer operand size based on time taken
RSA exploits time taken in exponentiation
countermeasures
use constant exponentiation time
add random delays
blind values used in calculations
22. Advantages
In asymmetric or public key, cryptography there is no need for exchanging
keys, thus eliminating the key distribution problem.
The primary advantage of public-key cryptography is increased security:
the private keys do not ever need to be transmitted or revealed to anyone.
Can provide digital signatures that can be repudiated
23. DisADVANTAGES
A disadvantage of using public-key cryptography for encryption is speed:
there are popular secret-key encryption methods which are significantly faster
than any currently available public-key encryption method.
Key Management
Key Validation
The loss of a private key means that all received messages cannot be decrypted.