Skip to content

Commit 6fcda55

Browse files
authored
Make documentation more precise (#277)
According to https://en.wikipedia.org/wiki/SHA-2#Comparison_of_SHA_functions, it's 8 x 32 bits for sha256 and 8 x 64 bits for sha512. Reading just `the 32-bit 'Sha256'` is confusing to me. But YMMV...
1 parent 1de4114 commit 6fcda55

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

sha2/src/lib.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@
22
//!
33
//! There are 6 standard algorithms specified in the SHA-2 standard:
44
//!
5-
//! * `Sha224`, which is the 32-bit `Sha256` algorithm with the result truncated
5+
//! * `Sha224`, which is the 8 x 32-bit `Sha256` algorithm with the result truncated
66
//! to 224 bits.
7-
//! * `Sha256`, which is the 32-bit `Sha256` algorithm.
8-
//! * `Sha384`, which is the 64-bit `Sha512` algorithm with the result truncated
7+
//! * `Sha256`, which is the 8 x 32-bit `Sha256` algorithm.
8+
//! * `Sha384`, which is the 8 x 64-bit `Sha512` algorithm with the result truncated
99
//! to 384 bits.
10-
//! * `Sha512`, which is the 64-bit `Sha512` algorithm.
11-
//! * `Sha512Trunc224`, which is the 64-bit `Sha512` algorithm with the result
10+
//! * `Sha512`, which is the 8 x 64-bit `Sha512` algorithm.
11+
//! * `Sha512Trunc224`, which is the 8 x 64-bit `Sha512` algorithm with the result
1212
//! truncated to 224 bits.
13-
//! * `Sha512Trunc256`, which is the 64-bit `Sha512` algorithm with the result
13+
//! * `Sha512Trunc256`, which is the 8 x 64-bit `Sha512` algorithm with the result
1414
//! truncated to 256 bits.
1515
//!
1616
//! Algorithmically, there are only 2 core algorithms: `Sha256` and `Sha512`.

0 commit comments

Comments
 (0)