Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 24 for enableTls (0.03 sec)

  1. okhttp/src/jvmTest/kotlin/okhttp3/ConnectionListenerTest.kt

          "ConnectStart",
          "ConnectEnd",
          "ConnectionAcquired",
          "ConnectionReleased",
        )
      }
    
      @Test
      @Throws(IOException::class)
      fun secondCallEventSequence() {
        enableTls()
        server.protocols = listOf(Protocol.HTTP_2, Protocol.HTTP_1_1)
        server.enqueue(MockResponse())
        server.enqueue(MockResponse())
    
        client
          .newCall(Request(server.url("/")))
          .execute()
    Registered: Fri Dec 26 11:42:13 UTC 2025
    - Last Modified: Tue Nov 04 18:33:48 UTC 2025
    - 9.7K bytes
    - Viewed (0)
  2. android-test/src/androidTest/java/okhttp/android/test/OkHttpTest.kt

        assertEquals(TlsVersion.TLS_1_3, response.handshake?.tlsVersion)
        assertEquals(Protocol.HTTP_2, response.protocol)
      }
    
      @Test
      fun testMockWebserverRequest() {
        enableTls()
    
        server.enqueue(MockResponse(body = "abc"))
    
        val request = Request.Builder().url(server.url("/")).build()
    
        val response = client.newCall(request).execute()
    
        response.use {
    Registered: Fri Dec 26 11:42:13 UTC 2025
    - Last Modified: Tue Nov 04 19:13:52 UTC 2025
    - 29.9K bytes
    - Viewed (0)
  3. okhttp/src/jvmTest/kotlin/okhttp3/internal/http/HttpUpgradesTest.kt

        executeAndCheckUpgrade(
          upgradeRequest()
            .newBuilder()
            .post("Hello".toRequestBody())
            .build(),
        )
      }
    
      @Test
      fun upgradeHttps() {
        enableTls(Protocol.HTTP_1_1)
        upgrade()
      }
    
      @Test
      fun upgradeRefusedByServer() {
        server.enqueue(MockResponse(body = "normal request"))
        val requestWithUpgrade =
          Request
            .Builder()
    Registered: Fri Dec 26 11:42:13 UTC 2025
    - Last Modified: Tue Nov 04 19:13:52 UTC 2025
    - 9.6K bytes
    - Viewed (0)
  4. okhttp/src/jvmTest/kotlin/okhttp3/SessionReuseTest.kt

        if (tlsVersion == TlsVersion.TLS_1_3.javaName) {
          assumeTrue(PlatformVersion.majorVersion != 8)
        }
    
        val sessionIds = mutableListOf<String>()
    
        enableTls()
    
        val tlsVersion = TlsVersion.forJavaName(tlsVersion)
        val spec =
          ConnectionSpec
            .Builder(ConnectionSpec.MODERN_TLS)
            .tlsVersions(tlsVersion)
            .build()
    
    Registered: Fri Dec 26 11:42:13 UTC 2025
    - Last Modified: Sat Nov 01 12:18:11 UTC 2025
    - 5.9K bytes
    - Viewed (1)
  5. okhttp/src/jvmTest/kotlin/okhttp3/TrailersTest.kt

      private fun enableProtocol(protocol: Protocol) {
        if (protocol == Protocol.HTTP_2) {
          enableTls()
          client =
            client
              .newBuilder()
              .protocols(listOf(protocol, Protocol.HTTP_1_1))
              .build()
          server.protocols = client.protocols
        }
      }
    
      private fun enableTls() {
        val handshakeCertificates = platform.localhostHandshakeCertificates()
        client =
    Registered: Fri Dec 26 11:42:13 UTC 2025
    - Last Modified: Sat Nov 08 21:45:04 UTC 2025
    - 18.8K bytes
    - Viewed (0)
  6. okhttp/src/jvmTest/kotlin/okhttp3/CallTest.kt

      }
    
      @Test
      fun tls() {
        enableTls()
        server.enqueue(
          MockResponse(
            headers = headersOf("Content-Type", "text/plain"),
            body = "abc",
          ),
        )
        executeSynchronously("/").assertHandshake()
      }
    
      @Test
      fun tls_Async() {
        enableTls()
        server.enqueue(
          MockResponse(
    Registered: Fri Dec 26 11:42:13 UTC 2025
    - Last Modified: Tue Nov 04 19:13:52 UTC 2025
    - 147.4K bytes
    - Viewed (0)
  7. okhttp/src/jvmTest/kotlin/okhttp3/ServerTruncatesRequestTest.kt

        }
      }
    
      private fun enableProtocol(protocol: Protocol) {
        enableTls()
        client =
          client
            .newBuilder()
            .protocols(listOf(protocol, Protocol.HTTP_1_1))
            .build()
        server.protocols = client.protocols
      }
    
      private fun enableTls() {
        client =
          client
            .newBuilder()
            .sslSocketFactory(
    Registered: Fri Dec 26 11:42:13 UTC 2025
    - Last Modified: Tue Nov 04 19:13:52 UTC 2025
    - 10.4K bytes
    - Viewed (0)
  8. okhttp/src/jvmTest/kotlin/okhttp3/RouteFailureTest.kt

          .assertCode(200)
      }
    
      private fun enableProtocol(protocol: Protocol) {
        enableTls()
        client =
          client
            .newBuilder()
            .protocols(listOf(protocol, Protocol.HTTP_1_1))
            .build()
        server1.protocols = client.protocols
        server2.protocols = client.protocols
      }
    
      private fun enableTls() {
        client =
          client
            .newBuilder()
            .sslSocketFactory(
    Registered: Fri Dec 26 11:42:13 UTC 2025
    - Last Modified: Tue Nov 04 19:13:52 UTC 2025
    - 11.6K bytes
    - Viewed (0)
  9. okhttp/src/jvmTest/kotlin/okhttp3/DuplexTest.kt

       */
      private fun enableProtocol(protocol: Protocol) {
        enableTls()
        client =
          client
            .newBuilder()
            .protocols(listOf(protocol, Protocol.HTTP_1_1))
            .build()
        server.protocols = client.protocols
      }
    
      private fun enableTls() {
        client =
          client
            .newBuilder()
            .sslSocketFactory(
    Registered: Fri Dec 26 11:42:13 UTC 2025
    - Last Modified: Tue Nov 04 19:13:52 UTC 2025
    - 25.8K bytes
    - Viewed (0)
  10. okhttp-brotli/README.md

    OkHttp Brotli Implementation
    ============================
    
    This module is an implementation of [Brotli][1] compression.
    It enables Brotli support in addition to tranparent Gzip support,
    provided Accept-Encoding is not set previously.  Modern web servers
    must choose to return Brotli responses.  n.b. It is not used for
    sending requests.
    
    ```java
    OkHttpClient client = new OkHttpClient.Builder()
      .addInterceptor(BrotliInterceptor.INSTANCE)
      .build();
    Registered: Fri Dec 26 11:42:13 UTC 2025
    - Last Modified: Thu Oct 30 21:39:59 UTC 2025
    - 571 bytes
    - Viewed (0)
Back to top