Commit graph

47 commits

Author SHA1 Message Date
Hans Leidekker
96692a2c21 bcrypt: Add support for PSS padding.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=53972
2022-12-06 17:12:31 +01:00
Hans Leidekker
6f5028dd03 bcrypt: Add full support for algorithm pseudo-handles. 2022-09-13 16:22:20 +02:00
Chris Denton
5df4ff1341 bcrypt: Add basic support for pseudo-handles.
Support constant values for algorithm handles in `BCryptGenRandom` and make no attempt to dereference such handles.
2022-09-09 23:21:40 +02:00
Martin Storsjö
fcb553ffc2 bcrypt: Fix the non-PE build after ECDH_P384 was added.
This fixes non-PE builds after
5253c8d77e.

Signed-off-by: Martin Storsjö <martin@martin.st>
2022-08-24 09:04:56 -05:00
Hans Leidekker
5253c8d77e bcrypt: Support ECDH_P384 key import/export. 2022-08-23 09:40:56 -05:00
Santino Mazza
4a395899ea bcrypt/tests: Test for BCryptEncrypt with RSA keys.
Signed-off-by: Santino Mazza <mazzasantino1206@gmail.com>
2022-08-03 15:09:02 +02:00
Santino Mazza
2132d38347 bcrypt: Add BCRYPT_KEY_BLOB struct definition.
Signed-off-by: Santino Mazza <mazzasantino1206@gmail.com>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-02-14 21:20:41 +01:00
Hans Leidekker
2795c7f995 bcrypt: Add support for exporting RSA private keys.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=52060
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-12-03 16:56:09 +01:00
Hans Leidekker
7cf9a75dfa bcrypt: Add support for importing and exporting DSS private keys.
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-06-03 21:46:30 +02:00
Hans Leidekker
c2a4a4ec3c bcrypt: Add support for BCRYPT_DSA_ALGORITHM.
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-05-29 20:05:30 +02:00
Hans Leidekker
0e17045288 bcrypt: Implement BCryptDeriveKeyCapi.
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-05-27 00:14:14 +02:00
Hans Leidekker
2bd5a8d572 bcrypt: Support retrieving the PaddingSchemes property for RSA.
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-02-17 15:05:00 +01:00
Derek Lesho
c2840dce7f bcrypt/tests: Add tests for BCRYPT_KDF_HASH.
Signed-off-by: Derek Lesho <dlesho@codeweavers.com>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-01-08 21:10:38 +01:00
Derek Lesho
044d585151 bcrypt/tests: Add test for BCryptSecretAgreement.
Signed-off-by: Derek Lesho <dlesho@codeweavers.com>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-01-08 21:10:35 +01:00
Hans Leidekker
04631f9c6e bcrypt: Implement BCryptEnumAlgorithms.
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-09-30 22:24:27 +02:00
Hans Leidekker
4c649116a5 bcrypt: Add support for BCRYPT_RSA_SIGN_ALGORITHM.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=47371
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-06-17 20:47:34 +02:00
Hans Leidekker
c1746612b2 bcrypt: Add stub implementations of BCryptEnumContextFunctions and BCryptFreeBuffer.
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-06-17 20:47:32 +02:00
Martin Liska
9afc341c4f include: Avoid compound literals for WCHAR strings.
Starting from GCC 9, compound liferal's scope has changed:
https://www.gnu.org/software/gcc/gcc-9/porting_to.html#complit

