Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 50 for SSLSocket (0.12 sec)

  1. okhttp/src/androidMain/kotlin/okhttp3/internal/platform/android/DeferredSocketAdapter.kt

      override fun matchesSocket(sslSocket: SSLSocket): Boolean = socketAdapterFactory.matchesSocket(sslSocket)
    
      override fun configureTlsExtensions(
        sslSocket: SSLSocket,
        hostname: String?,
        protocols: List<Protocol>,
      ) {
        getDelegate(sslSocket)?.configureTlsExtensions(sslSocket, hostname, protocols)
      }
    
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed Mar 19 19:25:20 UTC 2025
    - 2.1K bytes
    - Viewed (0)
  2. okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/connection/ConnectPlan.kt

      private fun connectTls(
        sslSocket: SSLSocket,
        connectionSpec: ConnectionSpec,
      ) {
        val address = route.address
        var success = false
        try {
          if (connectionSpec.supportsTlsExtensions) {
            Platform.get().configureTlsExtensions(sslSocket, address.url.host, address.protocols)
          }
    
          // Force handshake. This can throw!
          sslSocket.startHandshake()
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Thu Jul 31 04:18:40 UTC 2025
    - 18.6K bytes
    - Viewed (0)
  3. mockwebserver/src/test/java/mockwebserver3/internal/http2/Http2Server.kt

      }
    
      private fun doSsl(socket: Socket): SSLSocket {
        val sslSocket =
          sslSocketFactory.createSocket(
            socket,
            socket.inetAddress.hostAddress,
            socket.port,
            true,
          ) as SSLSocket
        sslSocket.useClientMode = false
        Platform.get().configureTlsExtensions(sslSocket, null, listOf(Protocol.HTTP_2))
        sslSocket.startHandshake()
        return sslSocket
      }
    
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Thu Jul 31 04:18:40 UTC 2025
    - 6.4K bytes
    - Viewed (0)
  4. mockwebserver/src/main/kotlin/mockwebserver3/internal/MockWebServerSocket.kt

      val scheme: String
        get() =
          when (javaNetSocket) {
            is SSLSocket -> "https"
            else -> "http"
          }
    
      val handshake: Handshake?
        get() = (javaNetSocket as? SSLSocket)?.session?.handshake()
    
      val handshakeServerNames: List<String>
        get() =
          (javaNetSocket as? SSLSocket)
            ?.let { Platform.Companion.get().getHandshakeServerNames(it) }
            ?: listOf()
    
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Thu Jul 31 04:18:40 UTC 2025
    - 3.3K bytes
    - Viewed (0)
  5. okhttp/src/androidMain/kotlin/okhttp3/internal/platform/android/AndroidSocketAdapter.kt

      override fun matchesSocket(sslSocket: SSLSocket): Boolean = sslSocketClass.isInstance(sslSocket)
    
      override fun configureTlsExtensions(
        sslSocket: SSLSocket,
        hostname: String?,
        protocols: List<Protocol>,
      ) {
        // No TLS extensions if the socket class is custom.
        if (matchesSocket(sslSocket)) {
          try {
            // Enable session tickets.
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed Mar 19 19:25:20 UTC 2025
    - 4.6K bytes
    - Viewed (0)
  6. okhttp/src/jvmMain/kotlin/okhttp3/internal/platform/ConscryptPlatform.kt

        }
      }
    
      override fun getSelectedProtocol(sslSocket: SSLSocket): String? =
        if (Conscrypt.isConscrypt(sslSocket)) {
          Conscrypt.getApplicationProtocol(sslSocket)
        } else {
          super.getSelectedProtocol(sslSocket)
        }
    
      override fun newSslSocketFactory(trustManager: X509TrustManager): SSLSocketFactory =
        newSSLContext()
          .apply {
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed Mar 19 19:25:20 UTC 2025
    - 4.6K bytes
    - Viewed (0)
  7. okhttp/src/androidMain/kotlin/okhttp3/internal/platform/android/Android10SocketAdapter.kt

    @SuppressSignatureCheck
    class Android10SocketAdapter : SocketAdapter {
      override fun matchesSocket(sslSocket: SSLSocket): Boolean = SSLSockets.isSupportedSocket(sslSocket)
    
      override fun isSupported(): Boolean = Companion.isSupported()
    
      @SuppressLint("NewApi")
      override fun getSelectedProtocol(sslSocket: SSLSocket): String? =
        try {
          // SSLSocket.getApplicationProtocol returns "" if application protocols values will not
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed Mar 19 19:25:20 UTC 2025
    - 2.8K bytes
    - Viewed (0)
  8. okhttp/src/jvmMain/kotlin/okhttp3/internal/platform/Jdk8WithJettyBootPlatform.kt

            )
          putMethod.invoke(null, sslSocket, alpnProvider)
        } catch (e: InvocationTargetException) {
          throw AssertionError("failed to set ALPN", e)
        } catch (e: IllegalAccessException) {
          throw AssertionError("failed to set ALPN", e)
        }
      }
    
      override fun afterHandshake(sslSocket: SSLSocket) {
        try {
          removeMethod.invoke(null, sslSocket)
        } catch (e: IllegalAccessException) {
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed Mar 19 19:25:20 UTC 2025
    - 6.1K bytes
    - Viewed (0)
  9. okhttp-tls/src/test/java/okhttp3/tls/HandshakeCertificatesTest.kt

            val sslSocket =
              server.sslSocketFactory().createSocket(
                rawSocket,
                rawSocket.inetAddress.hostAddress,
                rawSocket.port,
                true,
              ) as SSLSocket
            sslSocket.use {
              sslSocket.useClientMode = false
              sslSocket.wantClientAuth = true
              sslSocket.startHandshake()
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed Mar 19 19:25:20 UTC 2025
    - 7.2K bytes
    - Viewed (0)
  10. okhttp/src/jvmMain/kotlin/okhttp3/internal/platform/BouncyCastlePlatform.kt

        }
      }
    
      override fun getSelectedProtocol(sslSocket: SSLSocket): String? =
        if (sslSocket is BCSSLSocket) {
          when (val protocol = (sslSocket as BCSSLSocket).applicationProtocol) {
            // Handles both un-configured and none selected.
            null, "" -> null
            else -> protocol
          }
        } else {
          super.getSelectedProtocol(sslSocket)
        }
    
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Fri Dec 27 13:39:56 UTC 2024
    - 3.3K bytes
    - Viewed (0)
Back to top