diff options
author | Dr. Stephen Henson <steve@openssl.org> | 2011-02-12 18:25:18 +0000 |
---|---|---|
committer | Dr. Stephen Henson <steve@openssl.org> | 2011-02-12 18:25:18 +0000 |
commit | e47af46cd839c549fac2d9f8a2951c35c0113fbf (patch) | |
tree | 2fa93ea50fa6307c189711053274f8bba9949572 /fips/sha/fips_shatest.c | |
parent | 36246be9151adf1049d62f1261f87f9e3719afac (diff) |
Change FIPS source and utilities to use the "FIPS_" names directly
instead of using regular OpenSSL API names.
Diffstat (limited to 'fips/sha/fips_shatest.c')
-rw-r--r-- | fips/sha/fips_shatest.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/fips/sha/fips_shatest.c b/fips/sha/fips_shatest.c index 480b990fb8..9675518513 100644 --- a/fips/sha/fips_shatest.c +++ b/fips/sha/fips_shatest.c @@ -300,7 +300,7 @@ static int print_dgst(const EVP_MD *emd, FILE *out, { int i, mdlen; unsigned char md[EVP_MAX_MD_SIZE]; - if (!EVP_Digest(Msg, Msglen, md, (unsigned int *)&mdlen, emd, NULL)) + if (!FIPS_digest(Msg, Msglen, md, (unsigned int *)&mdlen, emd)) { fputs("Error calculating HASH\n", stderr); return 0; @@ -321,7 +321,7 @@ static int print_monte(const EVP_MD *md, FILE *out, unsigned char *m1, *m2, *m3, *p; unsigned int mlen, m1len, m2len, m3len; - EVP_MD_CTX_init(&ctx); + FIPS_md_ctx_init(&ctx); if (SeedLen > EVP_MAX_MD_SIZE) mlen = SeedLen; @@ -346,17 +346,17 @@ static int print_monte(const EVP_MD *md, FILE *out, { for (i = 0; i < 1000; i++) { - EVP_DigestInit_ex(&ctx, md, NULL); - EVP_DigestUpdate(&ctx, m1, m1len); - EVP_DigestUpdate(&ctx, m2, m2len); - EVP_DigestUpdate(&ctx, m3, m3len); + FIPS_digestinit(&ctx, md); + FIPS_digestupdate(&ctx, m1, m1len); + FIPS_digestupdate(&ctx, m2, m2len); + FIPS_digestupdate(&ctx, m3, m3len); p = m1; m1 = m2; m1len = m2len; m2 = m3; m2len = m3len; m3 = p; - EVP_DigestFinal_ex(&ctx, m3, &m3len); + FIPS_digestfinal(&ctx, m3, &m3len); } fprintf(out, "COUNT = %d\n", j); fputs("MD = ", out); @@ -378,7 +378,7 @@ static int print_monte(const EVP_MD *md, FILE *out, if (m3) OPENSSL_free(m3); - EVP_MD_CTX_cleanup(&ctx); + FIPS_md_ctx_cleanup(&ctx); return ret; } |