projects
/
openssl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Implement deterministic ECDSA sign (RFC6979)
[openssl.git]
/
crypto
/
dsa
/
dsa_sign.c
diff --git
a/crypto/dsa/dsa_sign.c
b/crypto/dsa/dsa_sign.c
index d942fa2afea4ea7cd004f72bf8ffb309715ba8aa..96d103d6f26f12bac887cb81d37663c1a1b15828 100644
(file)
--- a/
crypto/dsa/dsa_sign.c
+++ b/
crypto/dsa/dsa_sign.c
@@
-151,7
+151,9
@@
int DSA_SIG_set0(DSA_SIG *sig, BIGNUM *r, BIGNUM *s)
}
int ossl_dsa_sign_int(int type, const unsigned char *dgst, int dlen,
}
int ossl_dsa_sign_int(int type, const unsigned char *dgst, int dlen,
- unsigned char *sig, unsigned int *siglen, DSA *dsa)
+ unsigned char *sig, unsigned int *siglen, DSA *dsa,
+ unsigned int nonce_type, const char *digestname,
+ OSSL_LIB_CTX *libctx, const char *propq)
{
DSA_SIG *s;
{
DSA_SIG *s;
@@
-159,7
+161,8
@@
int ossl_dsa_sign_int(int type, const unsigned char *dgst, int dlen,
if (dsa->libctx == NULL || dsa->meth != DSA_get_default_method())
s = DSA_do_sign(dgst, dlen, dsa);
else
if (dsa->libctx == NULL || dsa->meth != DSA_get_default_method())
s = DSA_do_sign(dgst, dlen, dsa);
else
- s = ossl_dsa_do_sign_int(dgst, dlen, dsa);
+ s = ossl_dsa_do_sign_int(dgst, dlen, dsa,
+ nonce_type, digestname, libctx, propq);
if (s == NULL) {
*siglen = 0;
return 0;
if (s == NULL) {
*siglen = 0;
return 0;
@@
-172,7
+175,8
@@
int ossl_dsa_sign_int(int type, const unsigned char *dgst, int dlen,
int DSA_sign(int type, const unsigned char *dgst, int dlen,
unsigned char *sig, unsigned int *siglen, DSA *dsa)
{
int DSA_sign(int type, const unsigned char *dgst, int dlen,
unsigned char *sig, unsigned int *siglen, DSA *dsa)
{
- return ossl_dsa_sign_int(type, dgst, dlen, sig, siglen, dsa);
+ return ossl_dsa_sign_int(type, dgst, dlen, sig, siglen, dsa,
+ 0, NULL, NULL, NULL);
}
/* data has already been hashed (probably with SHA or SHA-1). */
}
/* data has already been hashed (probably with SHA or SHA-1). */