Don't default to SHA-1 in |EVP_DigestSignInit|/|EVP_DigestVerifyInit|.
This removes a hard link-time dependency on the SHA-1 code. The code was self-contradictory in whether it defaulted to SHA-1 or refused to default to SHA-1. Change-Id: I5ad7949bdd529df568904f87870313e3d8a57e72 Reviewed-on: https://boringssl-review.googlesource.com/5833 Reviewed-by: Adam Langley <alangley@gmail.com>
This commit is contained in:
parent
e564a5ba6e
commit
659806d7ff
@ -55,7 +55,6 @@
|
|||||||
|
|
||||||
#include <openssl/evp.h>
|
#include <openssl/evp.h>
|
||||||
|
|
||||||
#include <openssl/digest.h>
|
|
||||||
#include <openssl/err.h>
|
#include <openssl/err.h>
|
||||||
|
|
||||||
#include "internal.h"
|
#include "internal.h"
|
||||||
@ -78,10 +77,6 @@ static int do_sigver_init(EVP_MD_CTX *ctx, EVP_PKEY_CTX **pctx,
|
|||||||
}
|
}
|
||||||
ctx->pctx_ops = &md_pctx_ops;
|
ctx->pctx_ops = &md_pctx_ops;
|
||||||
|
|
||||||
if (type == NULL) {
|
|
||||||
type = EVP_sha1();
|
|
||||||
}
|
|
||||||
|
|
||||||
if (type == NULL) {
|
if (type == NULL) {
|
||||||
OPENSSL_PUT_ERROR(EVP, EVP_R_NO_DEFAULT_DIGEST);
|
OPENSSL_PUT_ERROR(EVP, EVP_R_NO_DEFAULT_DIGEST);
|
||||||
return 0;
|
return 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user