diff --git a/src/app/server/Server.cpp b/src/app/server/Server.cpp index c0d3e108babe65..66bb27c6f3d93d 100644 --- a/src/app/server/Server.cpp +++ b/src/app/server/Server.cpp @@ -541,7 +541,7 @@ void Server::ResumeSubscriptions() Credentials::IgnoreCertificateValidityPeriodPolicy Server::sDefaultCertValidityPolicy; KvsPersistentStorageDelegate CommonCaseDeviceServerInitParams::sKvsPersistenStorageDelegate; -PersistentStorageOperationalKeystore CommonCaseDeviceServerInitParams::sPersistentStorageOperationalKeystore; +Crypto::PSAOperationalKeystore CommonCaseDeviceServerInitParams::sPersistentStorageOperationalKeystore; Credentials::PersistentStorageOpCertStore CommonCaseDeviceServerInitParams::sPersistentStorageOpCertStore; Credentials::GroupDataProviderImpl CommonCaseDeviceServerInitParams::sGroupDataProvider; #if CHIP_CONFIG_ENABLE_SESSION_RESUMPTION diff --git a/src/app/server/Server.h b/src/app/server/Server.h index eee11b0bc6ff60..84b98e188afb1b 100644 --- a/src/app/server/Server.h +++ b/src/app/server/Server.h @@ -40,7 +40,7 @@ #include #include #include -#include +#include #include #include #include @@ -197,7 +197,7 @@ struct CommonCaseDeviceServerInitParams : public ServerInitParams { // WARNING: PersistentStorageOperationalKeystore::Finish() is never called. It's fine for // for examples and for now. - ReturnErrorOnFailure(sPersistentStorageOperationalKeystore.Init(this->persistentStorageDelegate)); + // ReturnErrorOnFailure(sPersistentStorageOperationalKeystore.Init(this->persistentStorageDelegate)); this->operationalKeystore = &sPersistentStorageOperationalKeystore; } @@ -246,7 +246,7 @@ struct CommonCaseDeviceServerInitParams : public ServerInitParams private: static KvsPersistentStorageDelegate sKvsPersistenStorageDelegate; - static PersistentStorageOperationalKeystore sPersistentStorageOperationalKeystore; + static Crypto::PSAOperationalKeystore sPersistentStorageOperationalKeystore; static Credentials::PersistentStorageOpCertStore sPersistentStorageOpCertStore; static Credentials::GroupDataProviderImpl sGroupDataProvider; #if CHIP_CONFIG_ENABLE_SESSION_RESUMPTION diff --git a/src/app/tests/integration/common.cpp b/src/app/tests/integration/common.cpp index 87627aeb9fddf0..19a7b1d75d7e5e 100644 --- a/src/app/tests/integration/common.cpp +++ b/src/app/tests/integration/common.cpp @@ -26,7 +26,7 @@ #include #include -#include +#include #include #include #include @@ -41,7 +41,7 @@ chip::SessionManager gSessionManager; chip::secure_channel::MessageCounterManager gMessageCounterManager; chip::SessionHolder gSession; chip::TestPersistentStorageDelegate gStorage; -chip::PersistentStorageOperationalKeystore gOperationalKeystore; +chip::Crypto::PSAOperationalKeystore gOperationalKeystore; chip::Credentials::PersistentStorageOpCertStore gOpCertStore; chip::Crypto::DefaultSessionKeystore gSessionKeystore; @@ -64,8 +64,8 @@ void InitializeChip() err = gOpCertStore.Init(&gStorage); SuccessOrExit(err); - err = gOperationalKeystore.Init(&gStorage); - SuccessOrExit(err); + // err = gOperationalKeystore.Init(&gStorage); + // SuccessOrExit(err); fabricTableInitParams.storage = &gStorage; fabricTableInitParams.operationalKeystore = &gOperationalKeystore; @@ -92,7 +92,7 @@ void ShutdownChip() gSessionManager.Shutdown(); gFabricTable.Shutdown(); - gOperationalKeystore.Finish(); + // gOperationalKeystore.Finish(); gOpCertStore.Finish(); chip::DeviceLayer::PlatformMgr().Shutdown(); diff --git a/src/credentials/tests/TestFabricTable.cpp b/src/credentials/tests/TestFabricTable.cpp index b687bf34788cf9..63fe033a249f4b 100644 --- a/src/credentials/tests/TestFabricTable.cpp +++ b/src/credentials/tests/TestFabricTable.cpp @@ -32,6 +32,7 @@ #include #include #include +#include #include #include #include @@ -57,7 +58,7 @@ class ScopedFabricTable { mFabricTable.Shutdown(); mOpCertStore.Finish(); - mOpKeyStore.Finish(); + // mOpKeyStore.Finish(); } CHIP_ERROR Init(chip::TestPersistentStorageDelegate * storage) @@ -67,7 +68,7 @@ class ScopedFabricTable initParams.operationalKeystore = &mOpKeyStore; initParams.opCertStore = &mOpCertStore; - ReturnErrorOnFailure(mOpKeyStore.Init(storage)); + // ReturnErrorOnFailure(mOpKeyStore.Init(storage)); ReturnErrorOnFailure(mOpCertStore.Init(storage)); return mFabricTable.Init(initParams); } @@ -76,7 +77,8 @@ class ScopedFabricTable private: chip::FabricTable mFabricTable; - chip::PersistentStorageOperationalKeystore mOpKeyStore; + chip::Crypto::PSAOperationalKeystore mOpKeyStore; + // chip::PersistentStorageOperationalKeystore mOpKeyStore; chip::Credentials::PersistentStorageOpCertStore mOpCertStore; }; diff --git a/src/messaging/tests/MessagingContext.cpp b/src/messaging/tests/MessagingContext.cpp index 295518d0811006..9dceaa0ae9c451 100644 --- a/src/messaging/tests/MessagingContext.cpp +++ b/src/messaging/tests/MessagingContext.cpp @@ -38,7 +38,7 @@ CHIP_ERROR MessagingContext::Init(TransportMgrBase * transport, IOContext * ioCo ReturnErrorOnFailure(PlatformMemoryUser::Init()); - ReturnErrorOnFailure(mOpKeyStore.Init(&mStorage)); + // ReturnErrorOnFailure(mOpKeyStore.Init(&mStorage)); ReturnErrorOnFailure(mOpCertStore.Init(&mStorage)); chip::FabricTable::InitParams initParams; @@ -80,7 +80,7 @@ void MessagingContext::Shutdown() mSessionManager.Shutdown(); mFabricTable.Shutdown(); mOpCertStore.Finish(); - mOpKeyStore.Finish(); + // mOpKeyStore.Finish(); } CHIP_ERROR MessagingContext::InitFromExisting(const MessagingContext & existing) diff --git a/src/messaging/tests/MessagingContext.h b/src/messaging/tests/MessagingContext.h index 156bb78bf3609e..2d3459ddad1ea0 100644 --- a/src/messaging/tests/MessagingContext.h +++ b/src/messaging/tests/MessagingContext.h @@ -18,7 +18,7 @@ #include #include -#include +#include #include #include #include @@ -182,7 +182,7 @@ class MessagingContext : public PlatformMemoryUser IOContext * mIOContext; TransportMgrBase * mTransport; // Only needed for InitFromExisting. chip::TestPersistentStorageDelegate mStorage; // for SessionManagerInit - chip::PersistentStorageOperationalKeystore mOpKeyStore; + chip::Crypto::PSAOperationalKeystore mOpKeyStore; chip::Credentials::PersistentStorageOpCertStore mOpCertStore; chip::Crypto::DefaultSessionKeystore mSessionKeystore; diff --git a/src/transport/tests/TestSessionManager.cpp b/src/transport/tests/TestSessionManager.cpp index 12dc46ae360cc6..1bc4f90d5691a5 100644 --- a/src/transport/tests/TestSessionManager.cpp +++ b/src/transport/tests/TestSessionManager.cpp @@ -27,7 +27,7 @@ #include #include #include -#include +#include #include #include #include @@ -70,13 +70,13 @@ class FabricTableHolder ~FabricTableHolder() { mFabricTable.Shutdown(); - mOpKeyStore.Finish(); + // mOpKeyStore.Finish(); mOpCertStore.Finish(); } CHIP_ERROR Init() { - ReturnErrorOnFailure(mOpKeyStore.Init(&mStorage)); + // ReturnErrorOnFailure(mOpKeyStore.Init(&mStorage)); ReturnErrorOnFailure(mOpCertStore.Init(&mStorage)); chip::FabricTable::InitParams initParams; @@ -92,7 +92,7 @@ class FabricTableHolder private: chip::FabricTable mFabricTable; chip::TestPersistentStorageDelegate mStorage; - chip::PersistentStorageOperationalKeystore mOpKeyStore; + chip::PSAOperationalKeystore mOpKeyStore; chip::Credentials::PersistentStorageOpCertStore mOpCertStore; }; diff --git a/src/transport/tests/TestSessionManagerDispatch.cpp b/src/transport/tests/TestSessionManagerDispatch.cpp index 4e320961267bd7..54f034e9763ef5 100644 --- a/src/transport/tests/TestSessionManagerDispatch.cpp +++ b/src/transport/tests/TestSessionManagerDispatch.cpp @@ -27,7 +27,7 @@ #include #include #include -#include +#include #include #include #include @@ -427,13 +427,13 @@ class FabricTableHolder ~FabricTableHolder() { mFabricTable.Shutdown(); - mOpKeyStore.Finish(); + // mOpKeyStore.Finish(); mOpCertStore.Finish(); } CHIP_ERROR Init() { - ReturnErrorOnFailure(mOpKeyStore.Init(&mStorage)); + // ReturnErrorOnFailure(mOpKeyStore.Init(&mStorage)); ReturnErrorOnFailure(mOpCertStore.Init(&mStorage)); // Initialize Group Data Provider @@ -457,7 +457,7 @@ class FabricTableHolder private: chip::FabricTable mFabricTable; chip::TestPersistentStorageDelegate mStorage; - chip::PersistentStorageOperationalKeystore mOpKeyStore; + chip::Crypto::PSAOperationalKeystore mOpKeyStore; chip::Credentials::PersistentStorageOpCertStore mOpCertStore; };