美文网首页
学习笔记《RSA - 129》

学习笔记《RSA - 129》

作者: 马文Marvin | 来源:发表于2018-04-08 11:16 被阅读54次

RSA (Rivest–Shamir–Adleman) is one of the first public-key cryptosystems and is widely used for secure data transmission. In such a cryptosystem, the encryption key is public and it is different from the decryption key which is kept secret (private). In RSA, this asymmetry is based on the practical difficulty of the factorization of the product of two large prime numbers, the "factoring problem". The acronym RSA is made of the initial letters of the surnames of Ron Rivest, Adi Shamir, and Leonard Adleman, who first publicly described the algorithm in 1978. Clifford Cocks, an English mathematician working for the British intelligence agency Government Communications Headquarters (GCHQ), had developed an equivalent system in 1973, but this was not declassified until 1997

概念讲解

你可以生成一个大质数 P,和一个大质数 Q,然后将 P*Q 的乘积作为 public_key 发布出去,没有人能够有能力知道这个 public_key 是哪两个大质数的乘积,只有你自己知道,而你知道的信息就可以换算出 private_key,这个就是 RSA算法

Ron Rivest(创造者之一) 在 Numberphile 的讲解:
https://www.youtube.com/watch?v=YQw124CtvO0

Computerphile 的一个讲解:
https://www.youtube.com/watch?v=GSIDS_lvRv4

1977年发表的论文《A Method for Obtaining Digital Signatures and Public-Key Cryptosystems》:
http://people.csail.mit.edu/rivest/Rsapaper.pdf

数学部分

假设 Alice 想要通过一个不可靠的媒体接收 Bob 的一条私人讯息。她可以用以下的方式来产生一个公钥和一个私钥:

  1. 随意选择两个大的质数 p 和 q,p 不等于 q,计算 N=pq。
  2. 根据欧拉函数(小于或等于 n 的正整数中与 n 互质的数的数目),求得 r = (p-1)(q-1)
  3. 选择一个小于 r 的整数 e,求得 e 关于模 r 的模反元素(如果两个正整数 a 和 n 互质,那么一定可以找到整数 b,使得 ab-1 被 n 整除,或者说 ab 被 n 除的余数是1。这时,b 就叫做 a 的模反元素),命名为 d。(模反元素存在,当且仅当 e 与 r 互质)
  4. 将 p 和 q 的记录销毁。
    注解:(N,e) 是公钥,(N,d) 是私钥。Alice 将她的公钥 (N,e) 传给 Bob,而将她的私钥 (N,d) 藏起来。
Key generation
Encryption and Decryption

Modular Arithmetic

一个模运算的课程视频:
https://www.youtube.com/watch?v=8SHnXUcQ2Nc

挺意外的,没有想到这么不起眼的模运算,居然有如此大的价值,怪不得课程用了一节课的时间来讲解,后面会继续研究欧拉函数,到时候再回来修订本文~

相关文章

  • 学习笔记《RSA - 129》

    RSA (Rivest–Shamir–Adleman) is one of the first public-ke...

  • 《庄子》学习笔记129

    黄帝将见大隗乎具茨之山,方明为御,昌㝢骖乘,张若、谐朋前马,昆阍、滑稽后车。至于襄城之野,七圣皆迷,无所问涂。 黄...

  • RSA加解密学习笔记

    RSA加解密简单说明: RSA是非对称加密方式,就是说加密解密不是同一个Key。私钥加密公钥解密,待加密的明文字节...

  • 读书笔记129--《曾国藩的经济课》- 量化的历史观

    打卡129(七月第一周) 读书笔记129--《曾国藩的经济课》- 量化的历史观 ...

  • RSA公钥加密算法笔记

    RSA是目前最有影响力和常用的公钥加密算法 这篇笔记目的是梳理RSA算法加解密的证明思路RSA算法是一种非对称密码...

  • 2019-10-11

    今天学习了RSA密钥算法

  • 《金文成〈大学〉学习笔记129》

    《金文成〈大学〉学习笔记129》 今天是戊戌年甲子月癸巳日,冬月廿一,2018年12月27日星期四。 上一节,船山...

  • 学习笔记129-自我激励

    【江湖说️学习日记】 [打卡宝宝]:洋芋. [打卡日期]:2019/04/25 [累计坚持]:这是我坚持学习的第1...

  • 【My learning experience】学习笔记(129

    一、首先确定做镂空字幕的视频,并确定要取的名字,保存到草稿箱。 二、制作文字(与个人水印制作相同) 1、点开始制作...

  • 学习(129)

    今天学习以下几个知识点。 1.国际刑事法院是审理战争罪犯的国际常设法院。 2.“或引渡或起诉”是三国国际民航安全公...

网友评论

      本文标题:学习笔记《RSA - 129》

      本文链接:https://www.haomeiwen.com/subject/fcguhftx.html