Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 26 for certificatePinner (0.14 sec)

  1. samples/guide/src/main/java/okhttp3/recipes/kt/CertificatePinning.kt

     * limitations under the License.
     */
    package okhttp3.recipes.kt
    
    import java.io.IOException
    import okhttp3.CertificatePinner
    import okhttp3.OkHttpClient
    import okhttp3.Request
    
    class CertificatePinning {
      private val client =
        OkHttpClient.Builder()
          .certificatePinner(
            CertificatePinner.Builder()
              .add("publicobject.com", "sha256/Vjs8r4z+80wjNcr1YKepWQboSIRi63WsWXhIMN+eWys=")
              .build(),
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 1.4K bytes
    - Viewed (0)
  2. samples/guide/src/main/java/okhttp3/recipes/CertificatePinning.java

    import java.io.IOException;
    import java.security.cert.Certificate;
    import okhttp3.CertificatePinner;
    import okhttp3.OkHttpClient;
    import okhttp3.Request;
    import okhttp3.Response;
    
    public final class CertificatePinning {
      private final OkHttpClient client = new OkHttpClient.Builder()
          .certificatePinner(
              new CertificatePinner.Builder()
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sun Dec 08 21:30:01 UTC 2019
    - 1.7K bytes
    - Viewed (0)
  3. docs/changelogs/upgrading_to_okhttp_4.md

    #### Vars and Vals
    
    Java doesn’t have language support for properties so developers make do with getters and setters.
    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
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sun Feb 06 16:58:16 UTC 2022
    - 10.9K bytes
    - Viewed (0)
  4. okhttp/src/test/java/okhttp3/OkHttpClientTest.kt

        }
      }
    
      @Test fun certificatePinnerEquality() {
        val clientA = clientTestRule.newClient()
        val clientB = clientTestRule.newClient()
        assertThat(clientB.certificatePinner).isEqualTo(clientA.certificatePinner)
      }
    
      @Test fun nullInterceptorInList() {
        val builder = OkHttpClient.Builder()
        builder.interceptors().addAll(listOf(null) as List<Interceptor>)
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sun Mar 31 17:16:15 UTC 2024
    - 13.2K bytes
    - Viewed (0)
  5. docs/features/https.md

              for (certificate in response.handshake!!.peerCertificates) {
                println(CertificatePinner.pin(certificate))
              }
            }
          }
        ```
    === ":material-language-java: Java"
        ```java
          private final OkHttpClient client = new OkHttpClient.Builder()
              .certificatePinner(
                  new CertificatePinner.Builder()
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sat Dec 24 00:16:30 UTC 2022
    - 10.5K bytes
    - Viewed (0)
  6. okhttp/src/test/java/okhttp3/KotlinDeprecationErrorTest.kt

        val proxy: Proxy? = address.proxy()
        val sslSocketFactory: SSLSocketFactory? = address.sslSocketFactory()
        val hostnameVerifier: HostnameVerifier? = address.hostnameVerifier()
        val certificatePinner: CertificatePinner? = address.certificatePinner()
      }
    
      @Test @Disabled
      fun cache() {
        val cache = Cache(File("/cache/"), Integer.MAX_VALUE.toLong())
        val directory: File = cache.directory()
      }
    
      @Test @Disabled
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 13.3K bytes
    - Viewed (0)
  7. okhttp/src/test/java/okhttp3/ConnectionCoalescingTest.kt

      /** Can still coalesce when pinning is used if pins match.  */
      @Test
      fun coalescesWhenCertificatePinsMatch() {
        val pinner =
          CertificatePinner.Builder()
            .add("san.com", pin(certificate.certificate))
            .build()
        client = client.newBuilder().certificatePinner(pinner).build()
        server.enqueue(MockResponse())
        server.enqueue(MockResponse())
        assert200Http2Response(execute(url), server.hostName)
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sat Jan 20 10:30:28 UTC 2024
    - 18.7K bytes
    - Viewed (0)
  8. okhttp-tls/src/main/kotlin/okhttp3/tls/HandshakeCertificates.kt

    import javax.net.ssl.SSLContext
    import javax.net.ssl.SSLSocketFactory
    import javax.net.ssl.TrustManager
    import javax.net.ssl.X509KeyManager
    import javax.net.ssl.X509TrustManager
    import okhttp3.CertificatePinner
    import okhttp3.internal.platform.Platform
    import okhttp3.internal.toImmutableList
    import okhttp3.tls.internal.TlsUtil.newKeyManager
    import okhttp3.tls.internal.TlsUtil.newTrustManager
    
    /**
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 8.5K bytes
    - Viewed (0)
  9. okhttp/api/okhttp.api

    }
    
    public final class okhttp3/CertificatePinner$Builder {
    	public fun <init> ()V
    	public final fun add (Ljava/lang/String;[Ljava/lang/String;)Lokhttp3/CertificatePinner$Builder;
    	public final fun build ()Lokhttp3/CertificatePinner;
    	public final fun getPins ()Ljava/util/List;
    }
    
    public final class okhttp3/CertificatePinner$Companion {
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Apr 15 13:41:01 UTC 2024
    - 70.2K bytes
    - Viewed (0)
  10. okhttp-testing-support/src/main/kotlin/okhttp3/TestValueFactory.kt

        return Address(
          uriHost = uriHost,
          uriPort = uriPort,
          dns = dns,
          socketFactory = SocketFactory.getDefault(),
          sslSocketFactory = null,
          hostnameVerifier = null,
          certificatePinner = null,
          proxyAuthenticator = proxyAuthenticator,
          proxy = proxy,
          protocols = protocols,
          connectionSpecs = connectionSpecs,
          proxySelector = proxySelector,
        )
      }
    
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sat Apr 20 17:03:43 UTC 2024
    - 7.7K bytes
    - Viewed (0)
Back to top