Skip to content

Commit c8ac68f

Browse files
committed
fix newDSA3
1 parent eb51754 commit c8ac68f

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

dsa.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -267,7 +267,9 @@ func newDSA3(params DSAParameters, X, Y BigInt) (C.GO_EVP_PKEY_PTR, error) {
267267
if C.go_openssl_OSSL_PARAM_BLD_push_BN(bld, paramPubKey, pub) != 1 {
268268
return nil, newOpenSSLError("OSSL_PARAM_BLD_push_BN")
269269
}
270-
selection = C.int(C.GO_EVP_PKEY_PUBLIC_KEY)
270+
if X == nil {
271+
selection = C.int(C.GO_EVP_PKEY_PUBLIC_KEY)
272+
}
271273
}
272274
if X != nil {
273275
priv := bigToBN(X)

0 commit comments

Comments
 (0)