Class JcaPKCS10CertificationRequest

    • Constructor Detail

      • JcaPKCS10CertificationRequest

        public JcaPKCS10CertificationRequest​(org.bouncycastle.asn1.pkcs.CertificationRequest certificationRequest)
        Wrap a parsed CertificationRequest.
        Parameters:
        certificationRequest - the underlying request.
      • JcaPKCS10CertificationRequest

        public JcaPKCS10CertificationRequest​(byte[] encoding)
                                      throws java.io.IOException
        Parse a BER/DER encoded PKCS#10 request.
        Parameters:
        encoding - the encoded request bytes.
        Throws:
        java.io.IOException - if the data is not a valid CertificationRequest.
    • Method Detail

      • setProvider

        public JcaPKCS10CertificationRequest setProvider​(java.lang.String providerName)
        Pin KeyFactory lookups to the named JCE provider.
        Parameters:
        providerName - name of the registered provider.
        Returns:
        this holder.
      • setProvider

        public JcaPKCS10CertificationRequest setProvider​(java.security.Provider provider)
        Pin KeyFactory lookups to the supplied JCE provider.
        Parameters:
        provider - the provider instance.
        Returns:
        this holder.
      • getPublicKey

        public java.security.PublicKey getPublicKey()
                                             throws java.security.InvalidKeyException,
                                                    java.security.NoSuchAlgorithmException
        Return the public key carried by the request as a JCA PublicKey.
        Returns:
        the decoded public key.
        Throws:
        java.security.InvalidKeyException - if the SubjectPublicKeyInfo cannot be parsed.
        java.security.NoSuchAlgorithmException - if no matching KeyFactory can be located.