Skip to content

Commit 526cc6e

Browse files
committed
add sha3 docs
1 parent 2d6379d commit 526cc6e

File tree

2 files changed

+24
-12
lines changed

2 files changed

+24
-12
lines changed

sha3/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "sha3"
3-
version = "0.8.1"
3+
version = "0.8.2"
44
authors = ["RustCrypto Developers"]
55
license = "MIT OR Apache-2.0"
66
description = "SHA-3 (Keccak) hash function"

sha3/src/lib.rs

+23-11
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@
4343
#![no_std]
4444
#![doc(html_logo_url =
4545
"https://raw.githubusercontent.com/RustCrypto/meta/master/logo_small.png")]
46+
#![deny(missing_docs, warnings)]
4647
extern crate keccak;
4748
extern crate block_buffer;
4849
extern crate byte_tools;
@@ -68,17 +69,28 @@ mod state;
6869
pub use reader::Sha3XofReader;
6970
use state::Sha3State;
7071

71-
sha3_impl!(Keccak224, U28, U144, paddings::Keccak, "");
72-
sha3_impl!(Keccak256, U32, U136, paddings::Keccak, "");
73-
sha3_impl!(Keccak384, U48, U104, paddings::Keccak, "");
74-
sha3_impl!(Keccak512, U64, U72, paddings::Keccak, "");
72+
sha3_impl!(Keccak224, U28, U144, paddings::Keccak,
73+
"Keccak-224 hash function.");
74+
sha3_impl!(Keccak256, U32, U136, paddings::Keccak,
75+
"Keccak-256 hash function.");
76+
sha3_impl!(Keccak384, U48, U104, paddings::Keccak,
77+
"Keccak-384 hash function.");
78+
sha3_impl!(Keccak512, U64, U72, paddings::Keccak,
79+
"Keccak-512 hash function.");
7580

76-
sha3_impl!(Keccak256Full, U200, U136, paddings::Keccak, "SHA-3 variant used in CryptoNight.");
81+
sha3_impl!(Keccak256Full, U200, U136, paddings::Keccak,
82+
"SHA-3 variant used in CryptoNight.");
7783

78-
sha3_impl!(Sha3_224, U28, U144, paddings::Sha3, "");
79-
sha3_impl!(Sha3_256, U32, U136, paddings::Sha3, "");
80-
sha3_impl!(Sha3_384, U48, U104, paddings::Sha3, "");
81-
sha3_impl!(Sha3_512, U64, U72, paddings::Sha3, "");
84+
sha3_impl!(Sha3_224, U28, U144, paddings::Sha3,
85+
"SHA-3-224 hash function.");
86+
sha3_impl!(Sha3_256, U32, U136, paddings::Sha3,
87+
"SHA-3-256 hash function.");
88+
sha3_impl!(Sha3_384, U48, U104, paddings::Sha3,
89+
"SHA-3-384 hash function.");
90+
sha3_impl!(Sha3_512, U64, U72, paddings::Sha3,
91+
"SHA-3-512 hash function.");
8292

83-
shake_impl!(Shake128, U168, paddings::Shake, "");
84-
shake_impl!(Shake256, U136, paddings::Shake, "");
93+
shake_impl!(Shake128, U168, paddings::Shake,
94+
"SHAKE128 extendable output (XOF) hash function");
95+
shake_impl!(Shake256, U136, paddings::Shake,
96+
"SHAKE256 extendable output (XOF) hash function");

0 commit comments

Comments
 (0)