Cryptography
Whomio
Some things are not immediately understood, but need a brewing process.
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
背包密码
/************************背包向量A={a1,a2,....,an}是超递增的,B为公开钥,t、k为私钥每个明文用一个5位的二进制表示00000-11010每组包含两个明文s为背包容积,若是s>=an,则说明xn=1,若s<a,则说明xn=0c=B*m(mod k)=t*A*m(mod k)m为二进制代码,c为整数A*m=c*t^(-1)...原创 2019-01-10 20:29:28 · 1792 阅读 · 1 评论 -
仿射变换
/**********************c=E[a,b](m)=am+b(mod 26)m=D[a,b](c)=a^(-1)(c-b)(mod 26)0<=a,b<=25;gcd(a,26)=1支持大小写英文字母**********************/#include <bits/stdc++.h>using namespace std;...原创 2019-01-10 20:31:31 · 470 阅读 · 0 评论 -
多表变换
/******************C=AM+BM=A^(-1)(C-B)******************/#include<iostream>#include<string>#include<math.h>#include<iomanip>using namespace std;int GetdetA(int **a...原创 2019-01-10 20:33:02 · 364 阅读 · 0 评论
分享