Skip to content

Commit d5461e6

Browse files
authored
Merge pull request #80 from mikkyang/refactor/digest-imports
Rearrange imports and prefer hmac::Mac over digest::Mac
2 parents cf254de + c9f02e8 commit d5461e6

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

src/algorithm/rust_crypto.rs

+4-6
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,14 @@
22
//! According to that organization, only hmac is safely implemented at the
33
//! moment.
44
5-
use digest::core_api::{CoreProxy, FixedOutputCore};
65
use digest::{
76
block_buffer::Eager,
87
consts::U256,
9-
core_api::{BlockSizeUser, BufferKindUser},
8+
core_api::{BlockSizeUser, BufferKindUser, CoreProxy, FixedOutputCore},
109
generic_array::typenum::{IsLess, Le, NonZero},
11-
HashMarker, Mac,
10+
HashMarker,
1211
};
13-
use hmac::Hmac;
12+
use hmac::{Hmac, Mac};
1413

1514
use crate::algorithm::{AlgorithmType, SigningAlgorithm, VerifyingAlgorithm};
1615
use crate::error::Error;
@@ -108,8 +107,7 @@ where
108107
mod tests {
109108
use crate::algorithm::{SigningAlgorithm, VerifyingAlgorithm};
110109
use crate::error::Error;
111-
use digest::Mac;
112-
use hmac::Hmac;
110+
use hmac::{Hmac, Mac};
113111
use sha2::Sha256;
114112

115113
#[test]

0 commit comments

Comments
 (0)