|
|
|
@ -1,4 +1,4 @@
|
|
|
|
|
/**
|
|
|
|
|
default certificate pa/**
|
|
|
|
|
* xrdp: A Remote Desktop Protocol server.
|
|
|
|
|
*
|
|
|
|
|
* Copyright (C) Jay Sorg 2004-2014
|
|
|
|
@ -186,15 +186,15 @@ xrdp_rdp_read_config(struct xrdp_client_info *client_info)
|
|
|
|
|
g_memset(client_info->certificate, 0, sizeof(char) * 1024);
|
|
|
|
|
if (value[0] != '/')
|
|
|
|
|
{
|
|
|
|
|
/* default certificate path */
|
|
|
|
|
/* default certificate path */
|
|
|
|
|
g_snprintf(client_info->certificate, 1023, "%s/cert.pem", XRDP_CFG_PATH);
|
|
|
|
|
log_message(LOG_LEVEL_ALWAYS,"WARNING: Invalid x.509 certificate path defined, "
|
|
|
|
|
"default path will be used: %s", client_info->certificate);
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
/* use user defined certificate */
|
|
|
|
|
g_strncpy(client_info->certificate, value, 1023);
|
|
|
|
|
/* use user defined certificate */
|
|
|
|
|
g_strncpy(client_info->certificate, value, 1023);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
else if (g_strcasecmp(item, "key_file") == 0)
|
|
|
|
@ -202,15 +202,15 @@ xrdp_rdp_read_config(struct xrdp_client_info *client_info)
|
|
|
|
|
g_memset(client_info->key_file, 0, sizeof(char) * 1024);
|
|
|
|
|
if (value[0] != '/')
|
|
|
|
|
{
|
|
|
|
|
/* default key_file path */
|
|
|
|
|
/* default key_file path */
|
|
|
|
|
g_snprintf(client_info->key_file, 1023, "%s/key.pem", XRDP_CFG_PATH);
|
|
|
|
|
log_message(LOG_LEVEL_ALWAYS,"WARNING: Invalid x.509 certificate path defined, "
|
|
|
|
|
"default path will be used: %s", client_info->key_file);
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
/* use user defined key_file */
|
|
|
|
|
g_strncpy(client_info->key_file, value, 1023);
|
|
|
|
|
/* use user defined key_file */
|
|
|
|
|
g_strncpy(client_info->key_file, value, 1023);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|