Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 6 of 6 for certificateKey (0.15 sec)

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

         * [certificatePem()][certificatePem] and [privateKeyPkcs8Pem()][privateKeyPkcs8Pem].
         *
         * [rfc_7468]: https://tools.ietf.org/html/rfc7468
         * [rfc_5208]: https://tools.ietf.org/html/rfc5208
         */
        @JvmStatic
        fun decode(certificateAndPrivateKeyPem: String): HeldCertificate {
          var certificatePem: String? = null
          var pkcs8Base64: String? = null
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 21.6K bytes
    - Viewed (0)
  2. okhttp-tls/src/test/java/okhttp3/tls/HeldCertificateTest.kt

          |lu/GJQZoU9lDrCPeUcQ28tzOW6AKBggqhkjOPQMBBw==
          |-----END PRIVATE KEY-----
          |
          """.trimMargin()
        val heldCertificate = decode(certificatePem + pkcs8Pem)
        assertThat(heldCertificate.certificatePem()).isEqualTo(certificatePem)
    
        // Slightly different encoding
        if (platform.isBouncyCastle()) {
          assertThat(heldCertificate.privateKeyPkcs8Pem()).isEqualTo(bcPkcs8Pem)
        } else {
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 22.5K bytes
    - Viewed (0)
  3. okhttp-tls/src/test/java/okhttp3/tls/internal/der/DerCertificatesTest.kt

          |
          """.trimMargin()
        val certificateByteString = certificateBase64.decodeBase64()!!
        val certificatePem =
          """
          |-----BEGIN CERTIFICATE-----
          |$certificateBase64
          |-----END CERTIFICATE-----
          |
          """.trimMargin()
    
        val javaCertificate = certificatePem.decodeCertificatePem()
        val okHttpCertificate =
          CertificateAdapters.certificate
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 43.9K bytes
    - Viewed (0)
  4. okhttp/src/test/java/okhttp3/internal/tls/HostnameVerifierTest.kt

        val heldCertificate =
          HeldCertificate.Builder()
            .commonName("Foo Corp")
            .addSubjectAlternativeName("foo.com")
            .build()
        val session = session(heldCertificate.certificatePem())
        assertThat(verifier.verify("foo.com", session)).isTrue()
        assertThat(verifier.verify("bar.com", session)).isFalse()
      }
    
      @Test fun specialKInHostname() {
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 40.3K bytes
    - Viewed (0)
  5. okhttp/src/test/java/okhttp3/KotlinSourceModernTest.kt

        val heldCertificate: HeldCertificate = HeldCertificate.Builder().build()
        val certificate: X509Certificate = heldCertificate.certificate
        val keyPair: KeyPair = heldCertificate.keyPair
        val certificatePem: String = heldCertificate.certificatePem()
        val privateKeyPkcs8Pem: String = heldCertificate.privateKeyPkcs8Pem()
        val privateKeyPkcs1Pem: String = heldCertificate.privateKeyPkcs1Pem()
      }
    
      @Test
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Apr 01 14:21:25 UTC 2024
    - 46.5K bytes
    - Viewed (0)
  6. docs/changelogs/changelog_4x.md

            .build()
        val server = MockWebServer()
        server.useHttps(handshakeCertificates.sslSocketFactory(), false)
        ```
    
        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.
    
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Wed Apr 17 13:25:31 UTC 2024
    - 25.2K bytes
    - Viewed (0)
Back to top