SlideShare a Scribd company logo
1 of 19
Mr . Sathish Kumar . M 
Department of Electronics and Communication 
Engineering 
I’ve learned that people will forget what you said, people will forget 
what you did, but people will never forget how you made them feel. 
–Maya Angelou
RivestShamir& Adleman 
MIT in 1977
What is RSA…? 
• RSA is an algorithm used by modern computers 
to encrypt and decrypt messages. 
• It is an asymmetric cryptographic algorithm. 
• It is included as part of the Web browsers from 
Microsoft and Netscape. 
• It's also part of Lotus Notes, Intuit's Quicken, and many 
other products.
RSA 
PUBLIC KEY PRIVATE KEY 
Public-key 
cryptography, also 
known as asymmetric 
cryptography, is a 
class 
of cryptographic 
algorithms 
Messages encrypted 
using the public key 
can only be 
decrypted with the 
private key.
OPERATION: 
• RSA involves a public key and private key. 
• The public key can be known to everyone, it is used to encrypt 
messages. 
• Messages encrypted using the public key can only be decrypted 
with the private key. 
The public key is used for encryption. 
• The key is known to the public . 
• The private key is used for decryption. 
• The key is only known to the 
owner .
The RSA algorithm involves three 
steps: key generation, encryption and decryption.
Why RSA…? 
• It developed to address two key issues: 
• Key distribution – how to have secure 
communications in general without having to 
trust a KDC with your key 
• Digital signatures – how to verify a message 
comes intact from the claimed sender
RSA CHARACTERISTICS: 
 Public-Key algorithms rely on two keys with the characteristics 
that it is: 
 computationally infeasible to find decryption key knowing 
only algorithm & encryption key 
 computationally easy to en/decrypt messages when the 
relevant (en/decrypt) key is known 
 either of the two related keys can be used for encryption, 
with the other used for decryption (in some schemes)
One-way function with trapdoor 
f 
x y 
x y 
x y 
 
f 
 
1 
 
f 
 
1 
 
trapdoor 
Easy: 
Hard: 
Easy: 
Use trapdoor 
as the private key. 
Many public-key cryptosystems are 
based on trapdoor one-way fu 
 
nctions.
RSA 
 
1 
RSA 
 
Idea behind RSA 
* 
It works in group 
Z 
Encryption (easy): 
Decryption (hard): 
Looking for a trapdoor: ( ) . 
If is a number such that 1mod ( ), then 
( ) 
1 
. 
e 
e 
e d 
n 
x x 
x x 
x x 
d ed n 
e d k 
n 
 
 
 
 
 
  
k 
for some , and 
  ( ) 1 ( ) 
k 
e d ed n k n 
x x x x x x x           
( ) 1 .
Integers 
a b a b a b 
 
| : divides , is a divisor of . 
 
gcd( a , b ): greatest common divisor of a and b 
. 
 Coprime or relatively prime: gcd( a , b 
)  
1. 
 
Euclid's algorithm: computes gcd( a , b 
). 
 Extented Eucl 
id's algorithm: computes integers 
x and y such that ax  by  gcd(a,b).
Euler Totient Function ø(n) 
• when doing arithmetic modulo n 
• complete set of residues is: 0..n-1 
• reduced set of residues is those numbers (residues) which are 
relatively prime to n 
eg for n=10, 
• complete set of residues is {0,1,2,3,4,5,6,7,8,9} 
• reduced set of residues is {1,3,7,9} 
• number of elements in reduced set of residues is called the Euler 
Totient Function ø(n)
Euler Totient Function ø(n) 
• when doing arithmetic modulo n 
• complete set of residues is: 0..n-1 
• reduced set of residues is those numbers (residues) which are 
relatively prime to n 
• eg for n=10, 
• complete set of residues is {0,1,2,3,4,5,6,7,8,9} 
• reduced set of residues is {1,3,7,9} 
• number of elements in reduced set of residues is called the 
Euler Totient Function ø(n)
Euler Totient Function ø(n) 
• when doing arithmetic modulo n 
• complete set of residues is: 0..n-1 
• reduced set of residues is those numbers (residues) which 
are relatively prime to n 
eg for n=10, 
• complete set of residues is {0,1,2,3,4,5,6,7,8,9} 
• reduced set of residues is {1,3,7,9} 
• number of elements in reduced set of residues is called the 
Euler Totient Function ø(n)
RSA ALGORITH EXAMPLE 
Choose p = 3 and q = 11 
Compute n = p * q = 3 * 11 = 33 
Compute φ(n) = (p - 1) * (q - 1) = 2 * 10 = 20 
Choose e such that 1 < e < φ(n) and e and n are coprime. Let e = 7 
Compute a value for d such that (d * e) % φ(n) = 1. One solution is d = 3 [(3 * 
7) % 20 = 1] 
Public key is (e, n) => (7, 33) 
Private key is (d, n) => (3, 33) 
The encryption ofm = 2 isc = 27 % 33 = 29 
The decryption ofc = 29 ism = 293 % 33 = 2
RSA ALGORITHM

