Jim Fulton added the comment:

SSL is used for more than just HTTP.  The are applications in which clients 
have server public keys that they use to authenticate servers rather than using 
certificate authorities.  For these applications, server host names are 
irrelevant.  This is why it makes sense to have an option on the SSL context to 
disable host name checking.  Removing this ability would break some 
applications.

If the option to check host names is provided as false on the SSL context, it 
makes no sense to check whether the host name, which isn't going to be used, is 
not None.  It's just silly, but not a huge deal one way or the other, because 
there are actually *two* ways to disable host name checking; you can also pass 
'' as the hostname, which is why this isn't a big deal and why I haven't gotten 
around to making a PR yet.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27391>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to