Class ThirdPartyCertificationSignatureBuilder

    • Constructor Detail

      • ThirdPartyCertificationSignatureBuilder

        public ThirdPartyCertificationSignatureBuilder​(org.bouncycastle.openpgp.PGPSecretKey signingKey,
                                                       SecretKeyRingProtector protector)
                                                throws org.bouncycastle.openpgp.PGPException
        Create a new certification signature builder. This constructor uses SignatureType.GENERIC_CERTIFICATION as signature type.
        Parameters:
        signingKey - our own certification key
        protector - protector to unlock the certification key
        Throws:
        WrongPassphraseException - in case of a wrong passphrase
        org.bouncycastle.openpgp.PGPException
      • ThirdPartyCertificationSignatureBuilder

        public ThirdPartyCertificationSignatureBuilder​(SignatureType signatureType,
                                                       org.bouncycastle.openpgp.PGPSecretKey signingKey,
                                                       SecretKeyRingProtector protector)
                                                throws org.bouncycastle.openpgp.PGPException
        Create a new certification signature builder.
        Parameters:
        signatureType - type of certification
        signingKey - our own certification key
        protector - protector to unlock the certification key
        Throws:
        WrongPassphraseException - in case of a wrong passphrase
        org.bouncycastle.openpgp.PGPException
      • ThirdPartyCertificationSignatureBuilder

        public ThirdPartyCertificationSignatureBuilder​(org.bouncycastle.openpgp.PGPSecretKey signingKey,
                                                       SecretKeyRingProtector protector,
                                                       org.bouncycastle.openpgp.PGPSignature archetypeSignature)
                                                throws org.bouncycastle.openpgp.PGPException
        Create a new certification signature builder.
        Parameters:
        signingKey - our own certification key
        protector - protector to unlock the certification key
        archetypeSignature - signature to use as a template for the new signature
        Throws:
        WrongPassphraseException - in case of a wrong passphrase
        org.bouncycastle.openpgp.PGPException
    • Method Detail

      • build

        public org.bouncycastle.openpgp.PGPSignature build​(org.bouncycastle.openpgp.PGPPublicKeyRing certifiedKey,
                                                           java.lang.String userId)
                                                    throws org.bouncycastle.openpgp.PGPException
        Create a certification signature for the given user-id and the primary key of the given key ring.
        Parameters:
        certifiedKey - key ring
        userId - user-id to certify
        Returns:
        signature
        Throws:
        org.bouncycastle.openpgp.PGPException - if the signature generator cannot be initialized
      • build

        public org.bouncycastle.openpgp.PGPSignature build​(org.bouncycastle.openpgp.PGPPublicKeyRing certifiedKey,
                                                           org.bouncycastle.openpgp.PGPUserAttributeSubpacketVector userAttribute)
                                                    throws org.bouncycastle.openpgp.PGPException
        Create a certification signature for the given user attribute and the primary key of the given key ring.
        Parameters:
        certifiedKey - key ring
        userAttribute - user-attributes to certify
        Returns:
        signature
        Throws:
        org.bouncycastle.openpgp.PGPException - if the signature generator cannot be initialized