Skip to main content

StarkProtocolConfig

Trait StarkProtocolConfig 

Source
pub trait StarkProtocolConfig:
    'static
    + Clone
    + Send
    + Sync {
    type F: TwoAdicField + PrimeField64;
    type EF: TwoAdicField + ExtensionField<Self::F>;
    type Digest: Copy + Send + Sync + Debug + Default + PartialEq + Eq + Serialize + for<'de> Deserialize<'de>;
    type Hasher: MerkleHasher<F = Self::F, Digest = Self::Digest>;

    const D_EF: usize = _;

    // Required methods
    fn params(&self) -> &SystemParams;
    fn hasher(&self) -> &Self::Hasher;
}
Expand description

Trait that holds the associated types for the SWIRL protocol. These are the types needed by the verifier and must be independent of the prover backend.

This trait only holds the associated types and the struct implementing the trait does not hold the system parameters. System parameters are specified and stored separated in SystemParams.

The trait has an implicit associated Fiat-Shamir transcript type, including the hash used. There is no explicit associated type because the concrete implementation of the transcript may differ between prover and verifier and the verifier may further employ different implementations for logging or debugging purposes. The trait controlling concrete implementations of the transcript is specified by FiatShamirTranscript.

Provided Associated Constants§

Source

const D_EF: usize = _

Degree of the extension field.

Required Associated Types§

Source

type F: TwoAdicField + PrimeField64

The prime base field.

Source

type EF: TwoAdicField + ExtensionField<Self::F>

The extension field, used for random challenges.

Source

type Digest: Copy + Send + Sync + Debug + Default + PartialEq + Eq + Serialize + for<'de> Deserialize<'de>

The digest type used for commitments.

Source

type Hasher: MerkleHasher<F = Self::F, Digest = Self::Digest>

The merkle tree hasher used by the polynomial commitment scheme.

Required Methods§

Source

fn params(&self) -> &SystemParams

Source

fn hasher(&self) -> &Self::Hasher

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§