Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 81 for Certificates (0.29 sec)

  1. okhttp-tls/src/main/kotlin/okhttp3/tls/Certificates.kt

        throw IllegalArgumentException("failed to decode certificate", nsee)
      } catch (iae: IllegalArgumentException) {
        throw IllegalArgumentException("failed to decode certificate", iae)
      } catch (e: GeneralSecurityException) {
        throw IllegalArgumentException("failed to decode certificate", e)
      }
    }
    
    /**
     * Returns the certificate encoded in [PEM format][rfc_7468].
     *
     * [rfc_7468]: https://tools.ietf.org/html/rfc7468
     */
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 2.8K bytes
    - Viewed (2)
  2. okhttp-tls/src/main/kotlin/okhttp3/tls/internal/der/Certificate.kt

        val data = CertificateAdapters.certificate.toDer(this)
        try {
          val certificateFactory = CertificateFactory.getInstance("X.509")
          val certificates = certificateFactory.generateCertificates(Buffer().write(data).inputStream())
          return certificates.single() as X509Certificate
        } catch (e: NoSuchElementException) {
          throw IllegalArgumentException("failed to decode certificate", e)
        } catch (e: IllegalArgumentException) {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 6.4K bytes
    - Viewed (0)
  3. docs/changelogs/changelog_4x.md

        ```
    
        Get these strings with `HeldCertificate.certificatePem()` and `privateKeyPkcs8Pem()`.
    
     *  Fix: Handshake now returns peer certificates in canonical order: each certificate is signed by
        the certificate that follows and the last certificate is signed by a trusted root.
    
     *  Fix: Don't lose HTTP/2 flow control bytes when incoming data races with a stream close. If this
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 17 13:25:31 GMT 2024
    - 25.2K bytes
    - Viewed (0)
  4. okhttp-tls/src/test/java/okhttp3/tls/HeldCertificateTest.kt

        val certificate = heldCertificate.certificate
        assertThat(certificate.getSubjectX500Principal().name, "self-signed")
          .isEqualTo(certificate.getIssuerX500Principal().name)
        assertThat(certificate.getIssuerX500Principal().name).matches(Regex("CN=[0-9a-f-]{36}"))
        assertThat(certificate.serialNumber).isEqualTo(BigInteger.ONE)
        assertThat(certificate.subjectAlternativeNames).isNull()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 22.5K bytes
    - Viewed (0)
  5. okhttp/src/main/kotlin/okhttp3/CertificatePinner.kt

     * `api.publicobject.com` are valid if either A's or B's certificate is in the chain.
     *
     * ## Warning: Certificate Pinning is Dangerous!
     *
     * Pinning certificates limits your server team's abilities to update their TLS certificates. By
     * pinning certificates, you take on additional operational complexity and limit your ability to
     * migrate between certificate authorities. Do not use certificate pinning without the blessing of
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 14.2K bytes
    - Viewed (1)
  6. okhttp-tls/src/main/kotlin/okhttp3/tls/HeldCertificate.kt

         * certificate can sign other certificates (but those certificates cannot themselves sign
         * certificates). Set this to 1 so this certificate can sign intermediate certificates that can
         * themselves sign certificates. Add one for each additional layer of intermediates to permit.
         */
        fun certificateAuthority(maxIntermediateCas: Int) =
          apply {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 21.6K bytes
    - Viewed (1)
  7. samples/guide/src/main/java/okhttp3/recipes/CustomTrust.java

            .addTrustedCertificate(comodoRsaCertificationAuthority)
            // Uncomment if standard certificates are also required.
            //.addPlatformTrustedCertificates()
            .build();
    
        client = new OkHttpClient.Builder()
                .sslSocketFactory(certificates.sslSocketFactory(), certificates.trustManager())
                .build();
      }
    
      public void run() throws Exception {
    Java
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Thu Aug 12 07:26:27 GMT 2021
    - 9.3K bytes
    - Viewed (2)
  8. okhttp-tls/src/test/java/okhttp3/tls/CertificatesJavaTest.java

          + "jaA9VEhgdaVhxBsT2qzUNDsXlOzGsliznDfoqETb\n"
          + "-----END CERTIFICATE-----\n";
    
        X509Certificate certificate =
            Certificates.decodeCertificatePem(certificateString);
    
        assertEquals(certificateString, Certificates.certificatePem(certificate));
      }
    Java
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Fri Nov 20 02:23:18 GMT 2020
    - 1.8K bytes
    - Viewed (0)
  9. okhttp/src/test/java/okhttp3/CertificateChainCleanerTest.kt

        assertThat(cleaner.clean(certificates, "hostname")).isEqualTo(certificates)
        assertThat(cleaner.clean(certificates.subList(0, 9), "hostname")).isEqualTo(
          certificates,
        )
      }
    
      @Test
      fun chainTooLong() {
        val heldCertificates = chainOfLength(11)
        val certificates: MutableList<Certificate> = ArrayList()
        for (heldCertificate in heldCertificates) {
          certificates.add(heldCertificate.certificate)
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 9.3K bytes
    - Viewed (0)
  10. okhttp/src/main/kotlin/okhttp3/internal/platform/android/AndroidCertificateChainCleaner.kt

      @Throws(SSLPeerUnverifiedException::class)
      @SuppressSignatureCheck
      override fun clean(
        chain: List<Certificate>,
        hostname: String,
      ): List<Certificate> {
        val certificates = (chain as List<X509Certificate>).toTypedArray()
        try {
          return x509TrustManagerExtensions.checkServerTrusted(certificates, "RSA", hostname)
        } catch (ce: CertificateException) {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 2.7K bytes
    - Viewed (0)
Back to top