More Related Content

What's hot

CRYPTOGRAPHY AND NETWORK SECURITY
CRYPTOGRAPHY AND NETWORK SECURITYCRYPTOGRAPHY AND NETWORK SECURITY
CRYPTOGRAPHY AND NETWORK SECURITYKathirvel Ayyaswamy
 
symmetric key encryption algorithms
 symmetric key encryption algorithms symmetric key encryption algorithms
symmetric key encryption algorithmsRashmi Burugupalli
 
Information Security & Cryptography
Information Security & CryptographyInformation Security & Cryptography
Information Security & CryptographyArun ACE
 
Cryptography.ppt
Cryptography.pptCryptography.ppt
Cryptography.pptUday Meena
 
12 symmetric key cryptography
12   symmetric key cryptography12   symmetric key cryptography
12 symmetric key cryptographydrewz lin
 
CS6701 CRYPTOGRAPHY AND NETWORK SECURITY
CS6701 CRYPTOGRAPHY AND NETWORK SECURITYCS6701 CRYPTOGRAPHY AND NETWORK SECURITY
CS6701 CRYPTOGRAPHY AND NETWORK SECURITYKathirvel Ayyaswamy
 
2. public key cryptography and RSA
2. public key cryptography and RSA2. public key cryptography and RSA
2. public key cryptography and RSADr.Florence Dayana
 
Double DES & Triple DES
Double DES & Triple DESDouble DES & Triple DES
Double DES & Triple DESHemant Sharma
 
Data Encryption Standard (DES)
Data Encryption Standard (DES)Data Encryption Standard (DES)
Data Encryption Standard (DES)Haris Ahmed
 
AES-Advanced Encryption Standard
AES-Advanced Encryption StandardAES-Advanced Encryption Standard
AES-Advanced Encryption StandardPrince Rachit
 
2. Stream Ciphers
2. Stream Ciphers2. Stream Ciphers
2. Stream CiphersSam Bowne
 
Cryptography using rsa cryptosystem
Cryptography using rsa cryptosystemCryptography using rsa cryptosystem
Cryptography using rsa cryptosystemSamdish Arora
 

What's hot (20)

RSA ALGORITHM
RSA ALGORITHMRSA ALGORITHM
RSA ALGORITHM
 
Rsa cryptosystem
Rsa cryptosystemRsa cryptosystem
Rsa cryptosystem
 
Rsa
RsaRsa
Rsa
 
CRYPTOGRAPHY AND NETWORK SECURITY
CRYPTOGRAPHY AND NETWORK SECURITYCRYPTOGRAPHY AND NETWORK SECURITY
CRYPTOGRAPHY AND NETWORK SECURITY
 
Cryptography
CryptographyCryptography
Cryptography
 
symmetric key encryption algorithms
 symmetric key encryption algorithms symmetric key encryption algorithms
symmetric key encryption algorithms
 
Information Security & Cryptography
Information Security & CryptographyInformation Security & Cryptography
Information Security & Cryptography
 
Cryptography.ppt
Cryptography.pptCryptography.ppt
Cryptography.ppt
 
12 symmetric key cryptography
12   symmetric key cryptography12   symmetric key cryptography
12 symmetric key cryptography
 
Key management
Key managementKey management
Key management
 
CS6701 CRYPTOGRAPHY AND NETWORK SECURITY
CS6701 CRYPTOGRAPHY AND NETWORK SECURITYCS6701 CRYPTOGRAPHY AND NETWORK SECURITY
CS6701 CRYPTOGRAPHY AND NETWORK SECURITY
 
Asymmetric Cryptography
Asymmetric CryptographyAsymmetric Cryptography
Asymmetric Cryptography
 
