-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Closed
Labels
api-approvedAPI was approved in API review, it can be implementedAPI was approved in API review, it can be implementedarea-System.Securityhelp wanted[up-for-grabs] Good issue for external contributors[up-for-grabs] Good issue for external contributors
Milestone
Description
We should add members on the ChainPolicy to allow a single call to X509Chain.Build to consider an X509Certificate2Collection of certs as a replacement of the system/user default certificate trust.
Win32: CERT_CHAIN_ENGINE_CONFIG looks like it has hExclusiveRoot for "replace".
Unix/OpenSSL: We just need to replace the root trust list when deciding whether or not to set the UnknownRoot flag.
Apple/Security.framework: The SecTrust APIs have options to replace the anchors list for a single request.
API requirements:
- A way of providing the replacement root certificate trust collection, with a clear mode of if the request is using system trust or custom trust.
(edited to remove the option of "in addition to" the system trust due to increased complexity and less OS support)
namespace System.Security.Cryptography.X509Certificates
{
public enum X509ChainTrustMode
{
System,
CustomRootTrust,
}
public partial class X509ChainPolicy
{
public X509ChainTrustMode TrustMode { get; set; }
public X509Certificate2Collection CustomTrustStore { get; }
}
}vcsjones, weber-software, ShutterQuick and Jamtastic808
Metadata
Metadata
Assignees
Labels
api-approvedAPI was approved in API review, it can be implementedAPI was approved in API review, it can be implementedarea-System.Securityhelp wanted[up-for-grabs] Good issue for external contributors[up-for-grabs] Good issue for external contributors