现在希望通过 Python 来验证磁盘上的 private key / certificate 文件的有效性,但是看了文档之后发现貌似 SSLContext 只在 Python 3 里存在:
http://docs.python.org/3/library/ssl.html#ssl-contexts
在 Python 2 里是没有的:
http://docs.python.org/2/library/ssl.html
那么要在 Python 2.7 里做这件事情的话,有什么简便可靠的方式么?
http://docs.python.org/3/library/ssl.html#ssl-contexts
在 Python 2 里是没有的:
http://docs.python.org/2/library/ssl.html
那么要在 Python 2.7 里做这件事情的话,有什么简便可靠的方式么?