pub struct Cl15k<Up, Udk> {
p: Odd<Up>,
absolute_value: Udk,
}Expand description
A fundamental discriminant as part of the CL15 cryptosystem.
This is constructed as detailed in “Linearly Homomorphic Encryption from DDH” by Guilhem Castagnos and Fabien Laguillaumie (https://eprint.iacr.org/2025/047), corresponding to $\Delta_K$.
Up is the numeric type used to represent the prime p. Udk is the numeric type used to
represent the discriminant’s absolute value, the product $q * p$.
Fields§
§p: Odd<Up>§absolute_value: UdkImplementations§
Trait Implementations§
impl<Up, Udk> Discriminant for Cl15k<Up, Udk>
Source§impl<Up, Udk> FundamentalDiscriminant for Cl15k<Up, Udk>
impl<Up, Udk> FundamentalDiscriminant for Cl15k<Up, Udk>
Source§fn inject<E: Element>(&self, element: impl Element, p: &impl Encoding) -> Ewhere
Self: NegativeDiscriminant,
fn inject<E: Element>(&self, element: impl Element, p: &impl Encoding) -> Ewhere
Self: NegativeDiscriminant,
Available on crate feature
alloc only.Take an element of the class group with fundamental discriminant and apply the injection such
that it is mapped to an element of the class group with non-fundamental discriminant. Read more
Source§impl<Up, Udk: Encoding> NegativeDiscriminant for Cl15k<Up, Udk>
impl<Up, Udk: Encoding> NegativeDiscriminant for Cl15k<Up, Udk>
Source§fn absolute_value(&self) -> impl AsRef<[u8]>
fn absolute_value(&self) -> impl AsRef<[u8]>
This runs in time variable to the bit-length of the discriminant.
Source§fn upper_bound_on_order(&self) -> u32
fn upper_bound_on_order(&self) -> u32
An upper bound on the order of the class group with this discriminant. Read more
impl<Up, Udk> OddDiscriminant for Cl15k<Up, Udk>
Auto Trait Implementations§
impl<Up, Udk> Freeze for Cl15k<Up, Udk>
impl<Up, Udk> RefUnwindSafe for Cl15k<Up, Udk>where
Udk: RefUnwindSafe,
Up: RefUnwindSafe,
impl<Up, Udk> Send for Cl15k<Up, Udk>
impl<Up, Udk> Sync for Cl15k<Up, Udk>
impl<Up, Udk> Unpin for Cl15k<Up, Udk>
impl<Up, Udk> UnsafeUnpin for Cl15k<Up, Udk>where
Udk: UnsafeUnpin,
Up: UnsafeUnpin,
impl<Up, Udk> UnwindSafe for Cl15k<Up, Udk>where
Udk: UnwindSafe,
Up: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> SizedTypeProperties for T
impl<T> SizedTypeProperties for T
Source§#[doc(hidden)]const SIZE: usize = _
#[doc(hidden)]const SIZE: usize = _
🔬This is a nightly-only experimental API. (
sized_type_properties)Source§#[doc(hidden)]const ALIGN: usize = _
#[doc(hidden)]const ALIGN: usize = _
🔬This is a nightly-only experimental API. (
sized_type_properties)Source§#[doc(hidden)]const ALIGNMENT: Alignment = _
#[doc(hidden)]const ALIGNMENT: Alignment = _
🔬This is a nightly-only experimental API. (
ptr_alignment_type)Source§#[doc(hidden)]const IS_ZST: bool = _
#[doc(hidden)]const IS_ZST: bool = _
🔬This is a nightly-only experimental API. (
sized_type_properties)Source§#[doc(hidden)]const LAYOUT: Layout = _
#[doc(hidden)]const LAYOUT: Layout = _
🔬This is a nightly-only experimental API. (
sized_type_properties)Source§#[doc(hidden)]const MAX_SLICE_LEN: usize = _
#[doc(hidden)]const MAX_SLICE_LEN: usize = _
🔬This is a nightly-only experimental API. (
sized_type_properties)The largest safe length for a
[Self]. Read more