[{"createTime":1735734952000,"id":1,"img":"hwy_ms_500_252.jpeg","link":"https://activity.huaweicloud.com/cps.html?fromacct=261f35b6-af54-4511-a2ca-910fa15905d1&utm_source=V1g3MDY4NTY=&utm_medium=cps&utm_campaign=201905","name":"华为云秒杀","status":9,"txt":"华为云38元秒杀","type":1,"updateTime":1735747411000,"userId":3},{"createTime":1736173885000,"id":2,"img":"txy_480_300.png","link":"https://cloud.tencent.com/act/cps/redirect?redirect=1077&cps_key=edb15096bfff75effaaa8c8bb66138bd&from=console","name":"腾讯云秒杀","status":9,"txt":"腾讯云限量秒杀","type":1,"updateTime":1736173885000,"userId":3},{"createTime":1736177492000,"id":3,"img":"aly_251_140.png","link":"https://www.aliyun.com/minisite/goods?userCode=pwp8kmv3","memo":"","name":"阿里云","status":9,"txt":"阿里云2折起","type":1,"updateTime":1736177492000,"userId":3},{"createTime":1735660800000,"id":4,"img":"vultr_560_300.png","link":"https://www.vultr.com/?ref=9603742-8H","name":"Vultr","status":9,"txt":"Vultr送$100","type":1,"updateTime":1735660800000,"userId":3},{"createTime":1735660800000,"id":5,"img":"jdy_663_320.jpg","link":"https://3.cn/2ay1-e5t","name":"京东云","status":9,"txt":"京东云特惠专区","type":1,"updateTime":1735660800000,"userId":3},{"createTime":1735660800000,"id":6,"img":"new_ads.png","link":"https://www.iodraw.com/ads","name":"发布广告","status":9,"txt":"发布广告","type":1,"updateTime":1735660800000,"userId":3},{"createTime":1735660800000,"id":7,"img":"yun_910_50.png","link":"https://activity.huaweicloud.com/discount_area_v5/index.html?fromacct=261f35b6-af54-4511-a2ca-910fa15905d1&utm_source=aXhpYW95YW5nOA===&utm_medium=cps&utm_campaign=201905","name":"底部","status":9,"txt":"高性能云服务器2折起","type":2,"updateTime":1735660800000,"userId":3}]
4.10.已知e=31,n=3599,求私钥d
答: e=31,n=3599,p=59,q=61
φ(n)=(p-1)(q-1)=3480
31d mod 3480=1
31d-3480k=1-----a
31d-8k=1------b
7d-8k=1------c
7d-k=1--------e,令d=1,得到k=6
将k=6代入c得d=7
将d=7代入b得k=27
将k=27代入a得d=3031
4.11.已知n=21,取公钥e=5,明文消息m=8,试用RSA加密m求密文c,并解密验证
加密得c = me mod n解得c=8
解密得m=cd mod n 解得 m=8
4.12已知p=43,q=59,e=13
(1)用欧几里得迭代算法求d
n=pq=2537
φ(n)=(p-1)(q-1)=2436
13d mod 2436=1
13d -2436k=1----x
13d-5k=1-----a
3d-5k=1------b
3d-2k=1------b
d-2*k=------c
令k=0,得到d=1
将d=1代入c得k=1
将k=1代入b得d=2
将d=2代入a得k=5
将k=5代入x得d=937
(2)明文 public key encryptions进行分组得=pu bl ic ke ye nc ry pt io ns
根据Z26=1520 0111 0802 1004 2404 1302 1724 1519 0814 1318
因为公钥为(13,2537)
所以加密后为:
C1=152013 mod 2537 = 0095
C2=011113 mod 2537 = 1648
C3=080213 mod 2537 = 1410
C4=100413 mod 2537 = 1299
C5=240413 mod 2537 = 1365
C6=130213 mod 2537 = 1379
C7=172413 mod 2537 = 2333
C8=151913 mod 2537 = 2132
C9=081413 mod 2537 = 1751
C10=131813 mod 2537 = 1324
* 取 p=17,q=11,计算出相应的密钥并利用公钥对明文m=88加密,利用私钥对密文进行解密
取e=3 n=pq=187
C=me mod n =883 mod 187 =44
根据辗转相除法得3d mod 160=1
解得d=107
解密得m=cd mod n解得m=88.