return 0;
}
- if (argc == 1 && check_ssh_interactive(getuid()))
+ if (argc == 1 && check_ssh_interactive(getuid())) {
+ setuid(getuid());
execvp(shell_argv[0], (char *const *) shell_argv);
+ }
#ifdef USE_DEFAULTS
ini_parse("repo_shell.cfg", handler, &cfg);
if (!check_ssh_interactive(getuid()))
die("only repository access is allowed");
+ setuid(getuid());
cd_to_homedir();
count = split_cmdline(prog, &user_argv);
if (count >= 0) {