diff options
author | beck <> | 2002-05-15 02:29:21 +0000 |
---|---|---|
committer | beck <> | 2002-05-15 02:29:21 +0000 |
commit | b64270d1e45fe7f3241e4c9b6ce60d5ac89bc2e9 (patch) | |
tree | fa27cf82a1250b64ed3bf5f4a18c7354d470bbcc /src/lib/libcrypto/evp/p_sign.c | |
parent | e471e1ea98d673597b182ea85f29e30c97cd08b5 (diff) | |
download | openbsd-b64270d1e45fe7f3241e4c9b6ce60d5ac89bc2e9.tar.gz openbsd-b64270d1e45fe7f3241e4c9b6ce60d5ac89bc2e9.tar.bz2 openbsd-b64270d1e45fe7f3241e4c9b6ce60d5ac89bc2e9.zip |
OpenSSL 0.9.7 stable 2002 05 08 merge
Diffstat (limited to 'src/lib/libcrypto/evp/p_sign.c')
-rw-r--r-- | src/lib/libcrypto/evp/p_sign.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/lib/libcrypto/evp/p_sign.c b/src/lib/libcrypto/evp/p_sign.c index 1fa32ac17e..e4ae5906f5 100644 --- a/src/lib/libcrypto/evp/p_sign.c +++ b/src/lib/libcrypto/evp/p_sign.c | |||
@@ -65,7 +65,7 @@ | |||
65 | #ifdef undef | 65 | #ifdef undef |
66 | void EVP_SignInit(EVP_MD_CTX *ctx, EVP_MD *type) | 66 | void EVP_SignInit(EVP_MD_CTX *ctx, EVP_MD *type) |
67 | { | 67 | { |
68 | EVP_DigestInit(ctx,type); | 68 | EVP_DigestInit_ex(ctx,type); |
69 | } | 69 | } |
70 | 70 | ||
71 | void EVP_SignUpdate(EVP_MD_CTX *ctx, unsigned char *data, | 71 | void EVP_SignUpdate(EVP_MD_CTX *ctx, unsigned char *data, |
@@ -84,8 +84,10 @@ int EVP_SignFinal(EVP_MD_CTX *ctx, unsigned char *sigret, unsigned int *siglen, | |||
84 | MS_STATIC EVP_MD_CTX tmp_ctx; | 84 | MS_STATIC EVP_MD_CTX tmp_ctx; |
85 | 85 | ||
86 | *siglen=0; | 86 | *siglen=0; |
87 | EVP_MD_CTX_copy(&tmp_ctx,ctx); | 87 | EVP_MD_CTX_init(&tmp_ctx); |
88 | EVP_DigestFinal(&tmp_ctx,&(m[0]),&m_len); | 88 | EVP_MD_CTX_copy_ex(&tmp_ctx,ctx); |
89 | EVP_DigestFinal_ex(&tmp_ctx,&(m[0]),&m_len); | ||
90 | EVP_MD_CTX_cleanup(&tmp_ctx); | ||
89 | for (i=0; i<4; i++) | 91 | for (i=0; i<4; i++) |
90 | { | 92 | { |
91 | v=ctx->digest->required_pkey_type[i]; | 93 | v=ctx->digest->required_pkey_type[i]; |