diff options
-rw-r--r-- | crypto/capi_util.h | 12 | ||||
-rw-r--r-- | crypto/nss_util.h | 5 | ||||
-rw-r--r-- | crypto/nss_util_internal.h | 6 |
3 files changed, 14 insertions, 9 deletions
diff --git a/crypto/capi_util.h b/crypto/capi_util.h index faaf012..b61c268 100644 --- a/crypto/capi_util.h +++ b/crypto/capi_util.h @@ -9,6 +9,8 @@ #include <windows.h> #include <wincrypt.h> +#include "crypto/crypto_api.h" + namespace crypto { // CryptAcquireContext when passed CRYPT_NEWKEYSET or CRYPT_DELETEKEYSET in @@ -21,11 +23,11 @@ namespace crypto { // "The CryptAcquireContext function is generally thread safe unless // CRYPT_NEWKEYSET or CRYPT_DELETEKEYSET is specified in the dwFlags // parameter." -BOOL CryptAcquireContextLocked(HCRYPTPROV* prov, - LPCWSTR container, - LPCWSTR provider, - DWORD prov_type, - DWORD flags); +CRYPTO_API BOOL CryptAcquireContextLocked(HCRYPTPROV* prov, + LPCWSTR container, + LPCWSTR provider, + DWORD prov_type, + DWORD flags); } // namespace crypto diff --git a/crypto/nss_util.h b/crypto/nss_util.h index c350c93..1244db9 100644 --- a/crypto/nss_util.h +++ b/crypto/nss_util.h @@ -8,6 +8,7 @@ #include <string> #include "base/basictypes.h" +#include "crypto/crypto_api.h" #if defined(USE_NSS) class FilePath; @@ -32,12 +33,12 @@ void EarlySetupForNSSInit(); // Initialize NRPR if it isn't already initialized. This function is // thread-safe, and NSPR will only ever be initialized once. -void EnsureNSPRInit(); +void CRYPTO_API EnsureNSPRInit(); // Initialize NSS if it isn't already initialized. This must be called before // any other NSS functions. This function is thread-safe, and NSS will only // ever be initialized once. -void EnsureNSSInit(); +void CRYPTO_API EnsureNSSInit(); // Call this before calling EnsureNSSInit() will force NSS to initialize // without a persistent DB. This is used for the special case where access of diff --git a/crypto/nss_util_internal.h b/crypto/nss_util_internal.h index e90e4c4..4d6a928 100644 --- a/crypto/nss_util_internal.h +++ b/crypto/nss_util_internal.h @@ -8,6 +8,8 @@ #include <secmodt.h> +#include "crypto/crypto_api.h" + // These functions return a type defined in an NSS header, and so cannot be // declared in nss_util.h. Hence, they are declared here. @@ -16,14 +18,14 @@ namespace crypto { // Returns a reference to the default NSS key slot for storing // public-key data only (e.g. server certs). Caller must release // returned reference with PK11_FreeSlot. -PK11SlotInfo* GetPublicNSSKeySlot(); +CRYPTO_API PK11SlotInfo* GetPublicNSSKeySlot(); // Returns a reference to the default slot for storing private-key and // mixed private-key/public-key data. Returns a hardware (TPM) NSS // key slot if on ChromeOS and EnableTPMForNSS() has been called // successfully. Caller must release returned reference with // PK11_FreeSlot. -PK11SlotInfo* GetPrivateNSSKeySlot(); +CRYPTO_API PK11SlotInfo* GetPrivateNSSKeySlot(); // A helper class that acquires the SECMOD list read lock while the // AutoSECMODListReadLock is in scope. |