Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release 0.1.6 #31

Merged
merged 1 commit into from
Feb 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "kanidm-hsm-crypto"
description = "A library for easily interacting with a HSM or TPM"
version = "0.1.5"
version = "0.1.6"
edition = "2021"
license = "MPL-2.0"
homepage = "https://github.com/kanidm/hsm-crypto/"
Expand Down
20 changes: 12 additions & 8 deletions src/tpm.rs
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
use crate::{
AuthValue, HmacKey, IdentityKey, KeyAlgorithm, LoadableHmacKey, LoadableIdentityKey,
LoadableMachineKey, MachineKey, Tpm, TpmError, AES256GCM_IV_LEN, AES256GCM_KEY_LEN,
LoadableMachineKey, MachineKey, Tpm, TpmError,
};

use crate::soft::{aes_256_gcm_decrypt, aes_256_gcm_encrypt};

use openssl::bn::BigNum;
use openssl::ecdsa::EcdsaSig;
use openssl::hash::{hash, MessageDigest};
Expand All @@ -16,12 +14,11 @@ use tracing::error;
use tss_esapi::attributes::{ObjectAttributesBuilder, SessionAttributesBuilder};
use tss_esapi::constants::SessionType;
use tss_esapi::structures::{
CreateKeyResult, CreatePrimaryKeyResult, Data, Digest, EccParameter, EccPoint, EccScheme,
CreateKeyResult, CreatePrimaryKeyResult, Digest, EccParameter, EccPoint, EccScheme,
EccSignature, HashScheme, HashcheckTicket, KeyedHashScheme, MaxBuffer, PublicBuilder,
PublicEccParametersBuilder, PublicKeyRsa, PublicKeyedHashParameters,
PublicRsaParametersBuilder, RsaDecryptionScheme, RsaExponent, RsaScheme, RsaSignature,
SensitiveData, Signature, SignatureScheme, SymmetricCipherParameters, SymmetricDefinition,
SymmetricDefinitionObject,
PublicRsaParametersBuilder, RsaExponent, RsaScheme, RsaSignature, Signature, SignatureScheme,
SymmetricCipherParameters, SymmetricDefinition, SymmetricDefinitionObject,
};
use tss_esapi::Context;
use tss_esapi::TctiNameConf;
Expand All @@ -43,7 +40,14 @@ pub use tss_esapi::structures::{Auth, Private, Public};
pub use tss_esapi::utils::TpmsContext;

#[cfg(feature = "msextensions")]
use crate::{LoadableMsOapxbcRsaKey, LoadableMsOapxbcSessionKey, MsOapxbcRsaKey, SealedData};
use crate::soft::{aes_256_gcm_decrypt, aes_256_gcm_encrypt};
#[cfg(feature = "msextensions")]
use crate::{
LoadableMsOapxbcRsaKey, LoadableMsOapxbcSessionKey, MsOapxbcRsaKey, SealedData,
AES256GCM_IV_LEN, AES256GCM_KEY_LEN,
};
#[cfg(feature = "msextensions")]
use tss_esapi::structures::{Data, RsaDecryptionScheme, SensitiveData};
#[cfg(feature = "msextensions")]
use zeroize::Zeroizing;

Expand Down
Loading