Type Alias Challenger

Source
pub type Challenger<P> = DuplexChallenger<Goldilocks, P, WIDTH, RATE>;

Aliased Type§

struct Challenger<P> {
    pub sponge_state: [Goldilocks; 8],
    pub input_buffer: Vec<Goldilocks>,
    pub output_buffer: Vec<Goldilocks>,
    pub permutation: P,
}

Fields§

§sponge_state: [Goldilocks; 8]§input_buffer: Vec<Goldilocks>§output_buffer: Vec<Goldilocks>§permutation: P

Implementations

§

impl<F, P, const WIDTH: usize, const RATE: usize> DuplexChallenger<F, P, WIDTH, RATE>
where F: Copy, P: CryptographicPermutation<[F; WIDTH]>,

pub fn new(permutation: P) -> DuplexChallenger<F, P, WIDTH, RATE>
where F: Default,

Trait Implementations

§

impl<F, P, const N: usize, const WIDTH: usize, const RATE: usize> CanObserve<[F; N]> for DuplexChallenger<F, P, WIDTH, RATE>
where F: Copy, P: CryptographicPermutation<[F; WIDTH]>,

§

fn observe(&mut self, values: [F; N])

§

fn observe_slice(&mut self, values: &[T])
where T: Clone,

§

impl<F, P, const WIDTH: usize, const RATE: usize> CanObserve<F> for DuplexChallenger<F, P, WIDTH, RATE>
where F: Copy, P: CryptographicPermutation<[F; WIDTH]>,

§

fn observe(&mut self, value: F)

§

fn observe_slice(&mut self, values: &[T])
where T: Clone,

§

impl<F, P, const N: usize, const WIDTH: usize, const RATE: usize> CanObserve<Hash<F, F, N>> for DuplexChallenger<F, P, WIDTH, RATE>
where F: Copy, P: CryptographicPermutation<[F; WIDTH]>,

§

fn observe(&mut self, values: Hash<F, F, N>)

§

fn observe_slice(&mut self, values: &[T])
where T: Clone,

§

impl<F, P, const WIDTH: usize, const RATE: usize> CanObserve<Vec<Vec<F>>> for DuplexChallenger<F, P, WIDTH, RATE>
where F: Copy, P: CryptographicPermutation<[F; WIDTH]>,

§

fn observe(&mut self, valuess: Vec<Vec<F>>)

§

fn observe_slice(&mut self, values: &[T])
where T: Clone,

§

impl<F, EF, P, const WIDTH: usize, const RATE: usize> CanSample<EF> for DuplexChallenger<F, P, WIDTH, RATE>
where F: Field, EF: ExtensionField<F>, P: CryptographicPermutation<[F; WIDTH]>,

§

fn sample(&mut self) -> EF

§

fn sample_array<const N: usize>(&mut self) -> [T; N]

§

fn sample_vec(&mut self, n: usize) -> Vec<T>

§

impl<F, P, const WIDTH: usize, const RATE: usize> CanSampleBits<usize> for DuplexChallenger<F, P, WIDTH, RATE>
where F: PrimeField64, P: CryptographicPermutation<[F; WIDTH]>,

§

fn sample_bits(&mut self, bits: usize) -> usize

§

impl<F, P, const WIDTH: usize, const RATE: usize> Clone for DuplexChallenger<F, P, WIDTH, RATE>
where F: Clone, P: Clone + CryptographicPermutation<[F; WIDTH]>,

§

fn clone(&self) -> DuplexChallenger<F, P, WIDTH, RATE>

Returns a copy of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
§

impl<F, P, const WIDTH: usize, const RATE: usize> Debug for DuplexChallenger<F, P, WIDTH, RATE>
where F: Debug + Clone, P: Debug + CryptographicPermutation<[F; WIDTH]>,

§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
§

impl<F, P, const WIDTH: usize, const RATE: usize> FieldChallenger<F> for DuplexChallenger<F, P, WIDTH, RATE>
where F: PrimeField64, P: CryptographicPermutation<[F; WIDTH]>,

§

fn observe_ext_element<EF>(&mut self, ext: EF)
where EF: FieldExtensionAlgebra<F>,

§

fn sample_ext_element<EF>(&mut self) -> EF
where EF: FieldExtensionAlgebra<F>,

§

impl<F, P, const WIDTH: usize, const RATE: usize> GrindingChallenger for DuplexChallenger<F, P, WIDTH, RATE>
where F: PrimeField64, P: CryptographicPermutation<[F; WIDTH]>,

§

type Witness = F

§

fn grind( &mut self, bits: usize, ) -> <DuplexChallenger<F, P, WIDTH, RATE> as GrindingChallenger>::Witness

§

fn check_witness(&mut self, bits: usize, witness: Self::Witness) -> bool