[][src]Struct sequoia_openpgp::tpk::ComponentBinding

pub struct ComponentBinding<C> { /* fields omitted */ }

A TPK component binding.

A TPK component is a primary key, a subkey, a user id, or a user attribute. A binding is a TPK component and any related signatures.

Implementations

impl<P, R> ComponentBinding<Key<KeyPart, KeyRole>> where
    P: KeyParts,
    R: KeyRole
[src]

pub fn mark_parts_public(self) -> KeyBinding<PublicParts, R>[src]

Changes the key's parts tag to PublicParts.

pub fn mark_parts_public_ref(&self) -> &KeyBinding<PublicParts, R>[src]

Changes the key's parts tag to PublicParts.

pub fn mark_parts_secret(self) -> KeyBinding<SecretParts, R>[src]

Changes the key's parts tag to SecretParts.

pub fn mark_parts_secret_ref(&self) -> &KeyBinding<SecretParts, R>[src]

Changes the key's parts tag to SecretParts.

pub fn mark_parts_unspecified(self) -> KeyBinding<UnspecifiedParts, R>[src]

Changes the key's parts tag to UnspecifiedParts.

pub fn mark_parts_unspecified_ref(&self) -> &KeyBinding<UnspecifiedParts, R>[src]

Changes the key's parts tag to UnspecifiedParts.

impl<P, R> ComponentBinding<Key<KeyPart, KeyRole>> where
    P: KeyParts,
    R: KeyRole
[src]

pub fn mark_role_primary(self) -> KeyBinding<P, PrimaryRole>[src]

Changes the key's role tag to PrimaryRole.

pub fn mark_role_primary_ref(&self) -> &KeyBinding<P, PrimaryRole>[src]

Changes the key's role tag to PrimaryRole.

pub fn mark_role_secondary(self) -> KeyBinding<P, SubordinateRole>[src]

Changes the key's role tag to SubordinateRole.

pub fn mark_role_secondary_ref(&self) -> &KeyBinding<P, SubordinateRole>[src]

Changes the key's role tag to SubordinateRole.

pub fn mark_role_unspecified(self) -> KeyBinding<P, UnspecifiedRole>[src]

Changes the key's role tag to UnspecifiedRole.

pub fn mark_role_unspecified_ref(&self) -> &KeyBinding<P, UnspecifiedRole>[src]

Changes the key's role tag to UnspecifiedRole.

impl<C> ComponentBinding<C>[src]

pub fn component(&self) -> &C[src]

Returns a reference to the component.

pub fn binding_signature<T>(&self, t: T) -> Option<&Signature> where
    T: Into<Option<Tm>>, 
[src]

Returns the active binding signature at time t.

An active binding signature is a non-revoked, self-signature that is alive at time t (creation time <= t, t <= expiry).

This function returns None if there are no active binding signatures at time t.

pub fn self_signatures(&self) -> &[Signature][src]

The self-signatures.

The signatures are validated, and they are reverse sorted by their creation time (newest first).

pub fn certifications(&self) -> &[Signature][src]

Any third-party certifications.

The signatures are not validated. They are reverse sorted by their creation time (newest first).

pub fn self_revocations(&self) -> &[Signature][src]

Revocations issued by the key itself.

The revocations are validated, and they are reverse sorted by their creation time (newest first).

pub fn other_revocations(&self) -> &[Signature][src]

Revocations issued by other keys.

The revocations are not validated. They are reverse sorted by their creation time (newest first).

impl<P: KeyParts, R: KeyRole> ComponentBinding<Key<P, R>>[src]

pub fn key(&self) -> &Key<P, R>[src]

Returns a reference to the key.

impl<P: KeyParts> ComponentBinding<Key<P, SubordinateRole>>[src]

pub fn revoked<T>(&self, t: T) -> RevocationStatus where
    T: Into<Option<Tm>>, 
[src]

Returns the subkey's revocation status at time t.

A subkey is revoked at time t if:

  • There is a live revocation at time t that is newer than all live self signatures at time t, or

  • There is a hard revocation (even if it is not live at time t, and even if there is a newer self-signature).

