diff --git a/server/plugins-available/shelluser_jailkit_plugin.inc.php b/server/plugins-available/shelluser_jailkit_plugin.inc.php index db1d2b676b87e022ccbe78d46da3ab1022a10f1a..c7112c497a1b2355d4d13fd298383a3b899630e9 100755 --- a/server/plugins-available/shelluser_jailkit_plugin.inc.php +++ b/server/plugins-available/shelluser_jailkit_plugin.inc.php @@ -490,7 +490,7 @@ class shelluser_jailkit_plugin { // add root's key $app->file->mkdirs($sshdir, '0755'); $authorized_keys_template = $this->jailkit_config['jailkit_chroot_authorized_keys_template']; - if(is_file('/root/.ssh/authorized_keys')) $app->system->file_put_contents($sshkeys, $app->system->file_get_contents($authorized_keys_template)); + if(is_file($authorized_keys_template)) $app->system->file_put_contents($sshkeys, $app->system->file_get_contents($authorized_keys_template)); // Remove duplicate keys $existing_keys = @file($sshkeys, FILE_IGNORE_NEW_LINES);