下面是我根据《密码编码学与网络安全:原理与实践》(第二版,电子工业出版社)一书中S-DES编的一个与书上对应的S-DES程序,能通过编译,且正确 #includestdio.hmain(){ int i,temp,temp1,a[8],k[10],k1[8],k2[8],t[8],t1[8],t2[8],p4[4],m[8];
int p10[10]={3,5,2,7,4,10,1,9,8,6};
int p8[8]={6,3,7,4,8,5,10,9};
int ip[8]={2,6,3,1,4,8,5,7};
int ip1[8]={4,1,3,5,7,2,8,6};
int ep[8]={4,1,2,3,2,3,4,1};
int s0[4][4]={{1,0,3,2},{3,2,1,0},{0,2,1,3},{3,1,3,2}};
int s1[4][4]={{0,1,2,3},{2,0,1,3},{3,0,1,0},{2,1,0,3}};
char c='c';while(c=='c...[ 查看全文 ]