org.bouncycastle.openpgp

Class PGPSignatureSubpacketGenerator

public class PGPSignatureSubpacketGenerator extends Object

Generator for signature subpackets.
Constructor Summary
PGPSignatureSubpacketGenerator()
Method Summary
PGPSignatureSubpacketVectorgenerate()
voidsetExportable(boolean isCritical, boolean isExportable)
voidsetKeyExpirationTime(boolean isCritical, long seconds)
Set the number of seconds a key is valid for after the time of its creation.
voidsetKeyFlags(boolean isCritical, int flags)
voidsetNotationData(boolean isCritical, boolean isHumanReadable, String notationName, String notationValue)
voidsetPreferredCompressionAlgorithms(boolean isCritical, int[] algorithms)
voidsetPreferredHashAlgorithms(boolean isCritical, int[] algorithms)
voidsetPreferredSymmetricAlgorithms(boolean isCritical, int[] algorithms)
voidsetPrimaryUserID(boolean isCritical, boolean isPrimaryUserID)
voidsetRevocable(boolean isCritical, boolean isRevocable)
voidsetSignatureCreationTime(boolean isCritical, Date date)
Set the creation time for the signature.
voidsetSignatureExpirationTime(boolean isCritical, long seconds)
Set the number of seconds a signature is valid for after the time of its creation.
voidsetSignerUserID(boolean isCritical, String userID)
voidsetTrust(boolean isCritical, int depth, int trustAmount)

Constructor Detail

PGPSignatureSubpacketGenerator

public PGPSignatureSubpacketGenerator()

Method Detail

generate

public PGPSignatureSubpacketVector generate()

setExportable

public void setExportable(boolean isCritical, boolean isExportable)

setKeyExpirationTime

public void setKeyExpirationTime(boolean isCritical, long seconds)
Set the number of seconds a key is valid for after the time of its creation. A value of zero means the key never expires.

Parameters: isCritical true if should be treated as critical, false otherwise. seconds

setKeyFlags

public void setKeyFlags(boolean isCritical, int flags)

setNotationData

public void setNotationData(boolean isCritical, boolean isHumanReadable, String notationName, String notationValue)

setPreferredCompressionAlgorithms

public void setPreferredCompressionAlgorithms(boolean isCritical, int[] algorithms)

setPreferredHashAlgorithms

public void setPreferredHashAlgorithms(boolean isCritical, int[] algorithms)

setPreferredSymmetricAlgorithms

public void setPreferredSymmetricAlgorithms(boolean isCritical, int[] algorithms)

setPrimaryUserID

public void setPrimaryUserID(boolean isCritical, boolean isPrimaryUserID)

setRevocable

public void setRevocable(boolean isCritical, boolean isRevocable)

setSignatureCreationTime

public void setSignatureCreationTime(boolean isCritical, Date date)
Set the creation time for the signature.

Note: this overrides the generation of a creation time when the signature is generated.

setSignatureExpirationTime

public void setSignatureExpirationTime(boolean isCritical, long seconds)
Set the number of seconds a signature is valid for after the time of its creation. A value of zero means the signature never expires.

Parameters: isCritical true if should be treated as critical, false otherwise. seconds

setSignerUserID

public void setSignerUserID(boolean isCritical, String userID)

setTrust

public void setTrust(boolean isCritical, int depth, int trustAmount)