Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 40 for socketFactory (0.16 sec)

  1. samples/tlssurvey/src/main/kotlin/okhttp3/survey/Clients.kt

        ianaSuites = ianaSuites,
      )
    }
    
    fun systemDefault(
      name: String,
      version: String,
      ianaSuites: IanaSuites,
    ): 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) },
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Tue Apr 02 01:44:15 UTC 2024
    - 2.5K bytes
    - Viewed (0)
  2. docs/changelogs/upgrading_to_okhttp_4.md

    Kotlin does have properties and we take advantage of them in OkHttp.
    
     * **Address**: certificatePinner, connectionSpecs, dns, hostnameVerifier, protocols, proxy,
       proxyAuthenticator, proxySelector, socketFactory, sslSocketFactory, url
     * **Cache**: directory
     * **CacheControl**: immutable, maxAgeSeconds, maxStaleSeconds, minFreshSeconds, mustRevalidate,
       noCache, noStore, noTransform, onlyIfCached, sMaxAgeSeconds
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sun Feb 06 16:58:16 UTC 2022
    - 10.9K bytes
    - Viewed (0)
  3. okhttp-testing-support/src/main/kotlin/okhttp3/TestValueFactory.kt

        proxy: Proxy? = null,
        proxySelector: ProxySelector = this.proxySelector,
      ): Address {
        return Address(
          uriHost = uriHost,
          uriPort = uriPort,
          dns = dns,
          socketFactory = SocketFactory.getDefault(),
          sslSocketFactory = null,
          hostnameVerifier = null,
          certificatePinner = null,
          proxyAuthenticator = proxyAuthenticator,
          proxy = proxy,
          protocols = protocols,
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sat Apr 20 17:03:43 UTC 2024
    - 7.7K bytes
    - Viewed (0)
  4. okhttp/src/test/java/okhttp3/KotlinDeprecationErrorTest.kt

        factory.close()
      }
    
      @Test @Disabled
      fun address() {
        val address: Address = factory.newAddress()
        val url: HttpUrl = address.url()
        val dns: Dns = address.dns()
        val socketFactory: SocketFactory = address.socketFactory()
        val proxyAuthenticator: Authenticator = address.proxyAuthenticator()
        val protocols: List<Protocol> = address.protocols()
        val connectionSpecs: List<ConnectionSpec> = address.connectionSpecs()
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 13.3K bytes
    - Viewed (0)
  5. okhttp/src/test/java/okhttp3/ChannelSocketFactory.kt

     * limitations under the License.
     */
    package okhttp3
    
    import java.net.InetAddress
    import java.net.Socket
    import java.nio.channels.SocketChannel
    import javax.net.SocketFactory
    
    class ChannelSocketFactory : SocketFactory() {
      override fun createSocket(): Socket {
        return SocketChannel.open().socket()
      }
    
      override fun createSocket(
        host: String,
        port: Int,
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 1.4K bytes
    - Viewed (0)
  6. okhttp/src/test/java/okhttp3/internal/http/CancelTest.kt

          server.useHttps(handshakeCertificates.sslSocketFactory())
        }
        server.start()
    
        client =
          clientTestRule.newClientBuilder()
            .socketFactory(
              object : DelegatingSocketFactory(SocketFactory.getDefault()) {
                @Throws(IOException::class)
                override fun configureSocket(socket: Socket): Socket {
                  socket.sendBufferSize = SOCKET_BUFFER_SIZE
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sat Jan 20 10:30:28 UTC 2024
    - 9.9K bytes
    - Viewed (0)
  7. okhttp-tls/src/test/java/okhttp3/tls/HandshakeCertificatesTest.kt

    import java.security.PrivateKey
    import java.util.concurrent.ExecutorService
    import java.util.concurrent.Executors
    import java.util.concurrent.Future
    import javax.net.ServerSocketFactory
    import javax.net.SocketFactory
    import javax.net.ssl.SSLSocket
    import okhttp3.Handshake
    import okhttp3.Handshake.Companion.handshake
    import okhttp3.TestUtil.threadFactory
    import okhttp3.internal.closeQuietly
    import okhttp3.testing.PlatformRule
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Thu Apr 11 22:09:35 UTC 2024
    - 7.1K bytes
    - Viewed (0)
  8. container-tests/src/test/java/okhttp3/containers/BasicProxyTest.kt

      @Test
      fun testUrlConnectionSecureDirect() {
        val keyStoreFactory = KeyStoreFactory(Configuration.configuration(), MockServerLogger())
        HttpsURLConnection.setDefaultSSLSocketFactory(keyStoreFactory.sslContext().socketFactory)
    
        testRequest {
          val url = URI(mockServer.secureEndpoint + "/person?name=peter").toURL()
    
          val connection = url.openConnection() as HttpURLConnection
    
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Fri Apr 05 03:30:42 UTC 2024
    - 5.9K bytes
    - Viewed (0)
  9. okhttp-android/src/androidTest/kotlin/okhttp3/android/AndroidAsyncDnsTest.kt

        val client =
          OkHttpClient.Builder()
            .dns(AsyncDns.toDns(AndroidAsyncDns.IPv4, AndroidAsyncDns.IPv6))
            .socketFactory(network.socketFactory)
            .build()
    
        val call =
          client.newCall(Request("https://google.com/robots.txt".toHttpUrl()))
    
        call.execute().use { response ->
          assertThat(response.code).isEqualTo(200)
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 5.7K bytes
    - Viewed (0)
  10. okhttp/src/test/java/okhttp3/internal/tls/CertificatePinnerChainValidationTest.kt

            .signedBy(compromisedIntermediateCa)
            .commonName(server.hostName)
            .build()
        val socketFactory =
          newServerSocketFactory(
            rogueCertificate,
            compromisedIntermediateCa.certificate,
            goodCertificate.certificate,
          )
        server.useHttps(socketFactory)
        server.enqueue(
          MockResponse.Builder()
            .body("abc")
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 23.8K bytes
    - Viewed (0)
Back to top