pub struct TrustGraph<S> where
    S: Storage
{ /* private fields */ }
Expand description

Graph to efficiently calculate weights of certificates and get chains of certificates. TODO serialization/deserialization TODO export a certificate from graph

Implementations

Insert new root weight

Certificate is a chain of trusts, add this chain to graph

Get the maximum weight of trust for one public key.

Get the maximum weight of trust for one public key. for all chains which contain issuer

Calculate weight from given certificates Returns None if there is no such public key or some trust between this key and a root key is revoked.

Get all possible certificates where issued_for will be the last element of the chain, all certificates contain issuer and one of the destinations is the root of this chain.

Get all possible certificates where issued_for will be the last element of the chain and one of the destinations is the root of this chain.

Mark public key as revoked. Every chain that contains path from revoked_by to revoked pk will be excluded from valid certificates until revocation canceled by giving trust

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Should always be Self

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.