pub struct Components { /* private fields */ }Expand description
The common components of an DSA keypair
(the prime p, quotient q and generator g)
Implementations§
Source§impl Components
impl Components
Sourcepub fn from_components(p: BoxedUint, q: BoxedUint, g: BoxedUint) -> Result<Self>
pub fn from_components(p: BoxedUint, q: BoxedUint, g: BoxedUint) -> Result<Self>
Construct the common components container from its inner values (p, q and g)
Sourcepub fn from_components_unchecked(
p: BoxedUint,
q: BoxedUint,
g: BoxedUint,
) -> Result<Self>
pub fn from_components_unchecked( p: BoxedUint, q: BoxedUint, g: BoxedUint, ) -> Result<Self>
Construct the common components container from its inner values (p, q and g)
§Safety
Any length of keys may be used, no checks are to be performed. You are responsible for checking the key strengths.
Trait Implementations§
Source§impl Clone for Components
impl Clone for Components
Source§fn clone(&self) -> Components
fn clone(&self) -> Components
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for Components
impl Debug for Components
Source§impl<'a> DecodeValue<'a> for Components
impl<'a> DecodeValue<'a> for Components
Source§impl EncodeValue for Components
impl EncodeValue for Components
Source§impl PartialEq for Components
impl PartialEq for Components
Source§impl PartialOrd for Components
impl PartialOrd for Components
impl Sequence<'_> for Components
impl StructuralPartialEq for Components
Auto Trait Implementations§
impl Freeze for Components
impl RefUnwindSafe for Components
impl Send for Components
impl Sync for Components
impl Unpin for Components
impl UnsafeUnpin for Components
impl UnwindSafe for Components
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<'a, T> Decode<'a> for Twhere
T: DecodeValue<'a> + FixedTag + 'a,
impl<'a, T> Decode<'a> for Twhere
T: DecodeValue<'a> + FixedTag + 'a,
Source§type Error = <T as DecodeValue<'a>>::Error
type Error = <T as DecodeValue<'a>>::Error
Type returned in the event of a decoding error.
Source§fn decode<R>(reader: &mut R) -> Result<T, <T as DecodeValue<'a>>::Error>where
R: Reader<'a>,
fn decode<R>(reader: &mut R) -> Result<T, <T as DecodeValue<'a>>::Error>where
R: Reader<'a>,
Attempt to decode this TLV message using the provided decoder. Read more
Source§impl<T> Encode for T
impl<T> Encode for T
Source§fn encoded_len(&self) -> Result<Length, Error>
fn encoded_len(&self) -> Result<Length, Error>
Compute the length of this TLV object in bytes when encoded as ASN.1 DER. Read more
Source§fn encode_to_slice<'a>(&self, buf: &'a mut [u8]) -> Result<&'a [u8], Error>
fn encode_to_slice<'a>(&self, buf: &'a mut [u8]) -> Result<&'a [u8], Error>
Encode this TLV object to the provided byte slice, returning a sub-slice
containing the encoded message. Read more
Source§impl<T> IsConstructed for T
impl<T> IsConstructed for T
Source§const CONSTRUCTED: bool
const CONSTRUCTED: bool
ASN.1 constructed bit