Home
last modified time | relevance | path

Searched refs:SSLContext (Results 1 – 25 of 151) sorted by relevance

1234567

/external/conscrypt/common/src/test/java/org/conscrypt/javax/net/ssl/
DSSLContextTest.java52 import javax.net.ssl.SSLContext;
75 SSLContext sslContext = SSLContext.getDefault(); in test_SSLContext_getDefault()
88 SSLContext.setDefault(null); in test_SSLContext_setDefault()
94 SSLContext defaultContext = SSLContext.getDefault(); in test_SSLContext_setDefault()
96 SSLContext oldContext = SSLContext.getDefault(); in test_SSLContext_setDefault()
98 SSLContext newContext = SSLContext.getInstance(protocol); in test_SSLContext_setDefault()
101 SSLContext.setDefault(newContext); in test_SSLContext_setDefault()
102 assertSame(newContext, SSLContext.getDefault()); in test_SSLContext_setDefault()
104 SSLContext.setDefault(defaultContext); in test_SSLContext_setDefault()
109 SSLConfigurationAsserts.assertSSLContextDefaultConfiguration(SSLContext.getDefault()); in test_SSLContext_defaultConfiguration()
[all …]
DSSLServerSocketTest.java27 import javax.net.ssl.SSLContext;
47 SSLContext context = SSLContext.getInstance("TLSv1.2"); in testSetEnabledCipherSuitesAffectsGetter_TLS12()
104 SSLContext context = SSLContext.getInstance("TLSv1.3"); in test_SSLSocket_setEnabledCipherSuites_TLS13()
/external/conscrypt/repackaged/common/src/test/java/com/android/org/conscrypt/javax/net/ssl/
DSSLContextTest.java55 import javax.net.ssl.SSLContext;
79 SSLContext sslContext = SSLContext.getDefault(); in test_SSLContext_getDefault()
92 SSLContext.setDefault(null); in test_SSLContext_setDefault()
98 SSLContext defaultContext = SSLContext.getDefault(); in test_SSLContext_setDefault()
100 SSLContext oldContext = SSLContext.getDefault(); in test_SSLContext_setDefault()
102 SSLContext newContext = SSLContext.getInstance(protocol); in test_SSLContext_setDefault()
105 SSLContext.setDefault(newContext); in test_SSLContext_setDefault()
106 assertSame(newContext, SSLContext.getDefault()); in test_SSLContext_setDefault()
108 SSLContext.setDefault(defaultContext); in test_SSLContext_setDefault()
113 SSLConfigurationAsserts.assertSSLContextDefaultConfiguration(SSLContext.getDefault()); in test_SSLContext_defaultConfiguration()
[all …]
DSSLServerSocketTest.java28 import javax.net.ssl.SSLContext;
51 SSLContext context = SSLContext.getInstance("TLSv1.2"); in testSetEnabledCipherSuitesAffectsGetter_TLS12()
108 SSLContext context = SSLContext.getInstance("TLSv1.3"); in test_SSLSocket_setEnabledCipherSuites_TLS13()
/external/conscrypt/benchmark-jmh/src/jmh/java/org/conscrypt/
DOpenJdkEngineFactory.java35 import javax.net.ssl.SSLContext;
55 private final SSLContext clientContext = initClientSslContext(newContext());
56 private final SSLContext serverContext = initServerSslContext(newContext());
74 private SSLContext newContext() { in newContext()
76 return SSLContext.getInstance(OpenJdkEngineFactoryConfig.PROTOCOL); in newContext()
83 private final SSLContext clientContext = newConscryptClientContext();
84 private final SSLContext serverContext = newConscryptServerContext();
104 private SSLContext newContext() { in newContext()
106 return SSLContext.getInstance( in newContext()
114 private final SSLContext clientContext = newConscryptClientContext();
[all …]
DOpenJdkEndpointFactory.java5 import javax.net.ssl.SSLContext;
55 SSLContext clientContext = TestUtils.newClientSslContext(provider); in newJdkFactories()
56 SSLContext serverContext = TestUtils.newServerSslContext(provider); in newJdkFactories()
65 SSLContext clientContext = TestUtils.newClientSslContext(provider); in newConscryptFactories()
66 SSLContext serverContext = TestUtils.newServerSslContext(provider); in newConscryptFactories()
/external/conscrypt/benchmark-android/src/main/java/org/conscrypt/
DAndroidEngineFactory.java19 import javax.net.ssl.SSLContext;
28 private final SSLContext clientContext = newConscryptClientContext();
29 private final SSLContext serverContext = newConscryptServerContext();
55 private final SSLContext clientContext = TestUtils.newClientSslContext(
57 private final SSLContext serverContext = TestUtils.newServerSslContext(
87 private static SSLContext newConscryptClientContext() { in newConscryptClientContext()
91 private static SSLContext newConscryptServerContext() { in newConscryptServerContext()
/external/conscrypt/repackaged/benchmark-android/src/main/java/com/android/org/conscrypt/
DAndroidEngineFactory.java20 import javax.net.ssl.SSLContext;
30 private final SSLContext clientContext = newConscryptClientContext();
31 private final SSLContext serverContext = newConscryptServerContext();
57 private final SSLContext clientContext =
59 private final SSLContext serverContext =
89 private static SSLContext newConscryptClientContext() { in newConscryptClientContext()
93 private static SSLContext newConscryptServerContext() { in newConscryptServerContext()
/external/conscrypt/testing/src/main/java/org/conscrypt/javax/net/ssl/
DSSLConfigurationAsserts.java27 import javax.net.ssl.SSLContext;
48 public static void assertSSLContextDefaultConfiguration(SSLContext sslContext) in assertSSLContextDefaultConfiguration()
78 assertSSLSocketFactoryConfigSameAsSSLContext(sslSocketFactory, SSLContext.getDefault()); in assertSSLSocketFactoryDefaultConfiguration()
86 SSLSocketFactory sslSocketFactory, SSLContext sslContext) throws IOException { in assertSSLSocketFactoryConfigSameAsSSLContext()
106 assertSSLSocketConfigSameAsSSLContext(sslSocket, SSLContext.getDefault()); in assertSSLSocketDefaultConfiguration()
112 SSLSocket sslSocket, SSLContext sslContext) { in assertSSLSocketConfigSameAsSSLContext()
132 sslServerSocketFactory, SSLContext.getDefault()); in assertSSLServerSocketFactoryDefaultConfiguration()
141 SSLServerSocketFactory sslServerSocketFactory, SSLContext sslContext) in assertSSLServerSocketFactoryConfigSameAsSSLContext()
164 assertSSLServerSocketConfigSameAsSSLContext(sslServerSocket, SSLContext.getDefault()); in assertSSLServerSocketDefaultConfiguration()
172 SSLServerSocket sslServerSocket, SSLContext sslContext) { in assertSSLServerSocketConfigSameAsSSLContext()
[all …]
DTestSSLContext.java38 import javax.net.ssl.SSLContext;
81 public final SSLContext clientContext;
82 public final SSLContext serverContext;
174 X509TrustManager serverTrustManager, SSLContext clientContext, in TestSSLContext()
175 SSLContext serverContext, SSLServerSocket serverSocket, InetAddress host, int port) { in TestSSLContext()
211 private SSLContext clientContext;
212 private SSLContext serverContext;
263 public Builder clientContext(SSLContext clientContext) { in clientContext()
268 public Builder serverContext(SSLContext serverContext) { in serverContext()
298 SSLContext clientContext = this.clientContext; in build()
[all …]
/external/conscrypt/repackaged/testing/src/main/java/com/android/org/conscrypt/javax/net/ssl/
DSSLConfigurationAsserts.java28 import javax.net.ssl.SSLContext;
50 public static void assertSSLContextDefaultConfiguration(SSLContext sslContext) in assertSSLContextDefaultConfiguration()
80 assertSSLSocketFactoryConfigSameAsSSLContext(sslSocketFactory, SSLContext.getDefault()); in assertSSLSocketFactoryDefaultConfiguration()
88 SSLSocketFactory sslSocketFactory, SSLContext sslContext) throws IOException { in assertSSLSocketFactoryConfigSameAsSSLContext()
108 assertSSLSocketConfigSameAsSSLContext(sslSocket, SSLContext.getDefault()); in assertSSLSocketDefaultConfiguration()
114 SSLSocket sslSocket, SSLContext sslContext) { in assertSSLSocketConfigSameAsSSLContext()
134 sslServerSocketFactory, SSLContext.getDefault()); in assertSSLServerSocketFactoryDefaultConfiguration()
143 SSLServerSocketFactory sslServerSocketFactory, SSLContext sslContext) in assertSSLServerSocketFactoryConfigSameAsSSLContext()
166 assertSSLServerSocketConfigSameAsSSLContext(sslServerSocket, SSLContext.getDefault()); in assertSSLServerSocketDefaultConfiguration()
174 SSLServerSocket sslServerSocket, SSLContext sslContext) { in assertSSLServerSocketConfigSameAsSSLContext()
[all …]
DTestSSLContext.java39 import javax.net.ssl.SSLContext;
83 public final SSLContext clientContext;
84 public final SSLContext serverContext;
176 X509TrustManager serverTrustManager, SSLContext clientContext, in TestSSLContext()
177 SSLContext serverContext, SSLServerSocket serverSocket, InetAddress host, int port) { in TestSSLContext()
216 private SSLContext clientContext;
217 private SSLContext serverContext;
268 public Builder clientContext(SSLContext clientContext) { in clientContext()
273 public Builder serverContext(SSLContext serverContext) { in serverContext()
303 SSLContext clientContext = this.clientContext; in build()
[all …]
/external/conscrypt/openjdk/src/test/java/org/conscrypt/
DConscryptTest.java31 import javax.net.ssl.SSLContext;
67 SSLContext context = SSLContext.getInstance("TLS"); in testProviderBuilder()
75 context = SSLContext.getInstance("Default"); in testProviderBuilder()
95 SSLContext context = SSLContext.getInstance("TLS"); in testProviderBuilder()
104 context = SSLContext.getInstance("Default"); in testProviderBuilder()
/external/conscrypt/repackaged/openjdk/src/test/java/com/android/org/conscrypt/
DConscryptTest.java32 import javax.net.ssl.SSLContext;
72 SSLContext context = SSLContext.getInstance("TLS"); in testProviderBuilder()
80 context = SSLContext.getInstance("Default"); in testProviderBuilder()
101 SSLContext context = SSLContext.getInstance("TLS"); in testProviderBuilder()
110 context = SSLContext.getInstance("Default"); in testProviderBuilder()
/external/okhttp/mockwebserver/src/main/java/com/squareup/okhttp/internal/
DSslContextBuilder.java31 import javax.net.ssl.SSLContext;
42 private static SSLContext localhost; // Lazily initialized.
45 public static synchronized SSLContext localhost() { in localhost()
90 public SSLContext build() throws GeneralSecurityException { in build()
114 SSLContext sslContext = SSLContext.getInstance("TLS"); in build()
/external/okhttp/samples/static-server/src/main/java/com/squareup/okhttp/sample/
DSampleServer.java17 import javax.net.ssl.SSLContext;
23 private final SSLContext sslContext;
27 public SampleServer(SSLContext sslContext, String root, int port) { in SampleServer()
114 SSLContext sslContext = sslContext(keystoreFile, password); in main()
119 private static SSLContext sslContext(String keystoreFile, String password) in sslContext()
136 SSLContext sslContext = SSLContext.getInstance("TLS"); in sslContext()
/external/okhttp/okhttp-tests/src/test/java/com/squareup/okhttp/internal/tls/
DCertificatePinnerChainValidationTest.java29 import javax.net.ssl.SSLContext;
63 SSLContext clientContext = new SslContextBuilder() in pinRootNotPresentInChain()
71 SSLContext serverSslContext = new SslContextBuilder() in pinRootNotPresentInChain()
118 SSLContext clientContext = new SslContextBuilder() in pinIntermediatePresentInChain()
126 SSLContext serverSslContext = new SslContextBuilder() in pinIntermediatePresentInChain()
177 SSLContext clientContext = new SslContextBuilder() in unrelatedPinnedLeafCertificateInChain()
200 SSLContext serverSslContext = new SslContextBuilder() in unrelatedPinnedLeafCertificateInChain()
249 SSLContext clientContext = new SslContextBuilder() in unrelatedPinnedIntermediateCertificateInChain()
273 SSLContext serverSslContext = new SslContextBuilder() in unrelatedPinnedIntermediateCertificateInChain()
/external/conscrypt/testing/src/main/java/org/conscrypt/
DTestUtils.java53 import javax.net.ssl.SSLContext;
364 static SSLContext newContext(Provider provider) { in newContext()
366 return SSLContext.getInstance("TLS", provider); in newContext()
373 SSLContext jdkContext = in getCommonCipherSuites()
375 SSLContext conscryptContext = TestUtils.initSslContext( in getCommonCipherSuites()
384 private static List<String> supportedCiphers(SSLContext ctx) { in supportedCiphers()
431 static SSLContext newClientSslContext(Provider provider) { in newClientSslContext()
432 SSLContext context = newContext(provider); in newClientSslContext()
436 static SSLContext newServerSslContext(Provider provider) { in newServerSslContext()
437 SSLContext context = newContext(provider); in newServerSslContext()
[all …]
/external/okhttp/samples/guide/src/main/java/com/squareup/okhttp/recipes/
DCustomTrust.java32 import javax.net.ssl.SSLContext;
41 SSLContext sslContext = sslContextForTrustedCertificates(trustedCertificatesInputStream()); in CustomTrust()
159 public SSLContext sslContextForTrustedCertificates(InputStream in) { in sslContextForTrustedCertificates()
183 SSLContext sslContext = SSLContext.getInstance("TLS"); in sslContextForTrustedCertificates()
/external/python/cpython3/Doc/library/
Dssl.rst48 For more sophisticated applications, the :class:`ssl.SSLContext` class
50 by SSL sockets created through the :meth:`SSLContext.wrap_socket` method.
70 :meth:`SSLContext.wrap_socket` of an :class:`SSLContext` instance to wrap
94 context = ssl.SSLContext(ssl.PROTOCOL_TLS_CLIENT)
104 context = ssl.SSLContext(ssl.PROTOCOL_TLS_SERVER)
118 A convenience function helps create :class:`SSLContext` objects for common
123 Return a new :class:`SSLContext` object with default settings for
126 :class:`SSLContext` constructor directly.
130 :meth:`SSLContext.load_verify_locations`. If all three are
137 as *purpose* sets :data:`~SSLContext.verify_mode` to :data:`CERT_REQUIRED`
[all …]
/external/python/cpython2/Lib/test/
Dtest_ssl.py144 ssl.SSLContext(ssl.PROTOCOL_SSLv2)
541 ctx = ssl.SSLContext(ssl.PROTOCOL_SSLv23)
679 ctx = ssl.SSLContext(ssl.PROTOCOL_SSLv23)
755 ssl.SSLContext(protocol)
756 self.assertRaises(TypeError, ssl.SSLContext)
757 self.assertRaises(ValueError, ssl.SSLContext, -1)
758 self.assertRaises(ValueError, ssl.SSLContext, 42)
763 ctx = ssl.SSLContext(proto)
767 ctx = ssl.SSLContext(ssl.PROTOCOL_TLSv1)
775 ctx = ssl.SSLContext(ssl.PROTOCOL_TLSv1)
[all …]
/external/conscrypt/repackaged/testing/src/main/java/com/android/org/conscrypt/
DTestUtils.java57 import javax.net.ssl.SSLContext;
370 static SSLContext newContext(Provider provider) { in newContext()
372 return SSLContext.getInstance("TLS", provider); in newContext()
379 SSLContext jdkContext = in getCommonCipherSuites()
381 SSLContext conscryptContext = TestUtils.initSslContext( in getCommonCipherSuites()
390 private static List<String> supportedCiphers(SSLContext ctx) { in supportedCiphers()
437 static SSLContext newClientSslContext(Provider provider) { in newClientSslContext()
438 SSLContext context = newContext(provider); in newClientSslContext()
442 static SSLContext newServerSslContext(Provider provider) { in newServerSslContext()
443 SSLContext context = newContext(provider); in newServerSslContext()
[all …]
/external/python/cpython3/Lib/test/
Dtest_ssl.py192 ctx = ssl.SSLContext()
227 hasattr(ssl.SSLContext, 'minimum_version'),
252 ctx = ssl.SSLContext(ssl.PROTOCOL_TLS_SERVER)
291 context = ssl.SSLContext(ssl_version)
317 client_context = ssl.SSLContext(ssl.PROTOCOL_TLS_CLIENT)
320 server_context = ssl.SSLContext(ssl.PROTOCOL_TLS_SERVER)
360 ctx = ssl.SSLContext(proto)
855 ctx = ssl.SSLContext(ssl.PROTOCOL_TLS_SERVER)
1004 ctx = ssl.SSLContext(ssl.PROTOCOL_TLS_CLIENT)
1095 ssl.SSLContext(protocol)
[all …]
/external/python/cpython3/Lib/
Dssl.py474 class SSLContext(_SSLContext): class
586 super(SSLContext, SSLContext).minimum_version.__set__(self, value)
594 super(SSLContext, SSLContext).maximum_version.__set__(self, value)
602 super(SSLContext, SSLContext).options.__set__(self, value)
663 super(SSLContext, SSLContext)._msg_callback.__set__(self, None)
696 super(SSLContext, SSLContext)._msg_callback.__set__(self, inner)
708 super(SSLContext, SSLContext).verify_flags.__set__(self, value)
720 super(SSLContext, SSLContext).verify_mode.__set__(self, value)
737 context = SSLContext(PROTOCOL_TLS)
775 context = SSLContext(protocol)
[all …]
/external/grpc-grpc-java/netty/src/main/java/io/grpc/netty/
DJettyTlsUtil.java22 import javax.net.ssl.SSLContext;
41 SSLContext context = SSLContext.getInstance("TLS"); in checkAlpnAvailability()

1234567