Search Options

Results per page
Sort
Preferred Languages
Advance

Results 31 - 40 of 53 for SSLSocket (0.04 sec)

  1. samples/guide/src/main/java/okhttp3/recipes/CustomCipherSuites.java

          return configureSocket((SSLSocket) delegate.createSocket(
              address, port, localAddress, localPort));
        }
    
        protected SSLSocket configureSocket(SSLSocket socket) throws IOException {
          return socket;
        }
      }
    
      public void run() throws Exception {
        Request request = new Request.Builder()
            .url("https://publicobject.com/helloworld.txt")
            .build();
    
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Thu Mar 14 21:57:42 UTC 2019
    - 6.5K bytes
    - Viewed (0)
  2. okhttp/src/commonJvmAndroid/kotlin/okhttp3/ConnectionSpec.kt

      /** Applies this spec to [sslSocket]. */
      internal fun apply(
        sslSocket: SSLSocket,
        isFallback: Boolean,
      ) {
        val specToApply = supportedSpec(sslSocket, isFallback)
    
        if (specToApply.tlsVersions != null) {
          sslSocket.enabledProtocols = specToApply.tlsVersionsAsString
        }
    
        if (specToApply.cipherSuites != null) {
          sslSocket.enabledCipherSuites = specToApply.cipherSuitesAsString
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Fri Dec 27 13:39:56 UTC 2024
    - 13.4K bytes
    - Viewed (0)
  3. samples/tlssurvey/src/main/kotlin/okhttp3/survey/Clients.kt

    ): Client {
      val socketFactory = SSLSocketFactory.getDefault() as SSLSocketFactory
      val sslSocket = socketFactory.createSocket() as SSLSocket
    
      return Client(
        userAgent = name,
        version = version,
        enabled = sslSocket.enabledCipherSuites.map { ianaSuites.fromJavaName(it) },
        supported = sslSocket.supportedCipherSuites.map { ianaSuites.fromJavaName(it) },
      )
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed Mar 19 19:25:20 UTC 2025
    - 2.4K bytes
    - Viewed (0)
  4. mockwebserver-deprecated/src/main/kotlin/okhttp3/mockwebserver/RecordedRequest.kt

     * limitations under the License.
     */
    package okhttp3.mockwebserver
    
    import java.io.IOException
    import java.net.Inet6Address
    import java.net.Socket
    import javax.net.ssl.SSLSocket
    import okhttp3.Handshake
    import okhttp3.Handshake.Companion.handshake
    import okhttp3.Headers
    import okhttp3.HttpUrl
    import okhttp3.HttpUrl.Companion.toHttpUrlOrNull
    import okhttp3.TlsVersion
    import okio.Buffer
    
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 4.1K bytes
    - Viewed (0)
  5. mockwebserver/src/main/kotlin/mockwebserver3/MockWebServer.kt

                sslSocket.wantClientAuth = true
              }
              openClientSockets.add(sslSocket)
    
              if (protocolNegotiationEnabled) {
                Platform.get().configureTlsExtensions(sslSocket, null, protocols)
              }
    
              sslSocket.startHandshake()
    
              // Wait until after handshake to grab the buffered socket
              socket = MockWebServerSocket(sslSocket)
    
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Sat Aug 02 20:36:00 UTC 2025
    - 40.3K bytes
    - Viewed (0)
  6. okhttp/src/jvmTest/kotlin/okhttp3/SocketChannelTest.kt

                }
    
                val serverSslSocketFactory =
                  object : DelegatingSSLSocketFactory(sslSocketFactory) {
                    override fun configureSocket(sslSocket: SSLSocket): SSLSocket {
                      return sslSocket.apply {
                        sslParameters =
                          sslParameters.apply {
                            sniMatchers =
                              listOf(
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed Jun 18 12:28:21 UTC 2025
    - 8K bytes
    - Viewed (0)
  7. samples/guide/src/main/java/okhttp3/recipes/kt/WiresharkExample.kt

        }
    
        override fun connectionAcquired(
          call: Call,
          connection: Connection,
        ) {
          if (random != null) {
            val sslSocket = connection.socket() as SSLSocket
            val session = sslSocket.session
    
            val masterSecretHex =
              session.masterSecret
                ?.encoded
                ?.toByteString()
                ?.hex()
    
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Sat May 10 11:15:14 UTC 2025
    - 10.9K bytes
    - Viewed (0)
  8. android-test/src/androidTest/java/okhttp/android/test/OkHttpTest.kt

        val trustManager = client.x509TrustManager!!
    
        val delegatingSocketFactory =
          object : DelegatingSSLSocketFactory(sslSocketFactory) {
            override fun configureSocket(sslSocket: SSLSocket): SSLSocket =
              object : DelegatingSSLSocket(sslSocket) {
                override fun getApplicationProtocol(): String = throw UnsupportedOperationException()
              }
          }
    
        client =
          client
            .newBuilder()
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Sat Aug 02 14:12:28 UTC 2025
    - 29K bytes
    - Viewed (0)
  9. okhttp/src/jvmTest/kotlin/okhttp3/internal/platform/Jdk9PlatformTest.kt

     */
    package okhttp3.internal.platform
    
    import assertk.assertThat
    import assertk.assertions.isEqualTo
    import assertk.assertions.isNotNull
    import assertk.assertions.isNull
    import javax.net.ssl.SSLSocket
    import okhttp3.DelegatingSSLSocket
    import okhttp3.internal.platform.Jdk9Platform.Companion.buildIfSupported
    import okhttp3.testing.PlatformRule
    import org.junit.jupiter.api.Test
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed Mar 19 19:25:20 UTC 2025
    - 2K bytes
    - Viewed (0)
  10. okhttp/src/jvmTest/kotlin/okhttp3/ServerTruncatesRequestTest.kt

        val eventListener =
          object : EventListener() {
            var socket: SSLSocket? = null
            var closed = false
    
            override fun connectionAcquired(
              call: Call,
              connection: Connection,
            ) {
              socket = connection.socket() as SSLSocket
            }
    
            override fun requestHeadersStart(call: Call) {
              if (closed) {
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Fri Jun 20 11:46:46 UTC 2025
    - 9.4K bytes
    - Viewed (0)
Back to top