pub enum KeyLengthDh {
Rfc1024_160,
Rfc2048_224,
Rfc2048_256,
Generator2Bits(u16),
Generator5Bits(u16),
}Expand description
Enumeration of various YACA DH parameters including RFC 5114
- It’s meant to be passed or returned with
KeyLength::Dhin appropriate functions when dealing with Diffie-Hellman.
Variants§
Rfc1024_160
RFC 5114 DH parameters 1024_160
Rfc2048_224
RFC 5114 DH parameters 2048_224
Rfc2048_256
RFC 5114 DH parameters 2048_256
Generator2Bits(u16)
Generator equal 2 for DH parameters
- Needs specifying safe prime length in bits.
- Prime length needs to be >= 256 and divisble by 8.
- Prime length is recommended to be 2048 bits or higher.
Generator5Bits(u16)
Generator equal 5 for DH parameters
- Needs specifying safe prime length in bits.
- Prime length needs to be >= 256 and divisble by 8.
- Prime length is recommended to be 2048 bits or higher.
Trait Implementations§
Source§impl Debug for KeyLengthDh
impl Debug for KeyLengthDh
Source§impl PartialEq for KeyLengthDh
impl PartialEq for KeyLengthDh
impl StructuralPartialEq for KeyLengthDh
Auto Trait Implementations§
impl Freeze for KeyLengthDh
impl RefUnwindSafe for KeyLengthDh
impl Send for KeyLengthDh
impl Sync for KeyLengthDh
impl Unpin for KeyLengthDh
impl UnwindSafe for KeyLengthDh
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