Intro
RSA is an encryption algo used to send a message from one person to another. Each person has a private and public key.
Procedure
The variables used will be
and are 2 long primes, but for the demonstration we will use
Now we calculate using Euler’s totient function
The receiver chooses a number
This is useful for finding
is often prime. In our case, we set to 7 and to 3.
are broadcast by the receiver as public keys. The send broadcasts the message encrypted using the formula
For example, if the sender encrypts and sends the message , they would send .
Now, the receiver uses his private key to decode the message.