(self, ctx)
| 1689 | self.assertEqual(ctx.cert_store_stats(), stats) |
| 1690 | |
| 1691 | def _assert_context_options(self, ctx): |
| 1692 | self.assertEqual(ctx.options & ssl.OP_NO_SSLv2, ssl.OP_NO_SSLv2) |
| 1693 | if OP_NO_COMPRESSION != 0: |
| 1694 | self.assertEqual(ctx.options & OP_NO_COMPRESSION, |
| 1695 | OP_NO_COMPRESSION) |
| 1696 | if OP_SINGLE_DH_USE != 0: |
| 1697 | self.assertEqual(ctx.options & OP_SINGLE_DH_USE, |
| 1698 | OP_SINGLE_DH_USE) |
| 1699 | if OP_SINGLE_ECDH_USE != 0: |
| 1700 | self.assertEqual(ctx.options & OP_SINGLE_ECDH_USE, |
| 1701 | OP_SINGLE_ECDH_USE) |
| 1702 | if OP_CIPHER_SERVER_PREFERENCE != 0: |
| 1703 | self.assertEqual(ctx.options & OP_CIPHER_SERVER_PREFERENCE, |
| 1704 | OP_CIPHER_SERVER_PREFERENCE) |
| 1705 | self.assertEqual(ctx.options & ssl.OP_LEGACY_SERVER_CONNECT, |
| 1706 | 0 if IS_OPENSSL_3_0_0 else ssl.OP_LEGACY_SERVER_CONNECT) |
| 1707 | |
| 1708 | def test_create_default_context(self): |
| 1709 | ctx = ssl.create_default_context() |
no test coverage detected