2. public key cryptography and RSA
2. public key cryptography and RSA2. public key cryptography and RSA
2. public key cryptography and RSA
 
Double DES & Triple DES
Double DES & Triple DESDouble DES & Triple DES
Double DES & Triple DES
 
Kerberos
KerberosKerberos
Kerberos
 
Data Encryption Standard (DES)
Data Encryption Standard (DES)Data Encryption Standard (DES)
Data Encryption Standard (DES)
 
AES-Advanced Encryption Standard
AES-Advanced Encryption StandardAES-Advanced Encryption Standard
AES-Advanced Encryption Standard
 
2. Stream Ciphers
2. Stream Ciphers2. Stream Ciphers
2. Stream Ciphers
 
Diffie-hellman algorithm
Diffie-hellman algorithmDiffie-hellman algorithm
Diffie-hellman algorithm
 
Cryptography using rsa cryptosystem
Cryptography using rsa cryptosystemCryptography using rsa cryptosystem
Cryptography using rsa cryptosystem
 

Similar to RSA ALGORITHM

Similar to RSA ALGORITHM (20)

Information and network security 33 rsa algorithm
Information and network security 33 rsa algorithmInformation and network security 33 rsa algorithm
Information and network security 33 rsa algorithm
 
Homomorphic Encryption
Homomorphic EncryptionHomomorphic Encryption
Homomorphic Encryption
 
PKC&RSA
PKC&RSAPKC&RSA
PKC&RSA
 
Class3
Class3Class3
Class3
 
Simple Overview Caesar and RSA Encryption_by_Tarek_Gaber
Simple Overview Caesar and RSA Encryption_by_Tarek_GaberSimple Overview Caesar and RSA Encryption_by_Tarek_Gaber
Simple Overview Caesar and RSA Encryption_by_Tarek_Gaber
 
Computing on Encrypted Data
Computing on Encrypted DataComputing on Encrypted Data
Computing on Encrypted Data
 
RSA Algorithm
RSA AlgorithmRSA Algorithm
RSA Algorithm
 
Broadcasting and low exponent rsa attack
Broadcasting and low exponent rsa attackBroadcasting and low exponent rsa attack
Broadcasting and low exponent rsa attack
 
The rsa algorithm
The rsa algorithmThe rsa algorithm
The rsa algorithm
 
The rsa algorithm
The rsa algorithmThe rsa algorithm
The rsa algorithm
 
The rsa algorithm
The rsa algorithmThe rsa algorithm
The rsa algorithm
 
Python Programming - IX. On Randomness
Python Programming - IX. On RandomnessPython Programming - IX. On Randomness
Python Programming - IX. On Randomness
 
The rsa algorithm JooSeok Song
The rsa algorithm JooSeok SongThe rsa algorithm JooSeok Song
The rsa algorithm JooSeok Song
 
CNIT 141: 10. RSA
CNIT 141: 10. RSACNIT 141: 10. RSA
CNIT 141: 10. RSA
 
Overview on Cryptography and Network Security
Overview on Cryptography and Network SecurityOverview on Cryptography and Network Security
Overview on Cryptography and Network Security
 
3 pkc+rsa
3 pkc+rsa3 pkc+rsa
3 pkc+rsa
 
An Analysis of RSA Public Exponent e
An Analysis of RSA Public Exponent eAn Analysis of RSA Public Exponent e
An Analysis of RSA Public Exponent e
 
Ch9
Ch9Ch9
Ch9
 
CNIT 141 10. RSA
CNIT 141 10. RSACNIT 141 10. RSA
CNIT 141 10. RSA
 
10 RSA
10 RSA10 RSA
10 RSA
 

More from Sathish Kumar

LabVIEW Based Monitoring the Building in wireless communication
LabVIEW Based Monitoring the Building in wireless communicationLabVIEW Based Monitoring the Building in wireless communication
LabVIEW Based Monitoring the Building in wireless communicationSathish Kumar
 
7 layers of osi models
7 layers of osi models7 layers of osi models
7 layers of osi modelsSathish Kumar
 
Labview based wireless sensor for monitoring the building
Labview based wireless sensor for monitoring the buildingLabview based wireless sensor for monitoring the building
Labview based wireless sensor for monitoring the buildingSathish Kumar
 
V3 i4 ijertv3is040482
V3 i4 ijertv3is040482V3 i4 ijertv3is040482
V3 i4 ijertv3is040482Sathish Kumar
 
