public class SM2Util extends Object
| 构造器和说明 |
|---|
SM2Util() |
| 限定符和类型 | 方法和说明 |
|---|---|
static byte[] |
decrypt(byte[] privateKey,
byte[] encryptedData) |
static byte[] |
decrypt(String privateKeyStr,
String encryptedDataStr) |
static String |
encrypt(byte[] publicKey,
byte[] data) |
static String |
encrypt(String publicKeyStr,
String dataStr) |
static Map |
generateKeyPair() |
public static Map generateKeyPair()
public static String encrypt(byte[] publicKey, byte[] data) throws IOException
IOExceptionpublic static byte[] decrypt(byte[] privateKey,
byte[] encryptedData)
throws IOException
IOExceptionpublic static String encrypt(String publicKeyStr, String dataStr) throws IOException
IOExceptionpublic static byte[] decrypt(String privateKeyStr, String encryptedDataStr) throws IOException
IOExceptionCopyright © 2024. All rights reserved.