Dcf

Trait Dcf 

Source
pub trait Dcf<const N: usize, const LAMBDA: usize, G>
where G: Group<LAMBDA>,
{ // Required methods fn gen( &self, f: &CmpFn<N, LAMBDA, G>, s0s: [&[u8; LAMBDA]; 2], ) -> Share<LAMBDA, G>; fn eval( &self, b: bool, k: &Share<LAMBDA, G>, xs: &[&[u8; N]], ys: &mut [&mut G], ); }
Expand description

API of Distributed comparison function.

See CmpFn for N and LAMBDA.

Required Methods§

Source

fn gen( &self, f: &CmpFn<N, LAMBDA, G>, s0s: [&[u8; LAMBDA]; 2], ) -> Share<LAMBDA, G>

s0s is $s^{(0)}_0$ and $s^{(0)}_1$ which should be randomly sampled

Source

fn eval( &self, b: bool, k: &Share<LAMBDA, G>, xs: &[&[u8; N]], ys: &mut [&mut G], )

b is the party. false is 0 and true is 1.

Implementors§

Source§

impl<const N: usize, const LAMBDA: usize, PrgT, G> Dcf<N, LAMBDA, G> for DcfImpl<N, LAMBDA, PrgT>
where PrgT: Prg<LAMBDA>, G: Group<LAMBDA>,