Check if rsakeys.ini exists on startup, exit if it's missing

ulab-next-nosound
Pavel Roskin 8 years ago
parent 86ec50789c
commit 3eb495f425

@ -299,6 +299,7 @@ xrdp_sanity_check(void)
{
int intval = 1;
int host_be;
char key_file[256];
/* check compiled endian with actual endian */
host_be = !((int)(*(unsigned char *)(&intval)));
@ -343,6 +344,13 @@ xrdp_sanity_check(void)
return 1;
}
g_snprintf(key_file, 255, "%s/rsakeys.ini", XRDP_CFG_PATH);
if (!g_file_exist(key_file))
{
g_writeln("File %s is missing, create it using xrdp-keygen", key_file);
return 1;
}
return 0;
}

Loading…
Cancel
Save