Documentation ¶
Overview ¶
The keccak package implements the utilities for proving the hash over a single provider. The provider of type generic.GenericByteModule encodes the inputs and outputs of hash (related to the same module). The inputs and outputs are respectively embedded inside generic.GenDataModule, and generic.GenInfoModule.
The keccak package accumulates the providers from different zkEVM modules,
and proves the hash consistency over the unified provider.
The provider encodes the inputs and outputs of the hash from different modules.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AssignLaneInfo ¶
func AssignLaneInfo(run *wizard.ProverRuntime, l *LaneInfo, in [][]byte)
AssignLaneInfo a helper function that assigns the blocks (i.e., LaneInfo)) from the stream. Blocks then can be used by the customizedKeccak.
Types ¶
type KeccakOverBlockInputs ¶
type KeccakOverBlockInputs struct { LaneInfo LaneInfo MaxNumKeccakF int // used for the assignments Provider [][]byte }
KeccakOverBlockInputs stores the inputs required for NewKeccakOverBlocks
type KeccakOverBlocks ¶
type KeccakOverBlocks struct { Inputs *KeccakOverBlockInputs HashHi, HashLo ifaces.Column // it indicates the active part of HashHi/HashLo IsActive ifaces.Column MaxNumKeccakF int // contains filtered or unexported fields }
KeccakOverBlocks stores the result of the hash and the wizard.ProverAction of all the submodules.
func NewKeccakOverBlocks ¶
func NewKeccakOverBlocks(comp *wizard.CompiledIOP, inp KeccakOverBlockInputs) *KeccakOverBlocks
NewKeccakOverBlocks implements the utilities for proving keccak hash over the given blocks. It assumes that the padding and packing of the stream into blocks is done correctly,and thus directly uses the blocks.
func (*KeccakOverBlocks) Run ¶
func (m *KeccakOverBlocks) Run(run *wizard.ProverRuntime)
It implements wizard.ProverAction for customizedKeccak.
type KeccakSingleProvider ¶
type KeccakSingleProvider struct { Inputs *KeccakSingleProviderInput HashHi, HashLo ifaces.Column // indicates the active part of HashHi/HashLo IsActive ifaces.Column MaxNumKeccakF int // contains filtered or unexported fields }
KeccakSingleProvider stores the hash result and wizard.ProverAction of the submodules.
func NewKeccakSingleProvider ¶
func NewKeccakSingleProvider(comp *wizard.CompiledIOP, inp KeccakSingleProviderInput) *KeccakSingleProvider
NewKeccakSingleProvider implements the utilities for proving keccak hash over the streams which are encoded inside a set of structs generic.GenDataModule. It calls; - Padding module to insure the correct padding of the streams. - packing module to insure the correct packing of padded-stream into blocks. - keccakOverBlocks to insures the correct hash computation over the given blocks.
func (*KeccakSingleProvider) Run ¶
func (m *KeccakSingleProvider) Run(run *wizard.ProverRuntime)
It implements wizard.ProverAction for keccak.
type KeccakSingleProviderInput ¶
type KeccakSingleProviderInput struct { MaxNumKeccakF int Provider generic.GenericByteModule }
KeccakSingleProviderInput stores the inputs for NewKeccakSingleProvider
type KeccakZkEVM ¶
type KeccakZkEVM struct { Settings *Settings // contains filtered or unexported fields }
func NewKeccakZkEVM ¶
func NewKeccakZkEVM(comp *wizard.CompiledIOP, settings Settings, providersFromEcdsa []generic.GenericByteModule) *KeccakZkEVM
func (*KeccakZkEVM) Run ¶
func (k *KeccakZkEVM) Run(run *wizard.ProverRuntime)
Source Files ¶
Directories ¶
Path | Synopsis |
---|---|
The accumulator package is responsible for accumulating the data from different arithmetization module.
|
The accumulator package is responsible for accumulating the data from different arithmetization module. |
The keccakf package implements to keccakf module.
|
The keccakf package implements to keccakf module. |