Trait CaseP1

Source
pub trait CaseP1 {
    type OutputLen: ArrayLength + NonZero;
    type CF: ValidCostFactor;
    type R: ArrayLength + NonZero;

    const PASSWORD: &'static [u8];
    const SALT: &'static [u8];
    const KNOWN_ANSWER: GenericArray<u8, Self::OutputLen>;

    // Provided methods
    fn algorithm_self_test() { ... }
    fn pipeline_api_test() { ... }
}
Expand description

Test case for P = 1

Required Associated Constants§

Source

const PASSWORD: &'static [u8]

The password

Source

const SALT: &'static [u8]

The salt

Source

const KNOWN_ANSWER: GenericArray<u8, Self::OutputLen>

The known answer

Required Associated Types§

Source

type OutputLen: ArrayLength + NonZero

The length of the output

Source

type CF: ValidCostFactor

The cost factor

Source

type R: ArrayLength + NonZero

The number of rounds

Provided Methods§

Source

fn algorithm_self_test()

Test the algorithm implementation

Source

fn pipeline_api_test()

Test the pipeline API

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl CaseP1 for CaseN16R1P1

Source§

const PASSWORD: &'static [u8] = b""

Source§

const SALT: &'static [u8] = b""

Source§

const KNOWN_ANSWER: GenericArray<u8, Self::OutputLen>

Source§

type OutputLen = UInt<UInt<UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B0>, B0>, B0>, B0>, B0>, B0>

Source§

type CF = UInt<UInt<UInt<UTerm, B1>, B0>, B0>

Source§

type R = UInt<UTerm, B1>

Source§

impl CaseP1 for CaseN1024R53P1

Source§

const PASSWORD: &'static [u8] = b"password"

Source§

const SALT: &'static [u8] = b"NaCl"

Source§

const KNOWN_ANSWER: GenericArray<u8, Self::OutputLen>

Source§

type OutputLen = UInt<UInt<UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B0>, B0>, B0>, B0>, B0>, B0>

Source§

type CF = UInt<UInt<UInt<UInt<UTerm, B1>, B0>, B1>, B0>

Source§

type R = UInt<UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B1>, B0>, B1>, B0>, B1>

Source§

impl CaseP1 for CaseN16384R8P1

Source§

const PASSWORD: &'static [u8] = b"pleaseletmein"

Source§

const SALT: &'static [u8] = b"SodiumChloride"

Source§

const KNOWN_ANSWER: GenericArray<u8, Self::OutputLen>

Source§

type OutputLen = UInt<UInt<UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B0>, B0>, B0>, B0>, B0>, B0>

Source§

type CF = UInt<UInt<UInt<UInt<UTerm, B1>, B1>, B1>, B0>

Source§

type R = UInt<UInt<UInt<UInt<UTerm, B1>, B0>, B0>, B0>

Source§

impl CaseP1 for CaseN1048576R8P1

Source§

const PASSWORD: &'static [u8] = b"pleaseletmein"

Source§

const SALT: &'static [u8] = b"SodiumChloride"

Source§

const KNOWN_ANSWER: GenericArray<u8, Self::OutputLen>

Source§

type OutputLen = UInt<UInt<UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B0>, B0>, B0>, B0>, B0>, B0>

Source§

type CF = UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B0>, B1>, B0>, B0>

Source§

type R = UInt<UInt<UInt<UInt<UTerm, B1>, B0>, B0>, B0>