毕业论文论文范文课程设计实践报告法律论文英语论文教学论文医学论文农学论文艺术论文行政论文管理论文计算机安全
您现在的位置: 毕业论文 >> 计算机安全 >> 正文

vc++基于Misty1算法的加密软件设计+源码 第4页

更新时间:2010-7-12:  来源:毕业论文
vc++基于Misty1算法的加密软件设计+源码 第4页
FL-1输入为:
Y32 = YL‖YR
KLi = KLiL‖KLIr
FL-1的功能:
XL = (YR| KLIr) ∧YL
XR = (XL& KLiL) ∧YR
则输出:
X32 = XL‖XR
3.FO函数
FO函数由32位的输入数据X32和两组子密钥和48位的KIi构成。输入数据X32分为两个16位的L0和R0,64位的KOi 分为4组16位的子密钥,48位本文来自辣文论文网原文请找QQ752018766的KIi 分为3组16位的子密钥,FO函数最后返回一个32位的数据Y32,具体操作由图4所示:
图4  FO函数
FO的输入为:
X32=L0‖R0
KOi= KOi1‖KOi2‖KOi3‖KOi4
KIi= KIi1‖KIi2‖KIi3
FO的功能能表现为:
For i=1 to 3 do:
Rj=FI (Lj-1^KOij,KIij) ^Rj-1
Lj=Rj-1
Y32= (L3^KOi4)R3
4.FI函数
FI函数由16位输入数据和16位的子密钥KIij构成。输入数据X16分为两个不等长的部分即9位的L0和7位的R0,密钥KIij也被分为7位的KIijl和9位的KIijr两部分。FI返回一个16位的数据Y16。在函数中使用了两个S-盒,S7将7比特的输入映射为7比特的输出,S9将9比特的输入映射为9比特的输出。Zero-extend表示在7位的数据x尾部(最右边)添加2个零,将7位转换为9位。Truncate表示9位的数据x的头部(最左边)删除两个位数据,将9位转换为7位。具体操作如图5所示:
图5  FI函数
FI的输入为:
X16= L0‖R0
KIij=KIijL‖KIijR
FI则定义为:
毕业论文http://www.751com.cn
L1=R0
R2=S7[L1] ^(truncate(R1))KIijL
R3=S9[L2] ^(00b‖R2)
L3=R2
Y16=L3‖R3
5.S-boxes
两个S-boxes 既可以由组合逻辑实现,也可以通过查找表来实现。在本设计中由于考虑到加密的速度,所以才用了查表的方法来实现。
S7和S9表如下:
S7[] = {
  54, 50, 62, 56, 22, 34, 94, 96, 38, 6, 63, 93, 2, 18,123, 33,
  55,113, 39,114, 21, 67, 65, 12, 47, 73, 46, 27, 25,111,124, 81,
  53, 9,121, 79, 52, 60, 58, 48,101,127, 40,120,104, 70, 71, 43,
  20,122, 72, 61, 23,109, 13,100, 77, 1, 16, 7, 82, 10,105, 98,
  117,116, 76, 11, 89,106, 0,125,118, 99, 86, 69, 30, 57,126, 87,
  112, 51, 17, 5, 95, 14, 90, 84, 91, 8, 35,103, 32, 97, 28, 66,
  102, 31, 26, 45, 75, 4, 85, 92, 37, 74, 80, 49, 68, 29,115, 44,
  64,107,108, 24,110, 83, 36, 78, 42, 19, 15, 41, 88,119, 59, 3};
S9[] = {
  167,239,161,379,391,334, 9,338, 38,226, 48,358,452,385, 90,397,
  183,253,147,331,415,340,51,362,306,500,262, 82,216,159,356,177,
  175,241,489, 37,206, 17, 0,333, 44,254,378, 58,143,220, 81,400,
  95,3,315,245, 54,235,218,405,472,264,172,494,371,290,399, 76,
 165,197,395,121,257,480,423,212,240,28,462,176,406,507,288,223,501,407,249,265, 89,186,221,428,164, 74,440,196,458,421,350,163,
  232,158,134,354, 13,250,491,142,191, 69,193,425,152,227,366,135,
 344,300,276,242,437,320,113,278, 11,243, 87,317, 36, 93,496, 27,
  487,446,482, 41, 68,156,457,131,326,403,339, 20, 39,115,442,124,
  475,384,508,53,112,170,479,151,126,169, 73,268,279,321,168,364,
  363,292,46,499,393,327,324, 24,456,267,157,460,488,426,309,229,
  439,506,208,271,349,401,434,236, 16,209,359, 52, 56,120,199,277,
  465,416,252,287,246,  6, 83,305,420,345,153,502, 65, 61,244,282,
  173,222,418, 67,386,368,261,101,476,291,195,430, 49, 79,166,330,
 280,383,373,128,382,408,155,495,367,388,274,107,459,417,62,454,132,225,203,316,234, 14,301, 91,503,286,424,211,347,307,140,374,
35,103,125,427, 19,214,453,146,498,314,444,230,256,329,198,285,
  50,116, 78,410, 10,205,510,171,231, 45,139,467, 29, 86,505, 32,
  72,26,342,150,313,490,431,238,411,325,149,473, 40,119,174,355,

上一页  [1] [2] [3] [4] [5] [6] 下一页

vc++基于Misty1算法的加密软件设计+源码 第4页下载如图片无法显示或论文不完整,请联系qq752018766
设为首页 | 联系站长 | 友情链接 | 网站地图 |

copyright©751com.cn 辣文论文网 严禁转载
如果本毕业论文网损害了您的利益或者侵犯了您的权利,请及时联系,我们一定会及时改正。