RSA <ul><li>RSA is the most secondhand and also probably the simplest to deal and help. A peculiarity of this algorithm is that his two keys serve indistinctly so much to code like to authenticate. It owes his name to his three inventors: Ronald Rivest, Adi Shamir and Leonard Adleman, that they published by the first time the method RSA in 1977. </li></ul>
<ul><li>RSA, bases on the difcultad who presents the factoring of big numbers. The keys public and private are calculated from a number that is obtained as product of two big cousins. An attacker who wants to recover a clear text from the cryptogram and the public key, has to face the above mentioned problem of factoring. </li></ul>
The algorithm RSA <ul><li>(1) Generation of the couple of Generation of the couple of keys.
To generate a couple of keys (KP; Kp), first there are chosen aleatoriamente two prime big numbers, p and q (of approximately 200 numbers each one, for example). Later the product is calculated n = p.q. </li></ul>
<ul><li>We will take now a number and relative cousin with (p-1) and with (q-1). This couple of numbers (and, n) they can be known by anyone, and constitute the so called public key "e" therefore an inverse module must have (p-1) (q-1), which we call d. Certainly there is fulfilled that ed = 1 mod ((p-1) (q-1)), that is the same thing that to say that ed = 1+k (p-1) (q-1) for some point k. The private key will be the couple (d, n). This number d must be kept secret and only it will be known by the owner of the couple of keys. </li></ul>
<ul><li>(2) Coding of the message with the public key.
It is necessary to make notice that with this algorithm the messages that are coded and decipher are entire numbers of minor size that n, not free letters as in case of the codings Caesar or Vigènere. To obtain the ciphered message C from the message in clear M, the following operation is realized: C = Me (mod n). </li></ul>
<ul><li>(3) Deciphered of the message with the private key.
To recover the original message from the coding the following operation is realized: M = CD (mod n).
CD (mod n) = (Me) d (mod n) = M1+k (p-1) (q-1) (mod n) = (M (p-1) (q-1)) k. M (mod n) [i].
If we remember, the function of Euler f (n) = (p-1) (q-1), and that in general, except improbable random, have that mcd (M, p) =mcd (M, q) =mcd (M, n) =1. </li></ul>
And therefore according to the theorem of Euler-Fermat, Mf (n) = 1 (mod n) ⇒ (M (p-1) (q-1)) k = 1 (mod n) [ii]. <ul><li>Of [i] and [ii] there is obtained that CD (mod n) = 1. M (mod n) = M, for 0 <M <n.
Conmutatividad of the coding and deciphered in RSA. </li></ul>
<ul><li>For the properties of the modular exponenciación, the coding and deciphered commutative sound:
M = (Me mod n) d mod n = Md.e mod n = (Md mod n) and mod n = M. This supposes that if coding M with the public key and and later deciphering the result with the private road d we obtain again M, also we can code M with the private key d and decipher the result with the public key and, returning to obtain M. </li></ul>
Videos of example of code of the algorithm RSA Video of encrypted RSA university of loja: http://www.youtube.com/watch?v=9ReP4lmExmc&feature=related video of encriptacion RSA: http://www.youtube.com/watch?v=kbIonkBgY4Q&feature=related
algorithm rsa1 (part 1): http://www.youtube.com/watch?v=Zf9h3M7-rk0&feature=related algorithm rsa2 (part 2): http://www.youtube.com/watch?v=MvnJ2Rhu_dU&feature=related It paginates of algorimo RSA: http://www.elguille.info/net/dotnet/encriptar_rsa_cifrar_descifrar.aspx