diff --git a/src/jamidht/jamiaccount.cpp b/src/jamidht/jamiaccount.cpp
index 86f68a5adbac86bd6eb28b5872c3ca46eaa24e07..0fe2858d4bba820cf850c4efcfcf0cbe95e5bc7a 100644
--- a/src/jamidht/jamiaccount.cpp
+++ b/src/jamidht/jamiaccount.cpp
@@ -269,13 +269,13 @@ dhtStatusStr(dht::NodeStatus status)
 
 JamiAccount::JamiAccount(const std::string& accountId)
     : SIPAccountBase(accountId)
+    , certStore_ {std::make_unique<dhtnet::tls::CertificateStore>(idPath_, Logger::dhtLogger())}
     , dht_(new dht::DhtRunner)
     , idPath_(fileutils::get_data_dir() + DIR_SEPARATOR_STR + accountId)
     , cachePath_(fileutils::get_cache_dir() + DIR_SEPARATOR_STR + accountId)
     , dataPath_(cachePath_ + DIR_SEPARATOR_STR "values")
     , connectionManager_ {}
     , nonSwarmTransferManager_(std::make_shared<TransferManager>(accountId, ""))
-    , certStore_ {std::make_unique<dhtnet::tls::CertificateStore>(idPath_, Logger::dhtLogger())}
 {}
 
 JamiAccount::~JamiAccount() noexcept
diff --git a/src/jamidht/jamiaccount.h b/src/jamidht/jamiaccount.h
index 9c74d49bdade4119198f6f2b8c38b5ccc566b81d..dc85f4527977ae120dd52927798b4080439fc12a 100644
--- a/src/jamidht/jamiaccount.h
+++ b/src/jamidht/jamiaccount.h
@@ -702,6 +702,7 @@ private:
     std::string registeredName_;
 #endif
     std::shared_ptr<dht::Logger> logger_;
+    std::unique_ptr<dhtnet::tls::CertificateStore> certStore_;
 
     std::shared_ptr<dht::DhtRunner> dht_ {};
     std::unique_ptr<AccountManager> accountManager_;
@@ -876,8 +877,6 @@ private:
     std::unique_ptr<SyncModule> syncModule_;
 
     void initConnectionManager();
-
-    std::unique_ptr<dhtnet::tls::CertificateStore> certStore_;
 };
 
 static inline std::ostream&