@FunctionalInterface
public interface SignatureSubpacketsFunction
PGPSignatureSubpacketGenerator
.
The OpenPGPKeyGenerator
already prepopulates the hashed subpacket areas of signatures during
key generation. This callback is useful to apply custom changes to the hashed subpacket area during the
generation process.Modifier and Type | Method and Description |
---|---|
PGPSignatureSubpacketGenerator |
apply(PGPSignatureSubpacketGenerator subpackets)
Apply some changes to the given
PGPSignatureSubpacketGenerator and return the result. |
PGPSignatureSubpacketGenerator apply(PGPSignatureSubpacketGenerator subpackets)
PGPSignatureSubpacketGenerator
and return the result.
It is also possible to replace the whole PGPSignatureSubpacketGenerator
by returning another instance.
Tipp: In order to replace a subpacket, make sure to prevent duplicates by first removing subpackets
of the same type using PGPSignatureSubpacketGenerator.removePacketsOfType(int)
.
To inspect the current contents of the generator, it is best to call
PGPSignatureSubpacketGenerator.generate()
and in turn inspect its contents using
PGPSignatureSubpacketVector.toArray()
.subpackets
- original subpackets