feat: crypto

This commit is contained in:
Bobo
2025-05-07 15:57:19 +08:00
parent 0420e35a30
commit 78cef077e5
3 changed files with 20 additions and 8 deletions

View File

@@ -15,7 +15,7 @@ func TestDecryptAES(t *testing.T) {
aesKey = DefaultAESKey
plainText := []byte("cloud123456")
encryptText, err := AesEncrypt(plainText, aesKey)
encryptText, err := AesEncrypt(plainText, aesKey, nil)
if err != nil {
fmt.Println(err)
return
@@ -30,7 +30,7 @@ func TestDecryptAES(t *testing.T) {
return
}
decryptText, err := AesDecrypt(bytesPass, aesKey)
decryptText, err := AesDecrypt(bytesPass, aesKey, nil)
if err != nil {
fmt.Println(err)
return