pub struct Round1Work {
pub response: SubtreeAuditResponse,
pub content_bytes: i64,
pub corrupt_keys: Vec<XorName>,
}Expand description
A round-1 response together with the chunk bytes spent producing it.
Fields§
§response: SubtreeAuditResponseWhat to send back.
content_bytes: i64Chunk content read from LMDB and hashed BEFORE this response was produced.
Counted on the rejecting paths too, which is the point. A subtree is read
leaf by leaf, so a commitment holding one unreadable key still costs a
full run of reads and keyed-BLAKE3 passes over every leaf before it. If
only the Proof arm were charged, an attacker who found such a
commitment could replay subtrees over it indefinitely for free — and
since the per-peer cooldown is escapable by rotating identity, the
responder-wide work budget is the only bound that would have caught it.
corrupt_keys: Vec<XorName>Committed chunks whose bytes, read for this proof, no longer hash to their key.
The proof still carries what was read, so the auditor’s verdict on them
is unchanged. The caller reports them to the chunk store
(ChunkStore::report_corrupt), whose recheck worker takes the ones its
bounded queue admits out of service, so the node stops committing a chunk
it cannot prove and replication can repair it, rather than failing every
audit that lands on that key until a fetch of the same key happens to
notice. A key the queue cannot take stays committed, so the next audit
that reads it reports it again. Not done here, so the cleanup never delays
the answer the auditor is waiting for.
Auto Trait Implementations§
impl Freeze for Round1Work
impl RefUnwindSafe for Round1Work
impl Send for Round1Work
impl Sync for Round1Work
impl Unpin for Round1Work
impl UnsafeUnpin for Round1Work
impl UnwindSafe for Round1Work
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more