pairing_plus::hash_to_curve

Trait HashToCurve

Source
pub trait HashToCurve<X>
where X: ExpandMsg,
{ // Required methods fn hash_to_curve<Mt: AsRef<[u8]>, Dt: AsRef<[u8]>>(msg: Mt, dst: Dt) -> Self; fn encode_to_curve<Mt: AsRef<[u8]>, Dt: AsRef<[u8]>>( msg: Mt, dst: Dt, ) -> Self; }
Expand description

Random oracle and injective maps to curve

Required Methods§

Source

fn hash_to_curve<Mt: AsRef<[u8]>, Dt: AsRef<[u8]>>(msg: Mt, dst: Dt) -> Self

Random oracle

Source

fn encode_to_curve<Mt: AsRef<[u8]>, Dt: AsRef<[u8]>>(msg: Mt, dst: Dt) -> Self

Injective encoding

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<PtT, X> HashToCurve<X> for PtT
where PtT: ClearH + IsogenyMap + OSSWUMap, <PtT as CurveProjective>::Base: FromRO, X: ExpandMsg,