Modulation techniques
Modulation techniquesModulation techniques
Modulation techniquesSathish Kumar
 

More from Sathish Kumar (10)

Home security
Home securityHome security
Home security
 
Interview questions
Interview questionsInterview questions
Interview questions
 
LabVIEW Based Monitoring the Building in wireless communication
LabVIEW Based Monitoring the Building in wireless communicationLabVIEW Based Monitoring the Building in wireless communication
LabVIEW Based Monitoring the Building in wireless communication
 
Labview Basics
Labview BasicsLabview Basics
Labview Basics
 
7 layers of osi models
7 layers of osi models7 layers of osi models
7 layers of osi models
 
Labview based wireless sensor for monitoring the building
Labview based wireless sensor for monitoring the buildingLabview based wireless sensor for monitoring the building
Labview based wireless sensor for monitoring the building
 
Mysteries
MysteriesMysteries
Mysteries
 
V3 i4 ijertv3is040482
V3 i4 ijertv3is040482V3 i4 ijertv3is040482
V3 i4 ijertv3is040482
 
Modulation techniques
Modulation techniquesModulation techniques
Modulation techniques
 
System hardware
System hardwareSystem hardware
System hardware
 

Recently uploaded

multiple access in wireless communication
multiple access in wireless communicationmultiple access in wireless communication
multiple access in wireless communicationpanditadesh123
 
Risk Management in Engineering Construction Project
Risk Management in Engineering Construction ProjectRisk Management in Engineering Construction Project
Risk Management in Engineering Construction ProjectErbil Polytechnic University
 
Research Methodology for Engineering pdf
Research Methodology for Engineering pdfResearch Methodology for Engineering pdf
Research Methodology for Engineering pdfCaalaaAbdulkerim
 
Configuration of IoT devices - Systems managament
Configuration of IoT devices - Systems managamentConfiguration of IoT devices - Systems managament
Configuration of IoT devices - Systems managamentBharaniDharan195623
 
welding defects observed during the welding
welding defects observed during the weldingwelding defects observed during the welding
welding defects observed during the weldingMuhammadUzairLiaqat
 
Past, Present and Future of Generative AI
Past, Present and Future of Generative AIPast, Present and Future of Generative AI
Past, Present and Future of Generative AIabhishek36461
 
DM Pillar Training Manual.ppt will be useful in deploying TPM in project
DM Pillar Training Manual.ppt will be useful in deploying TPM in projectDM Pillar Training Manual.ppt will be useful in deploying TPM in project
DM Pillar Training Manual.ppt will be useful in deploying TPM in projectssuserb6619e
 
Work Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvvWork Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvvLewisJB
 
home automation using Arduino by Aditya Prasad
home automation using Arduino by Aditya Prasadhome automation using Arduino by Aditya Prasad
home automation using Arduino by Aditya Prasadaditya806802
 
Internet of things -Arshdeep Bahga .pptx
Internet of things -Arshdeep Bahga .pptxInternet of things -Arshdeep Bahga .pptx
Internet of things -Arshdeep Bahga .pptxVelmuruganTECE
 
Indian Dairy Industry Present Status and.ppt
Indian Dairy Industry Present Status and.pptIndian Dairy Industry Present Status and.ppt
Indian Dairy Industry Present Status and.pptMadan Karki
 
National Level Hackathon Participation Certificate.pdf
National Level Hackathon Participation Certificate.pdfNational Level Hackathon Participation Certificate.pdf
National Level Hackathon Participation Certificate.pdfRajuKanojiya4
 
US Department of Education FAFSA Week of Action
US Department of Education FAFSA Week of ActionUS Department of Education FAFSA Week of Action
US Department of Education FAFSA Week of ActionMebane Rash
 
Mine Environment II Lab_MI10448MI__________.pptx
Mine Environment II Lab_MI10448MI__________.pptxMine Environment II Lab_MI10448MI__________.pptx
Mine Environment II Lab_MI10448MI__________.pptxRomil Mishra
 
Crushers to screens in aggregate production
Crushers to screens in aggregate productionCrushers to screens in aggregate production
Crushers to screens in aggregate productionChinnuNinan
 
Autonomous emergency braking system (aeb) ppt.ppt
Autonomous emergency braking system (aeb) ppt.pptAutonomous emergency braking system (aeb) ppt.ppt
Autonomous emergency braking system (aeb) ppt.pptbibisarnayak0
 
