| 123456789101112131415161718192021222324252627282930 |
- import com.min.base64.Base64;
- import com.min.des.DesUtils;
- public class TestMain {
- /**
- * @param args
- * @throws Exception
- */
- public static void main(String[] args) throws Exception {
- // System.out.println(SHA1.enCoded("10000004" + "q1111111"));
- // System.out.println(SHA1.enCoded("10000005" + "q1111111"));
- // System.out.println(SHA1.enCoded("10000006" + "q1111111"));
- // System.out.println(SHA1.enCoded("10000007" + "q1111111"));
- String desDe = Base64.encode(DesUtils.getInstance().encrypt(Base64.encode("123432145321").getBytes(),"123445678".getBytes(), null));
-
-
- System.out.println(desDe);
- String string = new String(DesUtils.getInstance().decrypt(Base64.decodeBytes(desDe), "123445678".getBytes(), null));
- String code = Base64.decode(string);
- System.out.println(code);
- // byte[] decrypt = DesUtils.getInstance().decrypt(code.getBytes(), "123445678".getBytes(), null);
- // System.out.println(decrypt.toString());
- }
- }
|