diff --git a/lib/cli/pkiutility.cpp b/lib/cli/pkiutility.cpp index e80455b76..ea893e2aa 100644 --- a/lib/cli/pkiutility.cpp +++ b/lib/cli/pkiutility.cpp @@ -137,7 +137,7 @@ boost::shared_ptr PkiUtility::FetchCert(const String& host, const String& return boost::shared_ptr(); } - TlsStream::Ptr stream = new TlsStream(client, String(), RoleClient, sslContext); + TlsStream::Ptr stream = new TlsStream(client, host, RoleClient, sslContext); try { stream->Handshake(); @@ -201,7 +201,7 @@ int PkiUtility::RequestCertificate(const String& host, const String& port, const return 1; } - TlsStream::Ptr stream = new TlsStream(client, String(), RoleClient, sslContext); + TlsStream::Ptr stream = new TlsStream(client, host, RoleClient, sslContext); try { stream->Handshake();