Class 1 | NFPA 72 | Overview Fire Alarm System
Class 1 | NFPA 72 | Overview Fire Alarm SystemClass 1 | NFPA 72 | Overview Fire Alarm System
Class 1 | NFPA 72 | Overview Fire Alarm Systemirfanmechengr
 
Transport layer issues and challenges - Guide
Transport layer issues and challenges - GuideTransport layer issues and challenges - Guide
Transport layer issues and challenges - GuideGOPINATHS437943
 

Recently uploaded (20)

multiple access in wireless communication
multiple access in wireless communicationmultiple access in wireless communication
multiple access in wireless communication
 
Risk Management in Engineering Construction Project
Risk Management in Engineering Construction ProjectRisk Management in Engineering Construction Project
Risk Management in Engineering Construction Project
 
Research Methodology for Engineering pdf
Research Methodology for Engineering pdfResearch Methodology for Engineering pdf
Research Methodology for Engineering pdf
 
Configuration of IoT devices - Systems managament
Configuration of IoT devices - Systems managamentConfiguration of IoT devices - Systems managament
Configuration of IoT devices - Systems managament
 
welding defects observed during the welding
welding defects observed during the weldingwelding defects observed during the welding
welding defects observed during the welding
 
Past, Present and Future of Generative AI
Past, Present and Future of Generative AIPast, Present and Future of Generative AI
Past, Present and Future of Generative AI
 
DM Pillar Training Manual.ppt will be useful in deploying TPM in project
DM Pillar Training Manual.ppt will be useful in deploying TPM in projectDM Pillar Training Manual.ppt will be useful in deploying TPM in project
DM Pillar Training Manual.ppt will be useful in deploying TPM in project
 
Work Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvvWork Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvv
 
home automation using Arduino by Aditya Prasad
home automation using Arduino by Aditya Prasadhome automation using Arduino by Aditya Prasad
home automation using Arduino by Aditya Prasad
 
Design and analysis of solar grass cutter.pdf
Design and analysis of solar grass cutter.pdfDesign and analysis of solar grass cutter.pdf
Design and analysis of solar grass cutter.pdf
 
Internet of things -Arshdeep Bahga .pptx
Internet of things -Arshdeep Bahga .pptxInternet of things -Arshdeep Bahga .pptx
Internet of things -Arshdeep Bahga .pptx
 
Indian Dairy Industry Present Status and.ppt
Indian Dairy Industry Present Status and.pptIndian Dairy Industry Present Status and.ppt
Indian Dairy Industry Present Status and.ppt
 
National Level Hackathon Participation Certificate.pdf
National Level Hackathon Participation Certificate.pdfNational Level Hackathon Participation Certificate.pdf
National Level Hackathon Participation Certificate.pdf
 
US Department of Education FAFSA Week of Action
US Department of Education FAFSA Week of ActionUS Department of Education FAFSA Week of Action
US Department of Education FAFSA Week of Action
 
Mine Environment II Lab_MI10448MI__________.pptx
Mine Environment II Lab_MI10448MI__________.pptxMine Environment II Lab_MI10448MI__________.pptx
Mine Environment II Lab_MI10448MI__________.pptx
 
Crushers to screens in aggregate production
Crushers to screens in aggregate productionCrushers to screens in aggregate production
Crushers to screens in aggregate production
 
Autonomous emergency braking system (aeb) ppt.ppt
Autonomous emergency braking system (aeb) ppt.pptAutonomous emergency braking system (aeb) ppt.ppt
Autonomous emergency braking system (aeb) ppt.ppt
 
young call girls in Green Park🔝 9953056974 🔝 escort Service
young call girls in Green Park🔝 9953056974 🔝 escort Serviceyoung call girls in Green Park🔝 9953056974 🔝 escort Service
young call girls in Green Park🔝 9953056974 🔝 escort Service
 
Class 1 | NFPA 72 | Overview Fire Alarm System
Class 1 | NFPA 72 | Overview Fire Alarm SystemClass 1 | NFPA 72 | Overview Fire Alarm System
Class 1 | NFPA 72 | Overview Fire Alarm System
 
Transport layer issues and challenges - Guide
Transport layer issues and challenges - GuideTransport layer issues and challenges - Guide
Transport layer issues and challenges - Guide
 

