Module cryptoxide::sha1 [−][src]
Expand description
An implementation of the SHA-1 cryptographic hash algorithm.
it is however discouraged to use this algorithm in any application as is, as this is not considered secured anymore. the algorithm is deprecated since 2011, and chosen prefix attack are practical.
However the hash function is still pervasively used in other contextes where security is still ok (e.g. hmac-sha1), so on this basis is available here.
Example
use cryptoxide::{sha1::Sha1, digest::Digest};
let mut digest = [0u8; 20];
let mut context = Sha1::new();
context.input(b"hello world");
context.result(&mut digest);
Structs
Structure representing the state of a Sha1 computation
Functions
Process a block with the SHA-1 algorithm. (See more…)
Process a block with the SHA-1 algorithm.
Emulates llvm.x86.sha1rnds4
intrinsic.
Performs 4 rounds of the message block digest.
Not an intrinsic, but gets the first element of a vector.
Not an intrinsic, but adds a word to the first element of a vector.
Emulates llvm.x86.sha1nexte
intrinsic.
Performs 4 rounds of the message schedule update.