summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJustus Winter <justus@sequoia-pgp.org>2020-01-21 11:51:47 +0100
committerJustus Winter <justus@sequoia-pgp.org>2020-01-21 12:52:59 +0100
commit4ade8f621302ee094dcd7a5f7d3bbe61fb296940 (patch)
tree10a7560a1838cb1f3be0128713c127bac348192b
parent39d1b90b30a40e1f115baaadff8ff4067960a242 (diff)
openpgp: Make Cert::primary_key_signature_full private.
-rw-r--r--openpgp/src/cert/mod.rs32
1 files changed, 14 insertions, 18 deletions
diff --git a/openpgp/src/cert/mod.rs b/openpgp/src/cert/mod.rs
index 4f3b046e..a2253b56 100644
--- a/openpgp/src/cert/mod.rs
+++ b/openpgp/src/cert/mod.rs
@@ -421,21 +421,7 @@ impl Cert {
/// If the current self-signature is from a User ID binding (and
/// not a direct signature), this also returns the User ID binding
/// and its revocation status as of `t`.
- ///
- /// The primary key's current self-signature as of `t` is, in
- /// order of preference:
- ///
- /// - The binding signature of the primary User ID at time `t`,
- /// if the primary User ID is not revoked at time `t`.
- ///
- /// - The newest, live, direct self signature at time `t`.
- ///
- /// - The binding signature of the primary User ID at time `t`
- /// (this can only happen if there are only revoked User IDs
- /// at time `t`).
- ///
- /// If there are no applicable signatures, `None` is returned.
- pub fn primary_key_signature_full<T>(&self, t: T)
+ fn primary_key_signature_full<T>(&self, t: T)
-> Option<(&Signature, Option<(&UserIDBinding, RevocationStatus)>)>
where T: Into<Option<time::SystemTime>>
{
@@ -472,9 +458,19 @@ impl Cert {
/// Returns the primary key's current self-signature.
///
- /// This function is identical to
- /// `Cert::primary_key_signature_full()`, but it doesn't return the
- /// `UserIDBinding`.
+ /// The primary key's current self-signature as of `t` is, in
+ /// order of preference:
+ ///
+ /// - The binding signature of the primary User ID at time `t`,
+ /// if the primary User ID is not revoked at time `t`.
+ ///
+ /// - The newest, live, direct self signature at time `t`.
+ ///
+ /// - The binding signature of the primary User ID at time `t`
+ /// (this can only happen if there are only revoked User IDs
+ /// at time `t`).
+ ///
+ /// If there are no applicable signatures, `None` is returned.
pub fn primary_key_signature<T>(&self, t: T) -> Option<&Signature>
where T: Into<Option<time::SystemTime>>
{