Update x509.go

This commit is contained in:
Sun Yimin 2024-05-23 20:34:40 +08:00 committed by GitHub
parent 6762238407
commit 8787268d3d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1295,7 +1295,7 @@ func signingParamsForKey(key crypto.Signer, sigAlgo SignatureAlgorithm) (Signatu
case elliptic.P521():
defaultAlgo = ECDSAWithSHA512
case sm2.P256():
defaultAlgo = SM2WithSM3
sigAlgo = SM2WithSM3
default:
return 0, ai, errors.New("x509: unsupported elliptic curve")
}