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

Using P256 key from HSM for CASE #8217

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
7 changes: 7 additions & 0 deletions src/credentials/CHIPOperationalCredentials.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@
#include <credentials/CHIPCert.h>
#include <crypto/CHIPCryptoPAL.h>
#include <support/DLLUtil.h>
#if CHIP_CRYPTO_HSM
#include <crypto/hsm/CHIPCryptoPALHsm.h>
#endif

#include <algorithm>
#include <map>
Expand Down Expand Up @@ -66,7 +69,11 @@ struct NodeCredentialMap
struct NodeKeypairMap
{
CertificateKeyId trustedRootId;
#ifdef ENABLE_HSM_CASE_OPS_KEY
P256KeypairHSM keypair;
#else
P256Keypair keypair;
#endif
};

/**
Expand Down
2 changes: 1 addition & 1 deletion src/protocols/secure_channel/CASESession.h
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,7 @@ class DLL_EXPORT CASESession : public Messaging::ExchangeDelegate, public Pairin
Crypto::Hash_SHA256_stream mCommissioningHash;
Crypto::P256PublicKey mRemotePubKey;
#ifdef ENABLE_HSM_CASE_EPHERMAL_KEY
P256KeypairHSM mEphemeralKey;
Crypto::P256KeypairHSM mEphemeralKey;
#else
Crypto::P256Keypair mEphemeralKey;
#endif
Expand Down