RSA ALGORITHM

  • 1. Mr . Sathish Kumar . M Department of Electronics and Communication Engineering I’ve learned that people will forget what you said, people will forget what you did, but people will never forget how you made them feel. –Maya Angelou
  • 3. What is RSA…? • RSA is an algorithm used by modern computers to encrypt and decrypt messages. • It is an asymmetric cryptographic algorithm. • It is included as part of the Web browsers from Microsoft and Netscape. • It's also part of Lotus Notes, Intuit's Quicken, and many other products.
  • 4. RSA PUBLIC KEY PRIVATE KEY Public-key cryptography, also known as asymmetric cryptography, is a class of cryptographic algorithms Messages encrypted using the public key can only be decrypted with the private key.
  • 5.
  • 6. OPERATION: • RSA involves a public key and private key. • The public key can be known to everyone, it is used to encrypt messages. • Messages encrypted using the public key can only be decrypted with the private key. The public key is used for encryption. • The key is known to the public . • The private key is used for decryption. • The key is only known to the owner .
  • 7. The RSA algorithm involves three steps: key generation, encryption and decryption.
  • 8. Why RSA…? • It developed to address two key issues: • Key distribution – how to have secure communications in general without having to trust a KDC with your key • Digital signatures – how to verify a message comes intact from the claimed sender
  • 9.
  • 10. RSA CHARACTERISTICS:  Public-Key algorithms rely on two keys with the characteristics that it is:  computationally infeasible to find decryption key knowing only algorithm & encryption key  computationally easy to en/decrypt messages when the relevant (en/decrypt) key is known  either of the two related keys can be used for encryption, with the other used for decryption (in some schemes)
  • 11.
  • 12. One-way function with trapdoor f x y x y x y  f  1  f  1  trapdoor Easy: Hard: Easy: Use trapdoor as the private key. Many public-key cryptosystems are based on trapdoor one-way fu  nctions.
  • 13. RSA  1 RSA  Idea behind RSA * It works in group Z Encryption (easy): Decryption (hard): Looking for a trapdoor: ( ) . If is a number such that 1mod ( ), then ( ) 1 . e e e d n x x x x x x d ed n e d k n        k for some , and   ( ) 1 ( ) k e d ed n k n x x x x x x x           ( ) 1 .
  • 14. Integers a b a b a b  | : divides , is a divisor of .  gcd( a , b ): greatest common divisor of a and b .  Coprime or relatively prime: gcd( a , b )  1.  Euclid's algorithm: computes gcd( a , b ).  Extented Eucl id's algorithm: computes integers x and y such that ax  by  gcd(a,b).
  • 15. Euler Totient Function ø(n) • when doing arithmetic modulo n • complete set of residues is: 0..n-1 • reduced set of residues is those numbers (residues) which are relatively prime to n eg for n=10, • complete set of residues is {0,1,2,3,4,5,6,7,8,9} • reduced set of residues is {1,3,7,9} • number of elements in reduced set of residues is called the Euler Totient Function ø(n)
  • 16. Euler Totient Function ø(n) • when doing arithmetic modulo n • complete set of residues is: 0..n-1 • reduced set of residues is those numbers (residues) which are relatively prime to n • eg for n=10, • complete set of residues is {0,1,2,3,4,5,6,7,8,9} • reduced set of residues is {1,3,7,9} • number of elements in reduced set of residues is called the Euler Totient Function ø(n)
  • 17. Euler Totient Function ø(n) • when doing arithmetic modulo n • complete set of residues is: 0..n-1 • reduced set of residues is those numbers (residues) which are relatively prime to n eg for n=10, • complete set of residues is {0,1,2,3,4,5,6,7,8,9} • reduced set of residues is {1,3,7,9} • number of elements in reduced set of residues is called the Euler Totient Function ø(n)
  • 18. RSA ALGORITH EXAMPLE Choose p = 3 and q = 11 Compute n = p * q = 3 * 11 = 33 Compute φ(n) = (p - 1) * (q - 1) = 2 * 10 = 20 Choose e such that 1 < e < φ(n) and e and n are coprime. Let e = 7 Compute a value for d such that (d * e) % φ(n) = 1. One solution is d = 3 [(3 * 7) % 20 = 1] Public key is (e, n) => (7, 33) Private key is (d, n) => (3, 33) The encryption ofm = 2 isc = 27 % 33 = 29 The decryption ofc = 29 ism = 293 % 33 = 2