diff options
author | Richard Levitte <levitte@openssl.org> | 2015-11-29 20:09:34 +0100 |
---|---|---|
committer | Richard Levitte <levitte@openssl.org> | 2015-12-07 17:39:23 +0100 |
commit | 2db6bf6f856fc7a6e848e3c45b274b327a86784c (patch) | |
tree | 1b8dcbfe303680534358f4746338d3865a7ea9b7 /crypto/include/internal/evp_int.h | |
parent | 6e59a892db781658c050e5217127c4147c116ac9 (diff) | |
download | openssl-2db6bf6f856fc7a6e848e3c45b274b327a86784c.tar.gz |
Make the definition of EVP_MD opaque
This moves the definition to crypto/include/internal/evp_int.h and
defines all the necessary method creators, destructors, writers and
accessors. The name standard for the latter is inspired from the
corresponding functions to manipulate UI methods.
Reviewed-by: Rich Salz <rsalz@openssl.org>
Diffstat (limited to 'crypto/include/internal/evp_int.h')
-rw-r--r-- | crypto/include/internal/evp_int.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/crypto/include/internal/evp_int.h b/crypto/include/internal/evp_int.h index 218aedefed..4372d4bae0 100644 --- a/crypto/include/internal/evp_int.h +++ b/crypto/include/internal/evp_int.h @@ -129,3 +129,20 @@ extern const EVP_PKEY_METHOD dsa_pkey_meth; extern const EVP_PKEY_METHOD ec_pkey_meth; extern const EVP_PKEY_METHOD hmac_pkey_meth; extern const EVP_PKEY_METHOD rsa_pkey_meth; + +struct evp_md_st { + int type; + int pkey_type; + int md_size; + unsigned long flags; + int (*init) (EVP_MD_CTX *ctx); + int (*update) (EVP_MD_CTX *ctx, const void *data, size_t count); + int (*final) (EVP_MD_CTX *ctx, unsigned char *md); + int (*copy) (EVP_MD_CTX *to, const EVP_MD_CTX *from); + int (*cleanup) (EVP_MD_CTX *ctx); + int block_size; + int ctx_size; /* how big does the ctx->md_data need to be */ + /* control function */ + int (*md_ctrl) (EVP_MD_CTX *ctx, int cmd, int p1, void *p2); +} /* EVP_MD */ ; + |