Note: TPKs and subkeys have different criteria from User IDs and User Attributes.

Note: this only returns whether this subkey is revoked; it does not imply anything about the TPK or other components.

impl ComponentBinding<UserID>[src]

pub fn userid(&self) -> &UserID[src]

Returns a reference to the User ID.

pub fn revoked<T>(&self, t: T) -> RevocationStatus where
    T: Into<Option<Tm>>, 
[src]

Returns the User ID's revocation status at time t.

A User ID is revoked at time t if:

  • There is a live revocation at time t that is newer than all live self signatures at time t, or

Note: TPKs and subkeys have different criteria from User IDs and User Attributes.

Note: this only returns whether this User ID is revoked; it does not imply anything about the TPK or other components.

impl ComponentBinding<UserAttribute>[src]

pub fn user_attribute(&self) -> &UserAttribute[src]

Returns a reference to the User Attribute.

pub fn revoked<T>(&self, t: T) -> RevocationStatus where
    T: Into<Option<Tm>>, 
[src]

Returns the User Attribute's revocation status at time t.

A User Attribute is revoked at time t if:

  • There is a live revocation at time t that is newer than all live self signatures at time t, or

Note: TPKs and subkeys have different criteria from User IDs and User Attributes.

Note: this only returns whether this User Attribute is revoked; it does not imply anything about the TPK or other components.

impl ComponentBinding<Unknown>[src]

pub fn unknown(&self) -> &Unknown[src]

Returns a reference to the unknown component.

Trait Implementations

impl<C: Clone> Clone for ComponentBinding<C>[src]

impl<C: Debug> Debug for ComponentBinding<C>[src]

impl<'_, '_, P> From<&'_ ComponentBinding<Key<P, PrimaryRole>>> for &'_ KeyBinding<P, SubordinateRole> where
    P: KeyParts
[src]

impl<'_, '_, P> From<&'_ ComponentBinding<Key<P, PrimaryRole>>> for &'_ KeyBinding<P, UnspecifiedRole> where
    P: KeyParts
[src]

impl<'_, '_, P> From<&'_ ComponentBinding<Key<P, SubordinateRole>>> for &'_ KeyBinding<P, PrimaryRole> where
    P: KeyParts
[src]

impl<'_, '_, P> From<&'_ ComponentBinding<Key<P, SubordinateRole>>> for &'_ KeyBinding<P, UnspecifiedRole> where
    P: KeyParts
[src]

impl<'_, '_, P> From<&'_ ComponentBinding<Key<P, UnspecifiedRole>>> for &'_ KeyBinding<P, PrimaryRole> where
    P: KeyParts
[src]

impl<'_, '_, P> From<&'_ ComponentBinding<Key<P, UnspecifiedRole>>> for &'_ KeyBinding<P, SubordinateRole> where
    P: KeyParts
