Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for SubjectPublicKeyInfo (0.3 sec)

  1. okhttp-tls/src/main/kotlin/okhttp3/tls/internal/der/CertificateAdapters.kt

          rdnSequence,
        )
    
      /**
       * ```
       * SubjectPublicKeyInfo ::= SEQUENCE  {
       *   algorithm            AlgorithmIdentifier,
       *   subjectPublicKey     BIT STRING
       * }
       * ```
       */
      internal val subjectPublicKeyInfo: BasicDerAdapter<SubjectPublicKeyInfo> =
        Adapters.sequence(
          "SubjectPublicKeyInfo",
          algorithmIdentifier,
          Adapters.BIT_STRING,
          decompose = {
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 13.6K bytes
    - Viewed (0)
  2. okhttp-tls/src/test/java/okhttp3/tls/internal/der/DerCertificatesTest.kt

                  ),
              ),
          ),
        )
      }
    
      /** Converts public key bytes to SubjectPublicKeyInfo bytes. */
      private fun encodeKey(
        algorithm: String,
        publicKeyBytes: ByteString,
      ): ByteString {
        val subjectPublicKeyInfo =
          SubjectPublicKeyInfo(
            algorithm = AlgorithmIdentifier(algorithm = algorithm, parameters = null),
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 43.9K bytes
    - Viewed (0)
  3. okhttp-tls/src/main/kotlin/okhttp3/tls/HeldCertificate.kt

            keySize = 2048
          }
    
        fun build(): HeldCertificate {
          // Subject keys & identity.
          val subjectKeyPair = keyPair ?: generateKeyPair()
          val subjectPublicKeyInfo =
            CertificateAdapters.subjectPublicKeyInfo.fromDer(
              subjectKeyPair.public.encoded.toByteString(),
            )
          val subject: List<List<AttributeTypeAndValue>> = subject()
    
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 21.6K bytes
    - Viewed (0)
  4. okhttp-tls/src/test/java/okhttp3/tls/internal/der/DerTest.kt

      @Test fun `large object inside small object`() {
        val bytes = "301b300d06092a864886f70d010101050003847fffffff000504030201".decodeHex()
        assertFailsWith<ProtocolException> {
          CertificateAdapters.subjectPublicKeyInfo.fromDer(bytes)
        }.also { expected ->
          assertThat(expected.message).isEqualTo("enclosed object too large")
        }
      }
    
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 31.7K bytes
    - Viewed (0)
Back to top