- 
                Notifications
    
You must be signed in to change notification settings  - Fork 37
 
Description
Currently, the use of webpki-roots in the Linux verifier is not configurable and they are always loaded to supplement what might come from on-disk CA bundles. This, and the previous behavior of falling back to webpki-roots, was implemented at 1Password because we found openssl-probe to be way too unreliable and had multiple users write in that they were unable to use the app as a result.
However, this is likely not what everyone wants and makes it harder to control exactly what trust roots a consumer of rustls-platform-verifier might allow in addition to some other concerns:
I think webpki-roots should not be included on Linux, since they will inevitably bitrot - @Ralith
But there we're also some solutions presented as well:
I have mixed feelings about a feature, because those can end up silently enabled, which is a bit of a security hazard
maybe support manually adding certs and let people pipe in webpki-roots themselves if they really want to? - @Ralith
The use of webpki-roots can be an optional feature enabled with explicit API - @djc
Out of these, the last idea to enable it with an explicit API seems to be the best balance between convenience, a simple crate API, and control/security. So I believe that is the way we should go.
There are then two things needed to resolve this:
- Make all 
webpki-rootsdependencies optional via an opt-in feature calledwebpki-rootsorwebpki-roots-augment. - Add an API to the top-level crate like this which sets a global atomic and then update 
others.rsto use it on Linux: 
pub fn enable_webpki_fall() {
   ...
}