public class SignatureGenerator extends Object
| Modifier and Type | Field and Description |
|---|---|
protected boolean |
enabled |
protected ChannelWrapper.Key<byte[]> |
headerAndPayloadKey |
protected AbstractHeader.Entry<byte[]> |
headerAndPayloadPGPEntry |
protected ChannelWrapper.Key<byte[]> |
headerOnlyKey |
protected AbstractHeader.Entry<byte[]> |
headerOnlyRSAEntry |
protected org.bouncycastle.openpgp.PGPPrivateKey |
privateKey |
protected static int |
SIGNATURE_SIZE |
| Constructor and Description |
|---|
SignatureGenerator(File privateKeyRingFile,
String privateKeyId,
String privateKeyPassphrase) |
SignatureGenerator(org.bouncycastle.openpgp.PGPPrivateKey privateKey) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
checkEntry(AbstractHeader.Entry<byte[]> entry) |
protected void |
checkKey(ChannelWrapper.Key<byte[]> key) |
protected org.bouncycastle.openpgp.PGPPrivateKey |
extractPrivateKey(org.bouncycastle.openpgp.PGPSecretKey secretKey,
String privateKeyPassphrase) |
protected org.bouncycastle.openpgp.PGPSecretKey |
findMatchingSecretKey(org.bouncycastle.openpgp.PGPSecretKeyRingCollection keyRings,
String privateKeyId) |
void |
finishAfterHeader(WritableChannelWrapper output) |
void |
finishAfterPayload(WritableChannelWrapper output) |
protected void |
finishEntry(WritableChannelWrapper output,
AbstractHeader.Entry<byte[]> entry,
ChannelWrapper.Key<byte[]> key) |
protected int |
getAlgorithm() |
boolean |
isEnabled() |
protected boolean |
isMatchingKeyId(org.bouncycastle.openpgp.PGPSecretKey key,
String privateKeyId) |
void |
prepare(Signature signature) |
protected org.bouncycastle.openpgp.PGPSecretKeyRingCollection |
readKeyRings(File privateKeyRingFile) |
void |
startBeforeHeader(WritableChannelWrapper output) |
protected static final int SIGNATURE_SIZE
protected final boolean enabled
protected AbstractHeader.Entry<byte[]> headerOnlyRSAEntry
protected AbstractHeader.Entry<byte[]> headerAndPayloadPGPEntry
protected final org.bouncycastle.openpgp.PGPPrivateKey privateKey
protected ChannelWrapper.Key<byte[]> headerOnlyKey
protected ChannelWrapper.Key<byte[]> headerAndPayloadKey
public SignatureGenerator(org.bouncycastle.openpgp.PGPPrivateKey privateKey)
public void prepare(Signature signature)
public void startBeforeHeader(WritableChannelWrapper output)
public void finishAfterHeader(WritableChannelWrapper output)
public void finishAfterPayload(WritableChannelWrapper output)
protected org.bouncycastle.openpgp.PGPSecretKeyRingCollection readKeyRings(File privateKeyRingFile)
protected org.bouncycastle.openpgp.PGPSecretKey findMatchingSecretKey(org.bouncycastle.openpgp.PGPSecretKeyRingCollection keyRings,
String privateKeyId)
protected boolean isMatchingKeyId(org.bouncycastle.openpgp.PGPSecretKey key,
String privateKeyId)
protected org.bouncycastle.openpgp.PGPPrivateKey extractPrivateKey(org.bouncycastle.openpgp.PGPSecretKey secretKey,
String privateKeyPassphrase)
protected void finishEntry(WritableChannelWrapper output, AbstractHeader.Entry<byte[]> entry, ChannelWrapper.Key<byte[]> key)
protected void checkEntry(AbstractHeader.Entry<byte[]> entry)
protected void checkKey(ChannelWrapper.Key<byte[]> key)
public boolean isEnabled()
protected int getAlgorithm()
Copyright © 2021. All Rights Reserved.