Package org.vafer.jdeb.signing
Class PGPSigner
java.lang.Object
org.vafer.jdeb.signing.PGPSigner
Signing with OpenPGP.
-
Constructor Summary
ConstructorsConstructorDescriptionPGPSigner(InputStream keyring, String keyId, String passphrase, int digest) -
Method Summary
Modifier and TypeMethodDescriptionvoidclearSign(InputStream input, OutputStream output)Creates a clear sign signature over the input data.voidclearSign(String input, OutputStream output)Creates a clear sign signature over the input data.org.bouncycastle.openpgp.PGPPrivateKeyReturns the private key.org.bouncycastle.openpgp.PGPSecretKeyReturns the secret key.
-
Constructor Details
-
PGPSigner
public PGPSigner(InputStream keyring, String keyId, String passphrase, int digest) throws IOException, org.bouncycastle.openpgp.PGPException- Throws:
IOExceptionorg.bouncycastle.openpgp.PGPException
-
-
Method Details
-
clearSign
public void clearSign(String input, OutputStream output) throws IOException, org.bouncycastle.openpgp.PGPException, GeneralSecurityExceptionCreates a clear sign signature over the input data. (Not detached)- Parameters:
input- the content to be signedoutput- the output destination of the signature- Throws:
IOExceptionorg.bouncycastle.openpgp.PGPExceptionGeneralSecurityException
-
clearSign
public void clearSign(InputStream input, OutputStream output) throws IOException, org.bouncycastle.openpgp.PGPException, GeneralSecurityExceptionCreates a clear sign signature over the input data. (Not detached)- Parameters:
input- the content to be signedoutput- the output destination of the signature- Throws:
IOExceptionorg.bouncycastle.openpgp.PGPExceptionGeneralSecurityException
-
getSecretKey
Returns the secret key. -
getPrivateKey
Returns the private key.
-