diff options
author | Neal H. Walfield <neal@pep.foundation> | 2019-09-06 12:37:17 +0200 |
---|---|---|
committer | Neal H. Walfield <neal@pep.foundation> | 2019-09-17 10:26:25 +0200 |
commit | 0012dc4f4f99d2c4aea94bc63dc64e126cd3a306 (patch) | |
tree | f03dbc911934cb7c1c0035eead4c0b18ed82b4eb /tool | |
parent | f9087297f953ac9e458f1e131769dd0f8d876e74 (diff) |
openpgp: Add a timestamp arg to ComponentBinding::binding_signature
- Change ComponentBinding::binding_signature to take an optional
timestamp and return the self signature that is active at that
time.
Diffstat (limited to 'tool')
-rw-r--r-- | tool/src/commands/decrypt.rs | 2 | ||||
-rw-r--r-- | tool/src/commands/inspect.rs | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/tool/src/commands/decrypt.rs b/tool/src/commands/decrypt.rs index 444f1cbd..48b14e46 100644 --- a/tool/src/commands/decrypt.rs +++ b/tool/src/commands/decrypt.rs @@ -67,7 +67,7 @@ impl<'a> Helper<'a> { for skb in tsk.subkeys() { let key = skb.key(); - if can_encrypt(key, skb.binding_signature()) { + if can_encrypt(key, skb.binding_signature(None)) { let id = key.fingerprint().to_keyid(); keys.insert(id.clone(), key.clone().into()); identities.insert(id.clone(), tsk.fingerprint()); diff --git a/tool/src/commands/inspect.rs b/tool/src/commands/inspect.rs index bb8ed112..95fd07fa 100644 --- a/tool/src/commands/inspect.rs +++ b/tool/src/commands/inspect.rs @@ -139,7 +139,7 @@ fn inspect_tpk(output: &mut io::Write, tpk: &openpgp::TPK, for skb in tpk.subkeys() { writeln!(output, " Subkey: {}", skb.key().fingerprint())?; inspect_revocation(output, "", skb.revoked(None))?; - inspect_key(output, "", skb.key(), skb.binding_signature(), + inspect_key(output, "", skb.key(), skb.binding_signature(None), skb.certifications(), print_keygrips, print_certifications)?; writeln!(output)?; @@ -148,7 +148,7 @@ fn inspect_tpk(output: &mut io::Write, tpk: &openpgp::TPK, for uidb in tpk.userids() { writeln!(output, " UserID: {}", uidb.userid())?; inspect_revocation(output, "", uidb.revoked(None))?; - if let Some(sig) = uidb.binding_signature() { + if let Some(sig) = uidb.binding_signature(None) { if sig.signature_expired() { writeln!(output, " Expired")?; } else if ! sig.signature_alive() { |