tools: update arguments

Modify the tools to take the certificate and private key directly as arguments, rather than the path to the directory that contains them.

Change-Id: I18010c27379d8e985b596bed0159155343265112
diff --git a/tools/dsh/dsh.cpp b/tools/dsh/dsh.cpp
index 4e7507d..60637ff 100644
--- a/tools/dsh/dsh.cpp
+++ b/tools/dsh/dsh.cpp
@@ -85,8 +85,7 @@
     exit(EXIT_FAILURE);
 }
 
-dhtnet::Dsh::Dsh(const std::filesystem::path& path,
-                 dht::crypto::Identity identity,
+dhtnet::Dsh::Dsh(dht::crypto::Identity identity,
                  const std::string& bootstrap,
                  const std::string& turn_host,
                  const std::string& turn_user,
@@ -96,7 +95,7 @@
     :logger(dht::log::getStdLogger())
     , ioContext(std::make_shared<asio::io_context>()),
     iceFactory(std::make_shared<IceTransportFactory>(logger)),
-    certStore(std::make_shared<tls::CertificateStore>(path / "certstore", logger)),
+    certStore(std::make_shared<tls::CertificateStore>(PATH/"certstore", logger)),
     trustStore(std::make_shared<tls::TrustStore>(*certStore))
 {
     ioContext = std::make_shared<asio::io_context>();
@@ -112,8 +111,7 @@
     auto ca = identity.second->issuer;
     trustStore->setCertificateStatus(ca->getId().toString(), tls::TrustStore::PermissionStatus::ALLOWED);
     // Build a server
-    auto config = connectionManagerConfig(path,
-                                          identity,
+    auto config = connectionManagerConfig(identity,
                                           bootstrap,
                                           logger,
                                           certStore,
@@ -220,8 +218,7 @@
     });
 }
 
-dhtnet::Dsh::Dsh(const std::filesystem::path& path,
-                 dht::crypto::Identity identity,
+dhtnet::Dsh::Dsh(dht::crypto::Identity identity,
                  const std::string& bootstrap,
                  dht::InfoHash peer_id,
                  const std::string& binary,
@@ -229,7 +226,7 @@
                  const std::string& turn_user,
                  const std::string& turn_pass,
                  const std::string& turn_realm)
-    : Dsh(path, identity, bootstrap, turn_host, turn_user, turn_pass, turn_realm, false)
+    : Dsh(identity, bootstrap, turn_host, turn_user, turn_pass, turn_realm, false)
 {
     // Build a client
     std::condition_variable cv;