Signed-off-by: Martin Liska <mliska@suse.cz>
Signed-off-by: Marcus Meissner <meissner@suse.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-06-12 11:44:26 +02:00
Alistair Leslie-Hughes
eb615ea0cb bcrypt: Add BCryptDeriveKey stub.
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-05-28 12:06:46 +02:00
Alistair Leslie-Hughes
08bc5b0d34 bcrypt: Add BCryptDestroySecret/BCryptSecretAgreement stubs.
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-05-28 12:06:46 +02:00
Hans Leidekker
98ea906b96 bcrypt: Implement BCRYPT_HASH_REUSABLE_FLAG.
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-03-06 18:32:00 +01:00
Hans Leidekker
f0a18f6f19 bcrypt: Implement BCryptDeriveKeyPBKDF2.
Based on a patch by Jack Grigg.

Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=42704
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-02-13 19:45:24 +01:00
Hans Leidekker
73b695f059 bcrypt: Implement BCryptGenerate/FinalizeKeyPair for ECDH P256.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=46564
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-02-13 19:45:24 +01:00
Kimmo Myllyvirta
b3c8723bd4 bcrypt: Initial implementation for RSA key import and signature verification.
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-03-26 21:06:20 +02:00
Michael Müller
76b6c360fa bcrypt: Implement importing of ECDSA keys.
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-03-26 21:06:04 +02:00
Michael Müller
1f78267530 include: Add ecdsa and asymmetric key related bcrypt definitions.
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-03-21 10:41:22 +01:00
Michael Müller
3fe621b6e5 bcrypt/tests: Add tests for AES GCM mode.
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-03-19 13:15:10 +01:00
Hans Leidekker
c77d5c65fb bcrypt: Partial implementation of BCryptImportKey and BCryptExportKey.
Based on a patch by Michael Müller.

Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-02-28 17:24:38 +01:00
Dmitry Timoshkov
76bc8d01c0 bcrypt: Add some crypto-provider related stubs.
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-12-14 20:30:10 +01:00
Jacek Caban
e73d4e55a9 bcrypt: Added support for MD4 hashes.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-12-07 20:11:11 +01:00
Jacek Caban
85657376b3 bcrypt: Added MD2 hash support.
By adopting rsaenh implementation.

Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-12-07 20:10:28 +01:00
Hans Leidekker
63e3179c64 include: Add missing BCRYPT_CHAIN_MODE definitions.
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Vijay Kiran Kamuju <infyquest@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-11-08 20:23:38 +01:00
Hans Leidekker
ab575f3d2b include: Add BCRYPT_KEY_LENGTHS_STRUCT declaration.
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-08-18 08:08:41 +09:00
Jacek Caban
4c917e9532 rsaenh: Implement duplicate_hash_impl for bcrypt-based hashes.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-06 18:50:48 +02:00
Hans Leidekker
fd8f32aa8e bcrypt/tests: Add BcryptEncrypt/Decrypt tests.
Signed-off-by: Bruno Jesus <00cpxxx@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-12-06 18:58:36 +01:00
Hans Leidekker
63852e6ac4 bcrypt/tests: Add BCryptGenerateSymmetricKey tests.
Signed-off-by: Bruno Jesus <00cpxxx@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-12-06 18:58:33 +01:00
Hans Leidekker
9fcdc5ec75 bcrypt/tests: Add AES provider tests.
Signed-off-by: Bruno Jesus <00cpxxx@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-12-06 18:58:22 +01:00
Hans Leidekker
6415947e09 bcrypt: Add support for BCRYPT_RNG_ALGORITHM.
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-05 00:06:41 +09:00
Patrick Armstrong
408251948e bcrypt: Added BCryptHash function.
Signed-off-by: Patrick Armstrong <pat@oldpatricka.com>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-24 20:03:51 +09:00
Patrick Armstrong
630f5e97b1 bcrypt: Implement support for HMAC.
Signed-off-by: Patrick Armstrong <pat@oldpatricka.com>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-11 20:24:14 +09:00
Patrick Armstrong
8bd3e4cc2e bcrypt: Implement MD5 algorithm and add tests.
Signed-off-by: Patrick Armstrong <pat@oldpatricka.com>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-08 21:28:58 +09:00
Hans Leidekker
5c1a92e1cf include: Add missing BCrypt declarations.
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-01-06 18:08:33 +01:00
Marcus Meissner
5b33f18cfc bcrypt: Add BCryptCreateHash stub.
Signed-off-By: Marcus Meissner <marcus@jet.franken.de>
2015-10-01 16:27:42 +09:00
André Hentschel
574b30b685 bcrypt: Add stub for BCryptGetProperty. 2014-10-22 21:00:27 +09:00
Bruno Jesus
52aca431e4 bcrypt: Add BCryptGenRandom stub. 2014-02-05 19:34:16 +01:00
David Hedberg
66db40e891 crypt32: Add BCryptEnumAlgorithms stub. 2011-05-30 17:55:43 +02:00
Francois Gouget
5fcce569ce bcrypt: Add a skeleton bcrypt.h header and use it. 2007-08-31 12:08:58 +02:00