DescriptionAdd support for temporarily trusting a certificate for the duration of unit tests on Windows, rather than requiring the machine to be pre-configured out-of-band.
Given the lack of a Microsoft-provided high-level API to supply application-level trusts to the verification routines, this implements a workaround that intercepts attempts to open the trusted system root store and injects the test certificates directly. This allows the unit tests to work without requiring that the Test CA be added to the machine's Trusted Certificates store.
While doing so, clean up the interface to adding/removing trusted test certificates, so as to support more than one trusted certificate if necessary.
BUG=8470
TEST=To follow
Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=69351
Patch Set 1 #Patch Set 2 : Fix DCHECK_GT() usage on Win #Patch Set 3 : Slight Mac optimization/forgot a conditional #
Total comments: 2
Patch Set 4 : Ensure temporary root certs are searched (and preferred) when building chains on Win #
Total comments: 2
Patch Set 5 : Feedback from phajdan.jr and bulach #
Total comments: 36
Patch Set 6 : Rebase to trunk #Patch Set 7 : bulach and wtc feedback #
Total comments: 25
Patch Set 8 : more feedback #Patch Set 9 : Rebase to trunk with OpenSSL fixes from joth #
Total comments: 1
Patch Set 10 : New Win method & unittests #
Total comments: 29
Patch Set 11 : Feedback #Patch Set 12 : Rebase #Patch Set 13 : Split tests & new certs into new CL #Patch Set 14 : Fix comment typo, remove using operator<<, and update OpenSSL to trunk #Patch Set 15 : Rebase to trunk #Patch Set 16 : Widen suppresions #
Messages
Total messages: 28 (0 generated)
|