Hans Leidekker
4237cefb95
crypt32/tests: Add more OCSP response decoding tests.
...
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-01 20:30:57 +02:00
Hans Leidekker
33ff4a6671
crypt32/tests: Use wide character string literals.
...
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-31 12:35:04 +02:00
Hans Leidekker
8516a9e931
crypt32: Use CRT allocation functions.
...
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-30 16:05:29 +02:00
Hans Leidekker
1fb28509f7
crypt32: Consistently use CryptMemAlloc/Free().
...
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-30 16:05:29 +02:00
Hans Leidekker
dd91e541b6
crypt32: Correctly free memory in CNG_ImportRSAPubKey().
...
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-30 16:05:29 +02:00
Hans Leidekker
f04b102484
crypt32: Add partial support for decoding OCSP_BASIC_RESPONSE_INFO structures.
...
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-25 17:56:39 +01:00
Hans Leidekker
0b350ab967
crypt32: Add support for decoding signed OCSP responses.
...
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-15 18:05:27 +01:00
Hans Leidekker
3b90b7be75
crypt32: Add support for decoding OCSP responses.
...
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-10 18:27:43 +01:00
Hans Leidekker
85d2cbbe53
crypt32: Add partial support for encoding signed OCSP requests.
...
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-10 18:27:43 +01:00
Hans Leidekker
6de79d64fa
crypt32: Requestor name is optional in OCSP request.
...
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-10 18:27:43 +01:00
Hans Leidekker
92821ebd49
crypt32: Add support for encoding OCSP requests.
...
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-04 19:13:04 +01:00
Huw Davies
2c9fbf8300
crypt32: Use an unsigned int to avoid a compiler warning on macOS.
...
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-02-28 21:31:56 +01:00
Sven Baars
36378958f7
crypt32/tests: Fix a memory leak (Valgrind).
...
Signed-off-by: Sven Baars <sbaars@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-02-25 19:02:18 +01:00
Eric Pouech
c51ea8566b
crypt32/tests: Enable compilation with long types.
...
Signed-off-by: Eric Pouech <eric.pouech@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-02-23 10:17:26 +01:00
Eric Pouech
5fc99b35ba
crypt32: Enable compilation with long types.
...
Signed-off-by: Eric Pouech <eric.pouech@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-02-09 18:37:32 +01:00
Eric Pouech
bb1fc33570
include/msvcrt: Add attribute((format)) to printf and scanf -like APIs.
...
Fix a bunch of warnings generated by this patch and the migration of
GUID.Data1 to long in ae2693e2c4
Signed-off-by: Eric Pouech <eric.pouech@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-01-31 18:38:55 +01:00
Alexandre Julliard
f0cd33c69e
include: Add support for defining Win32 types as 'long' where possible.
...
Add -DWINE_NO_LONG_TYPES to modules that still have compilation
warnings with long types.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-01-27 20:38:22 +01:00
Eric Pouech
f88507a4fd
crypt32: Use correct integral type.
...
Signed-off-by: Eric Pouech <eric.pouech@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-01-27 11:13:00 +01:00
Fabian Maurer
281836d5b1
crypt32/tests: Avoid "misleading indentation" warnings.
...
Signed-off-by: Fabian Maurer <dark.shadow4@web.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-01-26 21:53:26 +01:00
Paul Gofman
861ae99683
crypt32: Increase maximum object encode length.
...
E. g., DigiCert CRL file is currently 35MB.
Signed-off-by: Paul Gofman <pgofman@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-01-13 17:05:14 +01:00
Alex Henrie
4fd80941f8
crypt32/tests: Make pfxdata static.
...
Signed-off-by: Alex Henrie <alexhenrie24@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-12-23 22:57:01 +01:00
Alexandre Julliard
b714ed411a
crypt32/tests: Mark a failing test as todo.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-12-17 15:05:09 +01:00
Alexandre Julliard
b52c6bfbb1
crypt32: Implement Wow64 entry points in the Unix library.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-12-07 17:54:01 +01:00
Dmitry Timoshkov
8afb89436f
crypt32: Avoid truncating unicode chars.
...
So that strings containing Cyrillic Capital Letter ER (0x420) won't be
quoted when not needed.
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-11-17 20:57:54 +01:00
Alexandre Julliard
41663e6ea5
crypt32: Convert the Unix library to the __wine_unix_call interface.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-10-31 17:09:52 +01:00
Alexandre Julliard
f18ccfef7b
crypt32: Split the import_cert_store function to move memory allocations to the PE side.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-10-31 17:09:52 +01:00
Alexandre Julliard
97479d3d32
ntdll: Move some exception definitions to winternl.h.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-10-07 13:52:42 +02:00
Charles Davis
6eab45621c
crypt32: Use the SecItemExport() function.
...
Signed-off-by: Chip Davis <cdavis@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-09-28 10:03:46 +02:00
Alexandre Julliard
088a787a2c
makefiles: Make -mno-cygwin the default.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-09-20 22:45:48 +02:00
Francois Gouget
dc502ec5d0
crypt32: Make gnutls_(un)?initialize() static.
...
Signed-off-by: Francois Gouget <fgouget@free.fr>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-08-31 15:51:52 +02:00
Aaron Hill
0342de8e4d
crypt32: Add missing 'break' to X509_ECC_SIGNATURE case.
...
This was accidentally removed as part of commit
5edf65616a
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=51501
Signed-off-by: Aaron Hill <aa1ronham@gmail.com>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-07-26 19:42:25 +02:00
Zebediah Figura
bdcddf024f
crypt32: Copy the CRL_INFO structure instead of recalculating it.
...
Steam calls CertGetCertificateChain() on a certificate with a 20 MB CRL, which
can take over 400 ms to parse each time. Avoid parsing it more often than we
need to.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-07-21 22:02:23 +02:00
Zebediah Figura
1c501c6587
crypt32: Rename "crl" and "cloned" to "dst" and "src" in CRL_clone().
...
"cloned" is very ambiguous and can be interpreted as the destination rather than
the source.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-07-21 22:02:20 +02:00
Aaron Hill
5edf65616a
crypt32: Implement CNG_RSA_PUBLIC_KEY_BLOB encoding/decoding.
...
Add support for the OID CNG_RSA_PUBLIC_KEY_BLOB to
CryptEncodeObjectEx and CryptDecodeObjectEx. This OID
decodes to / encodes from memory consisting of a
BCRYPT_RSAKEY_BLOB, followed in memory by the exponent and
modulus in big-endian format.
Signed-off-by: Aaron Hill <aa1ronham@gmail.com>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-07-19 12:17:41 +02:00
Rémi Bernon
8b8b43d5f3
crypt32: Grow item size buffer by more than 1 at a time.
...
When Steam starts and connects, it sometimes does some crypt32
processing and ends up spending a huge amount of time in ntdll memcpy,
reallocating buffers, effectively getting stuck while connecting to the
user account.
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-07-02 16:49:09 +02:00
Piotr Caban
6ac02c0cac
crypt32: Handle CERT_CHAIN_POLICY_IGNORE_NOT_TIME_VALID_FLAG when verifying chain policy.
...
Signed-off-by: Piotr Caban <piotr@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-04-15 18:03:47 +02:00
Piotr Caban
be3f6c87a0
crypt32/tests: Fix tests skipped on all test bot machines.
...
Signed-off-by: Piotr Caban <piotr@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-04-15 18:03:42 +02:00
Piotr Caban
a0dc2adf73
crypt32/tests: Fix tests on systems where google chain root is not trusted.
...
Signed-off-by: Piotr Caban <piotr@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-04-15 18:03:37 +02:00
Dmitry Timoshkov
3038c0cd1a
crypt32/tests: Remove Win9x checks.
...
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-04-14 20:50:15 +02:00
Dmitry Timoshkov
67c8ffc847
crypt32/tests: Link to BCryptDestroyKey directly.
...
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-04-14 20:50:13 +02:00
Dmitry Timoshkov
6bc7a65ef9
crypt32/tests: Link to CryptAcquireContext directly.
...
encode.c tests already do that.
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-04-14 20:50:09 +02:00
Dmitry Timoshkov
8601953ebd
crypt32/tests: Add a test to verify certificate signature.
...
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-04-14 20:50:04 +02:00
Dmitry Timoshkov
9d1ae850df
crypt32: Add support for importing RSA public keys with BCrypt.
...
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=50925
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-04-12 19:34:50 +02:00
Dmitry Timoshkov
c2c7946680
crypt32: Implement CryptImportPublicKeyInfoEx2.
...
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-04-12 19:34:43 +02:00
Piotr Caban
c53d6a4a7c
crypt32: Also import user/admin defined root certificates on macOS.
...
Signed-off-by: Piotr Caban <piotr@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-01-25 21:04:10 +01:00
Francois Gouget
7cd5cc2ecb
crypt32/tests: Fix a registerOIDInfo() failure when missing elevated privileges.
...
Signed-off-by: Francois Gouget <fgouget@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-12-17 10:46:42 +01:00
Dmitry Timoshkov
cd9a510bce
crypt32/tests: Add some tests for CRYPT_KEY_PROV_INFO certificate property.
...
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=50024
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-12-04 21:23:27 +01:00
Dmitry Timoshkov
01d7953189
crypt32: Fix reading and writing CRYPT_KEY_PROV_INFO certificate property.
...
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=50024
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-12-04 21:23:27 +01:00
Dmitry Timoshkov
d3a4477bad
crypt32: Add support for CRYPT_STRING_HEX to CryptBinaryToStringW.
...
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-12-03 20:18:38 +01:00
Paul Gofman
11d09da60f
crypt32: Prevent gnutls from using system priority file.
...
Signed-off-by: Paul Gofman <pgofman@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-11-12 20:22:33 +01:00