Lines Matching full:certificate
36 # The custom key and certificate files used in test_ssl are generated
185 # provided solely for this test, to exercise the certificate
377 """Check that trying to use the given client certificate fails"""
392 """Wrapping with a badly formatted certificate (syntax error)"""
1212 # Certificate verification is enabled by default
1334 self.assertRaisesRegexp(ssl.SSLError, "certificate verify failed",
1441 self.assertRaisesRegexp(ssl.SSLError, "certificate verify failed",
1458 # contain both versions of each certificate (same content, different
1552 self.fail("No server certificate on %s:%s!" % (host, port))
1562 self.fail("Got server certificate %s for %s:%s!" % (pem, host, port))
1566 self.fail("No server certificate on %s:%s!" % (host, port))
1568 sys.stdout.write("\nVerified certificate for %s:%s is\n%s\n" % (host, port ,pem))
1592 # certificate.
1596 # sha256.tbs-internet.com needs SNI to use the correct certificate
1613 sys.stdout.write("Certificate is:\n%s\n" %
1688 # a mismatching protocol version, an invalid certificate,
1787 def __init__(self, certificate=None, ssl_version=None,
1802 if certificate:
1803 self.context.load_cert_chain(certificate)
2113 self.assertTrue(cert, "Can't get peer certificate.")
2119 self.fail("No subject field in certificate: %s." %
2124 "Missing or invalid 'organizationName' field in certificate subject; "
2154 self.assertTrue(cert, "Can't get peer certificate.")
2163 "certificate verify failed"):
2174 self.assertTrue(cert, "Can't get peer certificate.")
2195 self.assertTrue(cert, "Can't get peer certificate.")
2215 """Connecting when the server rejects the client's certificate
2218 connect to it with a wrong client certificate fails.
3047 # The hostname was fetched properly, and the certificate was
3068 # Certificate didn't change
3168 raise support.TestFailed("Can't read certificate file %r" % filename)