修复JWTSignerUtil.createSigner中algorithmId未转换问题(issue#3806@Github)

This commit is contained in:
Looly
2024-12-03 23:54:08 +08:00
parent cc82342001
commit af5cddf80f
2 changed files with 3 additions and 2 deletions

View File

@@ -278,7 +278,7 @@ public class JWTSignerUtil {
if (key instanceof PrivateKey || key instanceof PublicKey) {
// issue3205@Github
if(ReUtil.isMatch("ES\\d{3}", algorithmId)){
return new EllipticCurveJWTSigner(algorithmId, key);
return new EllipticCurveJWTSigner(AlgorithmUtil.getAlgorithm(algorithmId), key);
}
return new AsymmetricJWTSigner(AlgorithmUtil.getAlgorithm(algorithmId), key);