pub struct CheckpointClaim {
pub checkpoint_id: Uuid,
pub head: [u8; 32],
pub entry_count: u64,
pub head_event_id: Uuid,
pub checkpoint_at: DateTime<Utc>,
pub prev_checkpoint: Option<[u8; 32]>,
pub verification_method: String,
}Expand description
Everything a checkpoint commits to, except the signature itself.
Split out so AuditCheckpoint::sign and
AuditCheckpoint::verify_signature cannot disagree about what is signed
— the classic way a signature scheme ends up covering less than it appears
to.
Fields§
§checkpoint_id: Uuid§head: [u8; 32]§entry_count: u64§head_event_id: Uuid§checkpoint_at: DateTime<Utc>§prev_checkpoint: Option<[u8; 32]>§verification_method: StringImplementations§
Source§impl CheckpointClaim
impl CheckpointClaim
Sourcepub fn signing_payload(&self) -> Vec<u8> ⓘ
pub fn signing_payload(&self) -> Vec<u8> ⓘ
The exact bytes an Ed25519 signature covers.
Length-prefixed and domain-tagged rather than a JSON encoding: the
signature must not depend on serializer field ordering or on a
canonicalisation step that could differ between signer and verifier.
Same reasoning as the envelope’s chain_digest.
Trait Implementations§
Source§impl Clone for CheckpointClaim
impl Clone for CheckpointClaim
Source§fn clone(&self) -> CheckpointClaim
fn clone(&self) -> CheckpointClaim
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CheckpointClaim
impl Debug for CheckpointClaim
impl Eq for CheckpointClaim
Source§impl PartialEq for CheckpointClaim
impl PartialEq for CheckpointClaim
impl StructuralPartialEq for CheckpointClaim
Auto Trait Implementations§
impl Freeze for CheckpointClaim
impl RefUnwindSafe for CheckpointClaim
impl Send for CheckpointClaim
impl Sync for CheckpointClaim
impl Unpin for CheckpointClaim
impl UnsafeUnpin for CheckpointClaim
impl UnwindSafe for CheckpointClaim
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.