diff options
author | Adam Langley <agl@chromium.org> | 2014-07-30 16:02:14 -0700 |
---|---|---|
committer | Adam Langley <agl@google.com> | 2014-07-31 22:03:11 +0000 |
commit | eb7d2ed1fe8a33b3e3871502ba7e12efaf94360c (patch) | |
tree | f6bcb80a83aef47e8a23210618792c08c54cba92 /include/openssl/md5.h | |
parent | 60d4c0e81042e4c014f38575a72c4befded62eef (diff) | |
download | boringssl-eb7d2ed1fe8a33b3e3871502ba7e12efaf94360c.zip boringssl-eb7d2ed1fe8a33b3e3871502ba7e12efaf94360c.tar.gz boringssl-eb7d2ed1fe8a33b3e3871502ba7e12efaf94360c.tar.bz2 |
Add visibility rules.
This change marks public symbols as dynamically exported. This means
that it becomes viable to build a shared library of libcrypto and libssl
with -fvisibility=hidden.
On Windows, one not only needs to mark functions for export in a
component, but also for import when using them from a different
component. Because of this we have to build with
|BORINGSSL_IMPLEMENTATION| defined when building the code. Other
components, when including our headers, won't have that defined and then
the |OPENSSL_EXPORT| tag becomes an import tag instead. See the #defines
in base.h
In the asm code, symbols are now hidden by default and those that need
to be exported are wrapped by a C function.
In order to support Chromium, a couple of libssl functions were moved to
ssl.h from ssl_locl.h: ssl_get_new_session and ssl_update_cache.
Change-Id: Ib4b76e2f1983ee066e7806c24721e8626d08a261
Reviewed-on: https://boringssl-review.googlesource.com/1350
Reviewed-by: Adam Langley <agl@google.com>
Diffstat (limited to 'include/openssl/md5.h')
-rw-r--r-- | include/openssl/md5.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/include/openssl/md5.h b/include/openssl/md5.h index 7a1a00f..dc800c0 100644 --- a/include/openssl/md5.h +++ b/include/openssl/md5.h @@ -73,23 +73,23 @@ extern "C" { #define MD5_DIGEST_LENGTH 16 /* MD51_Init initialises |md5| and returns 1. */ -int MD5_Init(MD5_CTX *md5); +OPENSSL_EXPORT int MD5_Init(MD5_CTX *md5); /* MD5_Update adds |len| bytes from |data| to |md5| and returns one. */ -int MD5_Update(MD5_CTX *md5, const void *data, size_t len); +OPENSSL_EXPORT int MD5_Update(MD5_CTX *md5, const void *data, size_t len); /* MD5_Final adds the final padding to |md5| and writes the resulting digest to * |md|, which must have at least |MD5_DIGEST_LENGTH| bytes of space. It * returns one. */ -int MD5_Final(uint8_t *md, MD5_CTX *md5); +OPENSSL_EXPORT int MD5_Final(uint8_t *md, MD5_CTX *md5); /* MD5 writes the digest of |len| bytes from |data| to |out| and returns |out|. * There must be at least |MD5_DIGEST_LENGTH| bytes of space in |out|. */ -uint8_t *MD5(const uint8_t *data, size_t len, uint8_t *out); +OPENSSL_EXPORT uint8_t *MD5(const uint8_t *data, size_t len, uint8_t *out); /* MD5_Transform is a low-level function that performs a single, MD5 block * transformation using the state from |md5| and 64 bytes from |block|. */ -void MD5_Transform(MD5_CTX *md5, const uint8_t *block); +OPENSSL_EXPORT void MD5_Transform(MD5_CTX *md5, const uint8_t *block); struct md5_state_st { uint32_t A, B, C, D; |