Enum saml_rs::sign::DigestAlgorithm
source · [−]pub enum DigestAlgorithm {
Sha1,
Sha224,
Sha256,
Sha384,
Sha512,
InvalidAlgorithm,
}
Expand description
Options of Digest Algorithms for things
Variants
Sha1
SHA1 Algorithm (Use is DISCOURAGED; see SHA-1 Warning)
Sha224
Really?
Sha256
SHA256 Algorithm
Sha384
For when 256 isn’t enough
Sha512
Size does matter, I guess?
InvalidAlgorithm
If you try to use the wrong one
Implementations
sourceimpl DigestAlgorithm
impl DigestAlgorithm
sourcepub fn hash(self, bytes_to_hash: &[u8]) -> Result<DigestBytes, ErrorStack>
pub fn hash(self, bytes_to_hash: &[u8]) -> Result<DigestBytes, ErrorStack>
Hash a set of bytes using an openssl::hash::MessageDigest
Trait Implementations
sourceimpl Clone for DigestAlgorithm
impl Clone for DigestAlgorithm
sourcefn clone(&self) -> DigestAlgorithm
fn clone(&self) -> DigestAlgorithm
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresourceimpl Debug for DigestAlgorithm
impl Debug for DigestAlgorithm
sourceimpl Display for DigestAlgorithm
impl Display for DigestAlgorithm
sourceimpl From<DigestAlgorithm> for MessageDigest
impl From<DigestAlgorithm> for MessageDigest
sourcefn from(src: DigestAlgorithm) -> MessageDigest
fn from(src: DigestAlgorithm) -> MessageDigest
Converts to this type from the input type.
sourceimpl From<DigestAlgorithm> for String
impl From<DigestAlgorithm> for String
sourcefn from(sa: DigestAlgorithm) -> String
fn from(sa: DigestAlgorithm) -> String
Converts to this type from the input type.
sourceimpl From<MessageDigest> for DigestAlgorithm
impl From<MessageDigest> for DigestAlgorithm
sourcefn from(_md: MessageDigest) -> Self
fn from(_md: MessageDigest) -> Self
Converts to this type from the input type.
sourceimpl From<String> for DigestAlgorithm
impl From<String> for DigestAlgorithm
impl Copy for DigestAlgorithm
Auto Trait Implementations
impl RefUnwindSafe for DigestAlgorithm
impl Send for DigestAlgorithm
impl Sync for DigestAlgorithm
impl Unpin for DigestAlgorithm
impl UnwindSafe for DigestAlgorithm
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more