From 466bb90298e3734dae8155db745b5d1a029c1e3b Mon Sep 17 00:00:00 2001 From: Looly Date: Thu, 9 Nov 2023 08:52:06 +0800 Subject: [PATCH] fix code --- .../src/main/java/org/dromara/hutool/crypto/bc/ECKeyUtil.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hutool-crypto/src/main/java/org/dromara/hutool/crypto/bc/ECKeyUtil.java b/hutool-crypto/src/main/java/org/dromara/hutool/crypto/bc/ECKeyUtil.java index ab3fd3966..81f7cab77 100644 --- a/hutool-crypto/src/main/java/org/dromara/hutool/crypto/bc/ECKeyUtil.java +++ b/hutool-crypto/src/main/java/org/dromara/hutool/crypto/bc/ECKeyUtil.java @@ -41,7 +41,7 @@ import java.security.PublicKey; import java.security.spec.KeySpec; /** - * EC密钥参数相关工具类封装 + * 椭圆曲线EC(Elliptic Curves)密钥参数相关工具类封装 * * @author looly * @since 5.4.3 @@ -319,7 +319,7 @@ public class ECKeyUtil { public static PrivateKey toSm2PrivateKey(final ECPrivateKey privateKey) { try { final PrivateKeyInfo info = new PrivateKeyInfo( - new AlgorithmIdentifier(X9ObjectIdentifiers.id_ecPublicKey, SmUtil.ID_SM2_PUBLIC_KEY_PARAM), privateKey); + new AlgorithmIdentifier(X9ObjectIdentifiers.id_ecPublicKey, SmUtil.ID_SM2_PUBLIC_KEY_PARAM), privateKey); return KeyUtil.generatePrivateKey("SM2", info.getEncoded()); } catch (final IOException e) { throw new IORuntimeException(e);