mirror of
https://github.com/pgpainless/pgpainless.git
synced 2024-11-23 04:42:06 +01:00
Rename method to set'Key'ExpirationDateInSubpacketGenerator()
This commit is contained in:
parent
d9ef55e22f
commit
2ac10e7bc7
3 changed files with 5 additions and 5 deletions
|
@ -138,7 +138,7 @@ public class KeyRingBuilder implements KeyRingBuilderInterface<KeyRingBuilder> {
|
||||||
PGPSignatureSubpacketGenerator hashedSubPacketGenerator = primaryKeySpec.getSubpacketGenerator();
|
PGPSignatureSubpacketGenerator hashedSubPacketGenerator = primaryKeySpec.getSubpacketGenerator();
|
||||||
hashedSubPacketGenerator.setPrimaryUserID(false, true);
|
hashedSubPacketGenerator.setPrimaryUserID(false, true);
|
||||||
if (expirationDate != null) {
|
if (expirationDate != null) {
|
||||||
SignatureSubpacketGeneratorUtil.setExpirationDateInSubpacketGenerator(
|
SignatureSubpacketGeneratorUtil.setKeyExpirationDateInSubpacketGenerator(
|
||||||
expirationDate, new Date(), hashedSubPacketGenerator);
|
expirationDate, new Date(), hashedSubPacketGenerator);
|
||||||
}
|
}
|
||||||
PGPSignatureSubpacketVector hashedSubPackets = hashedSubPacketGenerator.generate();
|
PGPSignatureSubpacketVector hashedSubPackets = hashedSubPacketGenerator.generate();
|
||||||
|
|
|
@ -377,7 +377,7 @@ public class SecretKeyRingEditor implements SecretKeyRingEditorInterface {
|
||||||
PGPSignatureSubpacketVector oldSubpackets = oldSignature.getHashedSubPackets();
|
PGPSignatureSubpacketVector oldSubpackets = oldSignature.getHashedSubPackets();
|
||||||
PGPSignatureSubpacketGenerator subpacketGenerator = new PGPSignatureSubpacketGenerator(oldSubpackets);
|
PGPSignatureSubpacketGenerator subpacketGenerator = new PGPSignatureSubpacketGenerator(oldSubpackets);
|
||||||
SignatureSubpacketGeneratorUtil.setSignatureCreationTimeInSubpacketGenerator(new Date(), subpacketGenerator);
|
SignatureSubpacketGeneratorUtil.setSignatureCreationTimeInSubpacketGenerator(new Date(), subpacketGenerator);
|
||||||
SignatureSubpacketGeneratorUtil.setExpirationDateInSubpacketGenerator(expiration, subjectPubKey.getCreationTime(), subpacketGenerator);
|
SignatureSubpacketGeneratorUtil.setKeyExpirationDateInSubpacketGenerator(expiration, subjectPubKey.getCreationTime(), subpacketGenerator);
|
||||||
|
|
||||||
PGPSignatureGenerator signatureGenerator = SignatureUtils.getSignatureGeneratorFor(primaryKey);
|
PGPSignatureGenerator signatureGenerator = SignatureUtils.getSignatureGeneratorFor(primaryKey);
|
||||||
signatureGenerator.setHashedSubpackets(subpacketGenerator.generate());
|
signatureGenerator.setHashedSubpackets(subpacketGenerator.generate());
|
||||||
|
|
|
@ -88,7 +88,7 @@ public final class SignatureSubpacketGeneratorUtil {
|
||||||
* @param creationDate date on which the key was created
|
* @param creationDate date on which the key was created
|
||||||
* @param subpacketGenerator subpacket generator
|
* @param subpacketGenerator subpacket generator
|
||||||
*/
|
*/
|
||||||
public static void setExpirationDateInSubpacketGenerator(Date expirationDate,
|
public static void setKeyExpirationDateInSubpacketGenerator(Date expirationDate,
|
||||||
@Nonnull Date creationDate,
|
@Nonnull Date creationDate,
|
||||||
PGPSignatureSubpacketGenerator subpacketGenerator) {
|
PGPSignatureSubpacketGenerator subpacketGenerator) {
|
||||||
removeAllPacketsOfType(SignatureSubpacketTags.KEY_EXPIRE_TIME, subpacketGenerator);
|
removeAllPacketsOfType(SignatureSubpacketTags.KEY_EXPIRE_TIME, subpacketGenerator);
|
||||||
|
|
Loading…
Reference in a new issue