Fixed ns plugin using old certificate path #4525
This commit is contained in:
parent
f997aea8e7
commit
a894615ca7
|
@ -23,6 +23,7 @@
|
||||||
#include "net/TSocketMultiplexerMethodJob.h"
|
#include "net/TSocketMultiplexerMethodJob.h"
|
||||||
#include "arch/XArch.h"
|
#include "arch/XArch.h"
|
||||||
|
|
||||||
|
static const char s_certificateDir[] = { "SSL" };
|
||||||
static const char s_certificateFilename[] = { "Synergy.pem" };
|
static const char s_certificateFilename[] = { "Synergy.pem" };
|
||||||
|
|
||||||
//
|
//
|
||||||
|
@ -60,14 +61,11 @@ SecureListenSocket::accept()
|
||||||
setListeningJob();
|
setListeningJob();
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: customized certificate path
|
String certificateFilename = synergy::string::sprintf(
|
||||||
String certificateFilename = ARCH->getProfileDirectory();
|
"%s/%s/%s",
|
||||||
#if SYSAPI_WIN32
|
ARCH->getProfileDirectory().c_str(),
|
||||||
certificateFilename.append("\\");
|
s_certificateDir,
|
||||||
#elif SYSAPI_UNIX
|
s_certificateFilename);
|
||||||
certificateFilename.append("/");
|
|
||||||
#endif
|
|
||||||
certificateFilename.append(s_certificateFilename);
|
|
||||||
|
|
||||||
bool loaded = socket->loadCertificates(certificateFilename);
|
bool loaded = socket->loadCertificates(certificateFilename);
|
||||||
if (!loaded) {
|
if (!loaded) {
|
||||||
|
|
Loading…
Reference in New Issue