> On 1 Jun 2017, at 11:28, Antoine Pitrou <anto...@python.org> wrote:
> 
> 
> Le 01/06/2017 à 12:23, Cory Benfield a écrit :
>> 
>> No it can’t.
>> 
>> OpenSSL builds chains differently, and disregards some metadata that Windows 
>> and macOS store, which means that cert validation will work differently than 
>> in the system store. This can lead to pip accepting a cert marked as 
>> “untrusted for SSL”, for example, which would be pretty bad.
> 
> Are you claiming that OpenSSL certificate validation is insecure and
> shouldn't be used at all?  I have never heard that claim before.

Of course I’m not.

I am claiming that using OpenSSL certificate validation with root stores that 
are not intended for OpenSSL can be. This is because trust of a certificate is 
non-binary. For example, consider WoSign. The Windows TLS implementation will 
distrust certificates that chain up to WoSign as a root certificate that were 
issued after October 21 2016. This is not something that can currently be 
represented as a PEM file. Therefore, the person exporting the certs needs to 
choose: should that be exported or not? If it is, then OpenSSL will happily 
trust it even in situations where the system trust store would not.

More generally, macOS allows the administrator to configure graduated trust: 
that is, to override whether or not a root should be trusted for certificate 
validation in some circumstances. Again, exporting this to a PEM does not 
persist this information.

Cory

_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to