Use BCryptGenRandom on Windows 7 or higher
authorMat <mberchtold@gmail.com>
Sun, 29 May 2016 18:23:22 +0000 (20:23 +0200)
committerRich Salz <rsalz@openssl.org>
Fri, 3 Jun 2016 16:18:59 +0000 (12:18 -0400)
When openssl is compiled with MSVC and _WIN32_WINNT>=0x0601 (Windows 7), BCryptGenRandom is used instead of the legacy CryptoAPI.

This change brings the following benefits:
- Removes dependency on CryptoAPI (legacy API) respectively advapi32.dll
- CryptoAPI Cryptographic Service Providers (rsa full) are not dynamically loaded.
- Allows Universal Windows Platform (UWP) apps to use openssl (CryptGenRandom is not available for Windows store apps)
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Rich Salz <rsalz@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/1142)


No differences found