Skip to main content

Module sha

Module sha 

Source
Expand description

Fine-grained, single-context SHA-256 WOTS verifier.

The context loads one exact 35-beat input frame, stores signature segments directly in two mutable parity banks, derives all sixteen current-oracle masks, advances only real chain steps, hashes the 67 endpoints, and retains a small verification result under backpressure. It emits no task for a bypassed chain position.

Tasks may issue in any dependency-correct order. Every accepted response must carry a canonical verifier-subset tag for this context and generation and name an actually in-flight task. Rejected responses perform no state write and latch a fail-closed transport poison that prevents context reuse until shared reset. Reset suppresses requests, response acceptance, memory writes, and retained results; the enclosing lane must share that reset.

The functional compression-lane contract is exact 64-cycle latency with tag preservation. A 64-bit due bitmap enforces response cardinality and timing locally, but is not an independent detector for a perfect swap of two canonical in-flight tags. The enclosing verifier transport supplies that stronger expected-tag delay line and converts every global integrity failure into transport_abort. This context exposes ordinary request backpressure; explicit outbound rejection and unowned lane returns are cluster-fatal rather than being represented as an indefinitely deasserted request_ready. Message digits are intentionally not retained after loading: the segment stages and exact expected-task count capture every downstream dependency, avoiding 268 bits of redundant logical register state.

Logical RAM geometry is 36,864 bits per context. This is source geometry, not synthesis, mapping, resource, timing, route, or hardware evidence.

Structs§

VerifyContextControl
Resettable frame, dependency, ownership, and result state.
VerifyContextInput
Input ports for one SHA verifier context.
VerifyContextOutput
Output ports from one SHA verifier context.
VerifyPrepareRequestInput
Inputs needed after one synchronous state/mask-memory prefetch.
VerifySingleContextSha
Complete one-context SHA verifier.

Constants§

VERIFY_CONTEXT_LOGICAL_RAM_BITS
Logical RAM bits authored by one SHA verifier context.
VERIFY_ERROR_AUDIT
Completion disagreed with exact task/dependency accounting.
VERIFY_ERROR_FRAME
Noncanonical keep, last, job-ID, context, or generation framing.
VERIFY_ERROR_NONE
Successful protocol execution; verified carries the signature decision.
VERIFY_ERROR_TRANSPORT
Malformed, stale, duplicate, or unexpected compression response.
VERIFY_LANE_LATENCY
Exact functional latency required from the tag-preserving SHA lane.

Functions§

prepare_verify_request_kernel
Build a SHA request for exactly Mask, Chain, or PublicKey work.
verify_single_context_sha_kernel
State transition and memory connectivity for VerifySingleContextSha.