home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / sci / math / 15014 < prev    next >
Encoding:
Text File  |  1992-11-15  |  1.7 KB  |  59 lines

  1. Newsgroups: sci.math
  2. Path: sparky!uunet!paladin.american.edu!darwin.sura.net!sgiblab!munnari.oz.au!cs.mu.OZ.AU!aet
  3. From: aet@mullian.ee.mu.OZ.AU (bert thompson)
  4. Subject: Re: HELP on RSA scheme for Encryption/Decryption
  5. Message-ID: <aet.721885629@munagin>
  6. Sender: news@cs.mu.OZ.AU
  7. Organization: Computer Science, University of Melbourne, Australia
  8. References: <6605@dciem.dciem.dnd.ca>
  9. Distribution: na
  10. Date: Mon, 16 Nov 1992 03:47:09 GMT
  11. Lines: 46
  12.  
  13. jorchard@dciem.dciem.dnd.ca (Jeff Orchard) writes:
  14.  
  15. >I would like to know the algorithm for encrypting/decrypting codes
  16. >with the RSA scheme.  I took it in first year algebra, but I sold my
  17. >textbook and can't remember for the life of me how it went.
  18.  
  19. >Could someone out there with better resources (or better memory)
  20. >help me?
  21.  
  22. --------------------------------------------------------------------------------
  23.  
  24. RSA in 30 seconds:
  25.  
  26. choose two big primes p q  such that p /= q
  27. let n = p * q
  28.  
  29. also choose random e such that e < phi_n and e and phi_n are coprime 
  30.     where
  31.     phi_n = phi n = (p-1)*(q-1) since p and q are prime.
  32.  
  33. (phi is the euler phi function)
  34.  
  35.  
  36. then encode message (a number):
  37.  
  38. m -> m^e (mod n)
  39.  
  40. decode message:
  41.  
  42. c -> c^d (mod n)
  43.     where
  44.     d = inverse e (mod phi_n)
  45.     (i.e. d*e = 1 (mod phi_n))
  46.  
  47. --------------------------------------------------------------------------------
  48.  
  49. well that's the idea essentially. but you also have to write the algorithms
  50. for finding inverses, powers, big primes etc.
  51.  
  52.     bert.
  53.  
  54. --------------------------------------------------------------------------------
  55. bert thompson    aet@munagin.ee.mu.oz.au.
  56. SITEE        school of information technology and electrical engineering
  57.         university of melbourne
  58. --------------------------------------------------------------------------------
  59.