All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.bouncycastle.openpgp.operator.PGPContentSignerBuilderProvider Maven / Gradle / Ivy

Go to download

The Bouncy Castle Java API for handling the OpenPGP protocol. This jar contains the OpenPGP API for JDK 1.4. The APIs can be used in conjunction with a JCE/JCA provider such as the one provided with the Bouncy Castle Cryptography APIs.

The newest version!
package org.bouncycastle.openpgp.operator;

import org.bouncycastle.openpgp.PGPPublicKey;

/**
 * Provider class for {@link PGPContentSignerBuilder} instances.
 * Concrete implementations of this class can choose the cryptographic backend (BC, JCA/JCE).
 */
public abstract class PGPContentSignerBuilderProvider
{
    protected final int hashAlgorithmId;

    /**
     * Constructor.
     *
     * @param hashAlgorithmId ID of the hash algorithm the {@link PGPContentSignerBuilder} shall use.
     */
    public PGPContentSignerBuilderProvider(int hashAlgorithmId)
    {
        this.hashAlgorithmId = hashAlgorithmId;
    }

    /**
     * Return a new instance of the {@link PGPContentSignerBuilder} for the given signing key.
     *
     * @param signingKey public part of the signing key
     * @return content signer builder
     */
    public abstract PGPContentSignerBuilder get(PGPPublicKey signingKey);
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy