Finish eliminating consts module

Either moves constants into their relevant modules, or puts the
remaining ones into `lib.rs`
This commit is contained in:
Tony Arcieri
2019-12-08 09:32:57 -08:00
parent 86b8c6a6db
commit 31efd4e78c
11 changed files with 86 additions and 47 deletions
+6 -1
View File
@@ -37,7 +37,10 @@ use std::convert::{TryFrom, TryInto};
use zeroize::{Zeroize, Zeroizing};
#[cfg(feature = "untested")]
use crate::{consts::*, metadata, yubikey::YubiKey};
use crate::{
metadata, yubikey::YubiKey, CB_BUF_MAX, CB_OBJ_MAX, TAG_ADMIN, TAG_ADMIN_FLAGS_1,
TAG_ADMIN_SALT, TAG_PROTECTED, TAG_PROTECTED_MGM,
};
#[cfg(feature = "untested")]
use des::{
block_cipher_trait::{generic_array::GenericArray, BlockCipher},
@@ -50,6 +53,8 @@ use pbkdf2::pbkdf2;
#[cfg(feature = "untested")]
use sha1::Sha1;
pub(crate) const ADMIN_FLAGS_1_PROTECTED_MGM: u8 = 0x02;
#[cfg(feature = "untested")]
const CB_ADMIN_SALT: usize = 16;