diff --git a/System/Jwt/JWTConstant.php b/System/Jwt/JWTConstant.php deleted file mode 100644 index 97fabba1..00000000 --- a/System/Jwt/JWTConstant.php +++ /dev/null @@ -1,31 +0,0 @@ -setScene($jwt['scene'] ?? 'application'); - $this->setEncrypt($jwt['encrypt'] ?? JWTConstant::AES_128_ECB); $this->setKey($jwt['key'] ?? get_called_class()); - $length = openssl_cipher_iv_length($this->encrypt); if ($length > 0) { $defaultIv = openssl_random_pseudo_bytes($length); diff --git a/System/Jwt/JwtHelper.php b/System/Jwt/JwtHelper.php index ea8862fc..306fef6b 100644 --- a/System/Jwt/JwtHelper.php +++ b/System/Jwt/JwtHelper.php @@ -26,7 +26,7 @@ trait JwtHelper private string $scene = 'default'; - private string $encrypt = ''; + private string $encrypt = 'aes-128-ecb'; private string $iv = '';