@@ -2381,6 +2381,12 @@ msgid ""
23812381"the appropriate stdlib API. (Contributed by Christian Heimes in "
23822382":issue:`19689`.)"
23832383msgstr ""
2384+ "新增的函数 :func:`~ssl.create_default_context` 提供了获取 :class:`~ssl.SSLContext` "
2385+ "的标准方式,其设置旨在合理兼顾兼容性和安全性。 这些设置比 :class:`~ssl.SSLContext` "
2386+ "构造器所提供的默认设置更为严格,如果最佳实践的安全要求发生变化,将来可能会对其进行调整,而不预先提示弃用。 对于使用支持 SSL 的 stdlib "
2387+ "库来新推荐的最佳实践是使用 :func:`~ssl.create_default_context` 来获取 "
2388+ ":class:`~ssl.SSLContext` 对象,必要时对其进行修改,然后将其作为相应 stdlib API 的 *contex* 参数传入。 "
2389+ "(由 Christian Heimes 在 :issue:`19689` 中贡献。)"
23842390
23852391#: ../../whatsnew/3.4.rst:1441
23862392msgid ""
@@ -2390,6 +2396,9 @@ msgid ""
23902396"certificates directly via strings or bytes, respectively. (Contributed by "
23912397"Christian Heimes in :issue:`18138`.)"
23922398msgstr ""
2399+ ":class:`~ssl.SSLContext` 方法 :meth:`~ssl.SSLContext.load_verify_locations` "
2400+ "接受新增的可选参数 *cadata*,它可被来分别通过字符串或字节串来直接提供 PEM 或 DER 编码的证书。 (由 Christian Heimes"
2401+ " 在 :issue:`18138` 中贡献。)"
23932402
23942403#: ../../whatsnew/3.4.rst:1446
23952404msgid ""
@@ -2400,6 +2409,10 @@ msgid ""
24002409"debugging default verification issues. (Contributed by Christian Heimes in "
24012410":issue:`18143`.)"
24022411msgstr ""
2412+ "新增的函数 :func:`~ssl.get_default_verify_paths` 可返回一个由路径和环境变量组成的具名元组, 供 "
2413+ ":meth:`~ssl.SSLContext.set_default_verify_paths` 方法用来设置 OpenSSL 的默认 "
2414+ "``cafile`` 和``capath``。 这有助于对默认的验证问题进行调试。 (由 Christian Heimes 在 "
2415+ ":issue:`18143` 中贡献。)"
24032416
24042417#: ../../whatsnew/3.4.rst:1453
24052418msgid ""
0 commit comments