/**
* 解密
*/
private byte[] decode(byte[] pBytes) throws Exception {
Cipher mCipher = Cipher.getInstance("DES");
mCipher.init(Cipher.DECRYPT_MODE, 获取key);
return mCipher.doFinal(pBytes);
}
/**
* 加密
*/
private byte[] encode(byte[] pBytes) throws Exception {
Cipher mCipher = Cipher.getInstance("DES");
mCipher.init(Cipher.ENCRYPT_MODE, 获取key);
return mCipher.doFinal(pBytes);
}
byte数组加密解密
最新推荐文章于 2024-09-20 16:19:55 发布