public class EncryptionUtil extends Object
| 限定符和类型 | 方法和说明 |
|---|---|
String |
decodeAes(String content,
String password)
解密AES加密过的字符串
|
String |
decodeBase64(String content)
BASE64解码
|
String |
encodeAes(String content,
String password)
AES加密字符串
|
String |
encodeBase64(String content)
BASE64编码
|
String |
encodeMd5(String body)
MD5 encryption
|
String |
encodeSha256Hmac(String str,
String secret)
sha256 Hmac加密
|
static EncryptionUtil |
of() |
String |
sha1Hmac(String str,
String secret) |
public static EncryptionUtil of()
public String encodeMd5(String body)
body - need to encryptionpublic String encodeSha256Hmac(String str, String secret)
str - 需要加密的消息secret - 秘钥public String sha1Hmac(String str, String secret)
str - 需要加密的内容secret - 秘钥public String encodeAes(String content, String password)
content - 需要被加密的字符串password - 加密需要的密码Copyright © 2019. All rights reserved.