Trait ocelot::oprf::Receiver

source ·
pub trait Receiver: ObliviousPrf
where Self: Sized,
{ // Required methods fn init<C: AbstractChannel, RNG: CryptoRng + Rng>( channel: &mut C, rng: &mut RNG ) -> Result<Self, Error>; fn receive<C: AbstractChannel, RNG: CryptoRng + Rng>( &mut self, channel: &mut C, inputs: &[Self::Input], rng: &mut RNG ) -> Result<Vec<Self::Output>, Error>; }
Expand description

Trait for an oblivious PRF receiver.

Required Methods§

source

fn init<C: AbstractChannel, RNG: CryptoRng + Rng>( channel: &mut C, rng: &mut RNG ) -> Result<Self, Error>

Runs any one-time initialization.

source

fn receive<C: AbstractChannel, RNG: CryptoRng + Rng>( &mut self, channel: &mut C, inputs: &[Self::Input], rng: &mut RNG ) -> Result<Vec<Self::Output>, Error>

Runs the oblivious PRF on inputs inputs, returning the OPRF outputs.

Object Safety§

This trait is not object safe.

Implementors§

source§

impl<OT: OtSender<Msg = Block> + SemiHonest> Receiver for Receiver<OT>