[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<PublicParts, PrimaryRole>>> for &'_ KeyBinding<SecretParts, SubordinateRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<PublicParts, PrimaryRole>>> for &'_ KeyBinding<SecretParts, UnspecifiedRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<PublicParts, PrimaryRole>>> for &'_ KeyBinding<UnspecifiedParts, SubordinateRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<PublicParts, PrimaryRole>>> for &'_ KeyBinding<UnspecifiedParts, UnspecifiedRole>[src]

impl<'_, '_, R> From<&'_ ComponentBinding<Key<PublicParts, R>>> for &'_ KeyBinding<SecretParts, R> where
    R: KeyRole
[src]

impl<'_, '_, R> From<&'_ ComponentBinding<Key<PublicParts, R>>> for &'_ KeyBinding<UnspecifiedParts, R> where
    R: KeyRole
[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<PublicParts, SubordinateRole>>> for &'_ KeyBinding<SecretParts, PrimaryRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<PublicParts, SubordinateRole>>> for &'_ KeyBinding<SecretParts, UnspecifiedRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<PublicParts, SubordinateRole>>> for &'_ KeyBinding<UnspecifiedParts, PrimaryRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<PublicParts, SubordinateRole>>> for &'_ KeyBinding<UnspecifiedParts, UnspecifiedRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<PublicParts, UnspecifiedRole>>> for &'_ KeyBinding<SecretParts, PrimaryRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<PublicParts, UnspecifiedRole>>> for &'_ KeyBinding<SecretParts, SubordinateRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<PublicParts, UnspecifiedRole>>> for &'_ KeyBinding<UnspecifiedParts, PrimaryRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<PublicParts, UnspecifiedRole>>> for &'_ KeyBinding<UnspecifiedParts, SubordinateRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<SecretParts, PrimaryRole>>> for &'_ KeyBinding<PublicParts, SubordinateRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<SecretParts, PrimaryRole>>> for &'_ KeyBinding<PublicParts, UnspecifiedRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<SecretParts, PrimaryRole>>> for &'_ KeyBinding<UnspecifiedParts, SubordinateRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<SecretParts, PrimaryRole>>> for &'_ KeyBinding<UnspecifiedParts, UnspecifiedRole>[src]

impl<'_, '_, R> From<&'_ ComponentBinding<Key<SecretParts, R>>> for &'_ KeyBinding<PublicParts, R> where
    R: KeyRole
[src]

impl<'_, '_, R> From<&'_ ComponentBinding<Key<SecretParts, R>>> for &'_ KeyBinding<UnspecifiedParts, R> where
    R: KeyRole
[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<SecretParts, SubordinateRole>>> for &'_ KeyBinding<PublicParts, PrimaryRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<SecretParts, SubordinateRole>>> for &'_ KeyBinding<PublicParts, UnspecifiedRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<SecretParts, SubordinateRole>>> for &'_ KeyBinding<UnspecifiedParts, PrimaryRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<SecretParts, SubordinateRole>>> for &'_ KeyBinding<UnspecifiedParts, UnspecifiedRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<SecretParts, UnspecifiedRole>>> for &'_ KeyBinding<PublicParts, PrimaryRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<SecretParts, UnspecifiedRole>>> for &'_ KeyBinding<PublicParts, SubordinateRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<SecretParts, UnspecifiedRole>>> for &'_ KeyBinding<UnspecifiedParts, PrimaryRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<SecretParts, UnspecifiedRole>>> for &'_ KeyBinding<UnspecifiedParts, SubordinateRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<UnspecifiedParts, PrimaryRole>>> for &'_ KeyBinding<PublicParts, SubordinateRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<UnspecifiedParts, PrimaryRole>>> for &'_ KeyBinding<PublicParts, UnspecifiedRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<UnspecifiedParts, PrimaryRole>>> for &'_ KeyBinding<SecretParts, SubordinateRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<UnspecifiedParts, PrimaryRole>>> for &'_ KeyBinding<SecretParts, UnspecifiedRole>[src]

impl<'_, '_, R> From<&'_ ComponentBinding<Key<UnspecifiedParts, R>>> for &'_ KeyBinding<PublicParts, R> where
    R: KeyRole
[src]

impl<'_, '_, R> From<&'_ ComponentBinding<Key<UnspecifiedParts, R>>> for &'_ KeyBinding<SecretParts, R> where
    R: KeyRole
[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<UnspecifiedParts, SubordinateRole>>> for &'_ KeyBinding<PublicParts, PrimaryRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<UnspecifiedParts, SubordinateRole>>> for &'_ KeyBinding<PublicParts, UnspecifiedRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<UnspecifiedParts, SubordinateRole>>> for &'_ KeyBinding<SecretParts, PrimaryRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<UnspecifiedParts, SubordinateRole>>> for &'_ KeyBinding<SecretParts, UnspecifiedRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<UnspecifiedParts, UnspecifiedRole>>> for &'_ KeyBinding<PublicParts, PrimaryRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<UnspecifiedParts, UnspecifiedRole>>> for &'_ KeyBinding<PublicParts, SubordinateRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<UnspecifiedParts, UnspecifiedRole>>> for &'_ KeyBinding<SecretParts, PrimaryRole>[src]

impl<'_, '_> From<&'_ ComponentBinding<Key<UnspecifiedParts, UnspecifiedRole>>> for &'_ KeyBinding<SecretParts, SubordinateRole>[src]

impl<P> From<ComponentBinding<Key<P, PrimaryRole>>> for KeyBinding<P, SubordinateRole> where
    P: KeyParts
[src]

impl<P> From<ComponentBinding<Key<P, PrimaryRole>>> for KeyBinding<P, UnspecifiedRole> where
    P: KeyParts
[src]

impl<P> From<ComponentBinding<Key<P, SubordinateRole>>> for KeyBinding<P, PrimaryRole> where
    P: KeyParts
[src]

impl<P> From<ComponentBinding<Key<P, SubordinateRole>>> for KeyBinding<P, UnspecifiedRole> where
    P: KeyParts
[src]

impl<P> From<ComponentBinding<Key<P, UnspecifiedRole>>> for KeyBinding<P, PrimaryRole> where
    P: KeyParts
[src]

impl<P> From<ComponentBinding<Key<P, UnspecifiedRole>>> for KeyBinding<P, SubordinateRole> where
    P: KeyParts
[src]

impl From<ComponentBinding<Key<PublicParts, PrimaryRole>>> for KeyBinding<SecretParts, SubordinateRole>[src]

impl From<ComponentBinding<Key<PublicParts, PrimaryRole>>> for KeyBinding<SecretParts, UnspecifiedRole>[src]

impl From<ComponentBinding<Key<PublicParts, PrimaryRole>>> for KeyBinding<UnspecifiedParts, SubordinateRole>[src]

impl From<ComponentBinding<Key<PublicParts, PrimaryRole>>> for KeyBinding<UnspecifiedParts, UnspecifiedRole>[src]

impl<R> From<ComponentBinding<Key<PublicParts, R>>> for KeyBinding<SecretParts, R> where
    R: KeyRole
[src]

impl<R> From<ComponentBinding<Key<PublicParts, R>>> for KeyBinding<UnspecifiedParts, R> where
    R: KeyRole
[src]

impl From<ComponentBinding<Key<PublicParts, SubordinateRole>>> for KeyBinding<SecretParts, PrimaryRole>[src]

impl From<ComponentBinding<Key<PublicParts, SubordinateRole>>> for KeyBinding<SecretParts, UnspecifiedRole>[src]

impl From<ComponentBinding<Key<PublicParts, SubordinateRole>>> for KeyBinding<UnspecifiedParts, PrimaryRole>[src]

impl From<ComponentBinding<Key<PublicParts, SubordinateRole>>> for KeyBinding<UnspecifiedParts, UnspecifiedRole>[src]

impl From<ComponentBinding<Key<PublicParts, UnspecifiedRole>>> for KeyBinding<SecretParts, PrimaryRole>[src]

impl From<ComponentBinding<Key<PublicParts, UnspecifiedRole>>> for KeyBinding<SecretParts, SubordinateRole>[src]

impl From<ComponentBinding<Key<PublicParts, UnspecifiedRole>>> for KeyBinding<UnspecifiedParts, PrimaryRole>[src]

impl From<ComponentBinding<Key<PublicParts, UnspecifiedRole>>> for KeyBinding<UnspecifiedParts, SubordinateRole>[src]

impl From<ComponentBinding<Key<SecretParts, PrimaryRole>>> for KeyBinding<PublicParts, SubordinateRole>[src]

impl From<ComponentBinding<Key<SecretParts, PrimaryRole>>> for KeyBinding<PublicParts, UnspecifiedRole>[src]

impl From<ComponentBinding<Key<SecretParts, PrimaryRole>>> for KeyBinding<UnspecifiedParts, SubordinateRole>[src]

impl From<ComponentBinding<Key<SecretParts, PrimaryRole>>> for KeyBinding<UnspecifiedParts, UnspecifiedRole>[src]

impl<R> From<ComponentBinding<Key<SecretParts, R>>> for KeyBinding<PublicParts, R> where
    R: KeyRole
[src]

impl<R> From<ComponentBinding<Key<SecretParts, R>>> for KeyBinding<UnspecifiedParts, R> where
    R: KeyRole
[src]

impl From<ComponentBinding<Key<SecretParts, SubordinateRole>>> for KeyBinding<PublicParts, PrimaryRole>[src]

impl From<ComponentBinding<Key<SecretParts, SubordinateRole>>> for KeyBinding<PublicParts, UnspecifiedRole>[src]

impl From<ComponentBinding<Key<SecretParts, SubordinateRole>>> for KeyBinding<UnspecifiedParts, PrimaryRole>[src]

impl From<ComponentBinding<Key<SecretParts, SubordinateRole>>> for KeyBinding<UnspecifiedParts, UnspecifiedRole>[src]

impl From<ComponentBinding<Key<SecretParts, UnspecifiedRole>>> for KeyBinding<PublicParts, PrimaryRole>[src]

impl From<ComponentBinding<Key<SecretParts, UnspecifiedRole>>> for KeyBinding<PublicParts, SubordinateRole>[src]

impl From<ComponentBinding<Key<SecretParts, UnspecifiedRole>>> for KeyBinding<UnspecifiedParts, PrimaryRole>[src]

impl From<ComponentBinding<Key<SecretParts, UnspecifiedRole>>> for KeyBinding<UnspecifiedParts, SubordinateRole>[src]

impl From<ComponentBinding<Key<UnspecifiedParts, PrimaryRole>>> for KeyBinding<PublicParts, SubordinateRole>[src]

impl From<ComponentBinding<Key<UnspecifiedParts, PrimaryRole>>> for KeyBinding<PublicParts, UnspecifiedRole>[src]

impl From<ComponentBinding<Key<UnspecifiedParts, PrimaryRole>>> for KeyBinding<SecretParts, SubordinateRole>[src]

impl From<ComponentBinding<Key<UnspecifiedParts, PrimaryRole>>> for KeyBinding<SecretParts, UnspecifiedRole>[src]

impl<R> From<ComponentBinding<Key<UnspecifiedParts, R>>> for KeyBinding<PublicParts, R> where
    R: KeyRole
[src]

impl<R> From<ComponentBinding<Key<UnspecifiedParts, R>>> for KeyBinding<SecretParts, R> where
    R: KeyRole
[src]

impl From<ComponentBinding<Key<UnspecifiedParts, SubordinateRole>>> for KeyBinding<PublicParts, PrimaryRole>[src]

impl From<ComponentBinding<Key<UnspecifiedParts, SubordinateRole>>> for KeyBinding<PublicParts, UnspecifiedRole>[src]

impl From<ComponentBinding<Key<UnspecifiedParts, SubordinateRole>>> for KeyBinding<SecretParts, PrimaryRole>[src]

impl From<ComponentBinding<Key<UnspecifiedParts, SubordinateRole>>> for KeyBinding<SecretParts, UnspecifiedRole>[src]

impl From<ComponentBinding<Key<UnspecifiedParts, UnspecifiedRole>>> for KeyBinding<PublicParts, PrimaryRole>[src]

impl From<ComponentBinding<Key<UnspecifiedParts, UnspecifiedRole>>> for KeyBinding<PublicParts, SubordinateRole>[src]

impl From<ComponentBinding<Key<UnspecifiedParts, UnspecifiedRole>>> for KeyBinding<SecretParts, PrimaryRole>[src]

impl From<ComponentBinding<Key<UnspecifiedParts, UnspecifiedRole>>> for KeyBinding<SecretParts, SubordinateRole>[src]

impl<C: PartialEq> PartialEq<ComponentBinding<C>> for ComponentBinding<C>[src]

impl<C> StructuralPartialEq for ComponentBinding<C>[src]

Auto Trait Implementations

impl<C> !RefUnwindSafe for ComponentBinding<C>

impl<C> Send for ComponentBinding<C> where
    C: Send

impl<C> Sync for ComponentBinding<C> where
    C: Sync

impl<C> Unpin for ComponentBinding<C> where
    C: Unpin

impl<C> !UnwindSafe for ComponentBinding<C>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,