mingwen.txt
来自「整体思路 用createkey.java 文件来产生秘钥」· 文本 代码 · 共 67 行
TXT
67 行
import java.io.*;import java.awt.*;import java.awt.event.*;import java.util.*;import java.math.*;public class jiemi{ int b; byte tom[]=new byte[17]; BigInteger n; BigInteger e; BigInteger d; File f; File ff; jiemi(BigInteger n,BigInteger e,BigInteger d,File f,File ff) { this.n=n; this.e=e; this.d=d; this.f=f; this.ff=ff; try{ FileInputStream in=new FileInputStream(f); FileOutputStream out=new FileOutputStream(ff); while((b=in.read(tom,1,16))!=-1) { BigInteger c=new BigInteger(tom); BigInteger mm=c.modPow(d,n); byte tom2[]=new byte[15]; tom2=mm.toByteArray(); String str=c.toString(16); str=mm.toString(16); System.out.println("mm:"+str); boolean flag=false; String sss=mm.toString(16); if(sss.startsWith("8")){ flag=true; } if(tom2.length==16) out.write(tom2, 1, 15); else if(tom2.length==15) out.write(tom2,0,tom2.length); else if(tom2.length<15&&flag==false) out.write(tom2, 0, tom2.length); else if(tom2.length<15&&flag==true) out.write(tom2,1,tom2.length-1); for(int j=0;j<16;j++) tom[j]=0; } in.close(); out.close(); } catch(IOException ffe) { System.out.println("File read Error"+ffe); } }}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?