mirror of
https://github.com/tmate-io/tmate-ssh-server.git
synced 2020-11-18 19:53:51 -08:00
logging improvement
This commit is contained in:
parent
2bd232c982
commit
5c2c1c2584
@ -370,7 +370,7 @@ static void jail(void)
|
||||
gid = pw->pw_gid;
|
||||
|
||||
if (getuid() != 0)
|
||||
tmate_fatal("Need root privileges");
|
||||
tmate_fatal("Need root privileges to create the jail");
|
||||
|
||||
if (chroot(TMATE_WORKDIR "/jail") < 0)
|
||||
tmate_fatal("Cannot chroot()");
|
||||
|
@ -400,10 +400,10 @@ static void ssh_import_key(ssh_bind bind, const char *keys_dir, const char *name
|
||||
|
||||
sprintf(path, "%s/%s", keys_dir, name);
|
||||
|
||||
if (access(path, F_OK) < 0) {
|
||||
tmate_warn("Skipping host key %s", path);
|
||||
if (access(path, F_OK) < 0)
|
||||
return;
|
||||
}
|
||||
|
||||
tmate_notice("Loading key %s", path);
|
||||
|
||||
ssh_pki_import_privkey_file(path, NULL, NULL, NULL, &key);
|
||||
ssh_bind_options_set(bind, SSH_BIND_OPTIONS_IMPORT_KEY, key);
|
||||
|
Loading…
x
Reference in New Issue
Block a user