diff options
author | Johannes Schindelin <johannes.schindelin@gmx.de> | 2017-06-23 01:04:56 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2017-08-28 14:56:56 +0200 |
commit | e35205a0c4f8d80dc9e878049a0fb0eb18f61dbf (patch) | |
tree | 1bca113b655e95ab19bd2f04d408d1e1ca7b2026 /lib/vtls/vtls.h | |
parent | 52e8237bfc66a2a8324dbb558c1f0704aa0f8c0e (diff) |
vtls: move md5sum into the Curl_ssl struct
The MD5 summing is also an SSL backend-specific function. So let's
include it, offering the previous fall-back code as a separate function
now: Curl_none_md5sum(). To allow for that, the signature had to be
changed so that an error could be returned from the implementation
(Curl_none_md5sum() can run out of memory).
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Diffstat (limited to 'lib/vtls/vtls.h')
-rw-r--r-- | lib/vtls/vtls.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/vtls/vtls.h b/lib/vtls/vtls.h index a568999e8..f95b9236e 100644 --- a/lib/vtls/vtls.h +++ b/lib/vtls/vtls.h @@ -54,6 +54,9 @@ struct Curl_ssl { struct curl_slist *(*engines_list)(struct Curl_easy *data); bool (*false_start)(void); + + CURLcode (*md5sum)(unsigned char *input, size_t inputlen, + unsigned char *md5sum, size_t md5sumlen); }; #ifdef USE_SSL @@ -74,6 +77,8 @@ CURLcode Curl_none_set_engine(struct Curl_easy *data, const char *engine); CURLcode Curl_none_set_engine_default(struct Curl_easy *data); struct curl_slist *Curl_none_engines_list(struct Curl_easy *data); bool Curl_none_false_start(void); +CURLcode Curl_none_md5sum(unsigned char *input, size_t inputlen, + unsigned char *md5sum, size_t md5len); #include "openssl.h" /* OpenSSL versions */ #include "gtls.h" /* GnuTLS versions */ |